Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!news.musoftware.de!wum.musoftware.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Robert Klemme Newsgroups: comp.lang.ruby Subject: Re: How to get ruby to find a native lib? Date: Mon, 13 Feb 2012 20:39:56 +0100 Lines: 20 Message-ID: <9pt78gFffaU1@mid.individual.net> References: <235d5$4f393be1$84b70406$5935@news.eurofeeds.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: individual.net 3B0VWT63ip/x7Katd6hx1grWP8xHvuCQc/CGXmwS0m5giDWZA= Cancel-Lock: sha1:h6spX9IdxHKSx7R4lUMhDmrAs38= User-Agent: Mozilla/5.0 (X11; Linux i686; rv:9.0) Gecko/20111229 Thunderbird/9.0 In-Reply-To: <235d5$4f393be1$84b70406$5935@news.eurofeeds.com> Xref: x330-a1.tempe.blueboxinc.net comp.lang.ruby:6454 On 02/13/2012 05:35 PM, Adam Russell wrote: > I have installed some native libraries. They are in /usr/local/lib. > I am now trying to install a ruby gem which needs these in order to > build correctly but the gem build fails as it cannot find these > libraries. > The gem's extconf.rb file tries to confirm it can find the library with > have_library() but this fails for some reason. > I have tried setting a bunch of environment variables (see below for my > tests in irb) but nothing seems to work. > What is the best way to solve this problem? Hmm, did you try $ LD_LIBRARY_PATH=/usr/local/lib gem install XYZ ? Maybe also export CPPFLAGS=-I/usr/local/include Kind regards robert