setting the JAVA_HOME environment variable

Thufir hawat.thufir at gmail.com
Mon Mar 24 09:28:43 UTC 2008


On Mon, 24 Mar 2008 19:48:38 +1100, James Gray wrote:


> The error message is correct - JAVA_HOME is a directory, not the Java
> binary.  In your case it appears you need to replace your existing
> JAVA_HOME with:
> $ export JAVA_HOME=/usr/lib/jvm/java-6-sun/jre


Excellent, thank you.  I have to environment variable correct now (?), 
but this particular ruby gem fails to install still (haven't examined the 
mkmf.log yet):

root at arrakis:~# 
root at arrakis:~# 
root at arrakis:~# cat /var/lib/gems/1.8/gems/rjb-1.1.2/ext/gem_make.out
ruby extconf.rb install rjb
*** 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=/usr/bin/ruby1.8
extconf.rb:36:in `open': No such file or directory - /usr/lib/jvm/java-6-
sun/jre/include (Errno::ENOENT)
        from extconf.rb:36
root at arrakis:~# 
root at arrakis:~# echo $JAVA_HOME
/usr/lib/jvm/java-6-sun/jre
root at arrakis:~# 
root at arrakis:~# ll /usr/lib/jvm/java-6-sun/jre/
total 260
drwxr-xr-x  2 root root   4096 2008-03-19 12:00 bin
-rw-r--r--  1 root root   2487 2007-09-24 23:05 COPYRIGHT
drwxr-xr-x  2 root root   4096 2008-03-19 12:00 javaws
drwxr-xr-x 17 root root   4096 2008-03-19 12:00 lib
-rw-r--r--  1 root root  35120 2006-12-06 17:20 LICENSE
drwxr-xr-x  4 root root   4096 2008-03-19 02:38 man
drwxr-xr-x  4 root root   4096 2008-03-19 02:38 plugin
-rw-r--r--  1 root root  13543 2006-12-06 17:21 README
-rw-r--r--  1 root root 178596 2007-09-24 23:05 
THIRDPARTYLICENSEREADME.txt
-rw-r--r--  1 root root    968 2007-09-24 23:05 Welcome.html
root at arrakis:~# 
root at arrakis:~# 


-Thufir






More information about the ubuntu-users mailing list