You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@buildr.apache.org by Stephen Bannasch <st...@deanbrook.org> on 2008/04/02 05:33:17 UTC
error installing buildr gem on MacOS 10.5.2
When I tried to install the gem it failed and complained that
JAVA_HOME was not set ... but JAVA_HOME is set:
$ echo $JAVA_HOME
/System/Library/Frameworks/JavaVM.framework/Home
The install is using the stock 1.8.6 MRI Ruby that comes with Leopard.
Here's what the install failure looks like:
$ sudo gem install buildr
Password:
Updating metadata for 153 gems from http://gems.rubyforge.org
.........................................................................................................................................................
complete
Building native extensions. This could take a while...
ERROR: Error installing buildr:
ERROR: Failed to build gem native extension.
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
extconf.rb install buildr
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers. Check the mkmf.log file for more
details. You may need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
extconf.rb:44: JAVA_HOME is not setted. (RuntimeError)
Gem files will remain installed in
/Library/Ruby/Gems/1.8/gems/rjb-1.1.3 for inspection.
Results logged to /Library/Ruby/Gems/1.8/gems/rjb-1.1.3/ext/gem_make.out
Re: error installing buildr gem on MacOS 10.5.2
Posted by Maarten Billemont <lh...@gmail.com>.
When you execute sudo, you loose your current environment.
Use:
$ sudo su -
$ JAVA_HOME=/... gem install buildr
On 02 Apr 2008, at 05:33, Stephen Bannasch wrote:
> When I tried to install the gem it failed and complained that
> JAVA_HOME was not set ... but JAVA_HOME is set:
>
> $ echo $JAVA_HOME
> /System/Library/Frameworks/JavaVM.framework/Home
>
> The install is using the stock 1.8.6 MRI Ruby that comes with Leopard.
>
> Here's what the install failure looks like:
>
> $ sudo gem install buildr
> Password:
> Updating metadata for 153 gems from http://gems.rubyforge.org
> .........................................................................................................................................................
> complete
> Building native extensions. This could take a while...
> ERROR: Error installing buildr:
> ERROR: Failed to build gem native extension.
>
> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
> extconf.rb install buildr
> *** extconf.rb failed ***
> Could not create Makefile due to some reason, probably lack of
> necessary libraries and/or headers. Check the mkmf.log file for more
> details. You may need configuration options.
>
> Provided configuration options:
> --with-opt-dir
> --without-opt-dir
> --with-opt-include
> --without-opt-include=${opt-dir}/include
> --with-opt-lib
> --without-opt-lib=${opt-dir}/lib
> --with-make-prog
> --without-make-prog
> --srcdir=.
> --curdir
> --ruby=/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/
> bin/ruby
> extconf.rb:44: JAVA_HOME is not setted. (RuntimeError)
>
>
> Gem files will remain installed in /Library/Ruby/Gems/1.8/gems/
> rjb-1.1.3 for inspection.
> Results logged to /Library/Ruby/Gems/1.8/gems/rjb-1.1.3/ext/
> gem_make.out
>
>
>
Re: error installing buildr gem on MacOS 10.5.2
Posted by Stephen Bannasch <st...@deanbrook.org>.
At 11:29 PM -0500 4/1/08, Rhett Sutphin wrote:
>Hi,
>
>On Apr 1, 2008, at 10:59 PM, Tal Rotbart wrote:
>>Hi there,
>>
>>I believe the problem stems because you are setting JAVA_HOME for your
>>user, but when you sudo, gem sees root's environment variables, and
>>those do not have JAVA_HOME set. I might be wrong though!
>
>Things run under sudo usually inherit the environment variables of the sudoer. However, OS X 10.5 has a more restrictive default sudo configuration. See here for more details & one fix:
>
>http://groups.google.com/group/buildr-talk/msg/5aa84b1dc9200ecf
>
>Rhett
Thanks Rhett -- I should have done a better search of the maillist first.
Re: error installing buildr gem on MacOS 10.5.2
Posted by Rhett Sutphin <rh...@detailedbalance.net>.
Hi,
On Apr 1, 2008, at 10:59 PM, Tal Rotbart wrote:
> Hi there,
>
> I believe the problem stems because you are setting JAVA_HOME for your
> user, but when you sudo, gem sees root's environment variables, and
> those do not have JAVA_HOME set. I might be wrong though!
Things run under sudo usually inherit the environment variables of the
sudoer. However, OS X 10.5 has a more restrictive default sudo
configuration. See here for more details & one fix:
http://groups.google.com/group/buildr-talk/msg/5aa84b1dc9200ecf
Rhett
>
>
> Cheers,
> Tal
>
> On Wed, Apr 2, 2008 at 2:33 PM, Stephen Bannasch
> <st...@deanbrook.org> wrote:
>> When I tried to install the gem it failed and complained that
>> JAVA_HOME was not set ... but JAVA_HOME is set:
>>
>> $ echo $JAVA_HOME
>> /System/Library/Frameworks/JavaVM.framework/Home
>>
>> The install is using the stock 1.8.6 MRI Ruby that comes with
>> Leopard.
>>
>> Here's what the install failure looks like:
>>
>> $ sudo gem install buildr
>> Password:
>> Updating metadata for 153 gems from http://gems.rubyforge.org
>> .........................................................................................................................................................
>> complete
>> Building native extensions. This could take a while...
>> ERROR: Error installing buildr:
>> ERROR: Failed to build gem native extension.
>>
>> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
>> extconf.rb install buildr
>> *** extconf.rb failed ***
>> Could not create Makefile due to some reason, probably lack of
>> necessary libraries and/or headers. Check the mkmf.log file for more
>> details. You may need configuration options.
>>
>> Provided configuration options:
>> --with-opt-dir
>> --without-opt-dir
>> --with-opt-include
>> --without-opt-include=${opt-dir}/include
>> --with-opt-lib
>> --without-opt-lib=${opt-dir}/lib
>> --with-make-prog
>> --without-make-prog
>> --srcdir=.
>> --curdir
>> --ruby=/System/Library/Frameworks/Ruby.framework/Versions/
>> 1.8/usr/bin/ruby
>> extconf.rb:44: JAVA_HOME is not setted. (RuntimeError)
>>
>>
>> Gem files will remain installed in
>> /Library/Ruby/Gems/1.8/gems/rjb-1.1.3 for inspection.
>> Results logged to /Library/Ruby/Gems/1.8/gems/rjb-1.1.3/ext/
>> gem_make.out
>>
>>
>>
>>
Re: error installing buildr gem on MacOS 10.5.2
Posted by Tal Rotbart <re...@gmail.com>.
Hi there,
I believe the problem stems because you are setting JAVA_HOME for your
user, but when you sudo, gem sees root's environment variables, and
those do not have JAVA_HOME set. I might be wrong though!
Cheers,
Tal
On Wed, Apr 2, 2008 at 2:33 PM, Stephen Bannasch
<st...@deanbrook.org> wrote:
> When I tried to install the gem it failed and complained that
> JAVA_HOME was not set ... but JAVA_HOME is set:
>
> $ echo $JAVA_HOME
> /System/Library/Frameworks/JavaVM.framework/Home
>
> The install is using the stock 1.8.6 MRI Ruby that comes with Leopard.
>
> Here's what the install failure looks like:
>
> $ sudo gem install buildr
> Password:
> Updating metadata for 153 gems from http://gems.rubyforge.org
> .........................................................................................................................................................
> complete
> Building native extensions. This could take a while...
> ERROR: Error installing buildr:
> ERROR: Failed to build gem native extension.
>
> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
> extconf.rb install buildr
> *** extconf.rb failed ***
> Could not create Makefile due to some reason, probably lack of
> necessary libraries and/or headers. Check the mkmf.log file for more
> details. You may need configuration options.
>
> Provided configuration options:
> --with-opt-dir
> --without-opt-dir
> --with-opt-include
> --without-opt-include=${opt-dir}/include
> --with-opt-lib
> --without-opt-lib=${opt-dir}/lib
> --with-make-prog
> --without-make-prog
> --srcdir=.
> --curdir
> --ruby=/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
> extconf.rb:44: JAVA_HOME is not setted. (RuntimeError)
>
>
> Gem files will remain installed in
> /Library/Ruby/Gems/1.8/gems/rjb-1.1.3 for inspection.
> Results logged to /Library/Ruby/Gems/1.8/gems/rjb-1.1.3/ext/gem_make.out
>
>
>
>