octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Overhaul of Java auto-detection


From: Philip Nienhuis
Subject: Re: Overhaul of Java auto-detection
Date: Tue, 11 Dec 2012 10:01:27 -0800 (PST)

Rik-4 wrote
> On 12/10/2012 04:34 PM, 

> octave-maintainers-request@

>  wrote:
>> Message: 5
>> Date: Mon, 10 Dec 2012 15:26:48 -0800 (PST)
>> From: Philip Nienhuis <

> address@hidden

> >
>> To: 

> octave-maintainers@

>> Subject: Re: Overhaul of Java auto-detection
>> Message-ID: <

> address@hidden

>>
>> Content-Type: text/plain; charset=us-ascii
>>
>> Rik-4 wrote
>>> > 12/10/12
>>> > 
>>> > All,
>>> > 
>>> > I just pushed a changeset which significantly changes (improves?) the
>>> way
>>> > Java is detected if JAVA_HOME has not been set
>>> > (http://hg.savannah.gnu.org/hgweb/octave/rev/56239ff815a3).  There are
>>> > likely to be kinks which need working out and I particularly need
>>> feedback
>>> > from Mac OS X systems.  Despite all those caveats, I think this is a
>>> much
>>> > better strategy for detection than having a laundry list of
>>> directories to
>>> > check for each operating system and distribution.
>> Sorry to say, but now Java isn't properly picked up any more on my Linux
>> dev
>> box (Mageia-2).
>> All configure does now is echo the entered value for JAVA_HOME; the
>> include
>> dirs etc are blank.
>>
>> W/o JAVA_HOME it doesn't work better; after an hg update (pulling your
>> very
>> changeset), configure ran again but after a while the build broke with
>> complaints about missing jni.h
> Philip,
> 
> Since configure.ac was changed you need to run bootstrap in order to
> regenerate the configure script before running it.
> 
> 'hg pull; hg update; bootstrap; configure; make'
> 
> If you can, run './configure --your-options | tee confdbg.log' and I can
> take a look at what configure discovered.

Sorry Rik, no joy.


This what configure says in various cases:

## No JAVA_HOME:
:
configure: WARNING: JAVA_HOME environment variable not initialized.
configure: WARNING: Auto-detection will proceed but is unreliable.
checking for java... /usr/bin/java
checking for javac... /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.6/bin/javac
checking for jar... /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.6/bin/jar
checking for Java version... 1.7.0_06-icedtea
configure: WARNING: Library libjvm not found.  Octave will not be able to
call Java methods.

// Configure correctly finds the executables but gets libjvm.so's location
wrong, it is in:
//  address@hidden oct370+]$ ls -l /usr/lib/jvm/java/jre/lib/i386/client
//  total 6032
//  lrwxrwxrwx 1 root root      13 Nov  9 15:52 libjsig.so -> ../libjsig.so*
//  -rwxr-xr-x 1 root root 6169780 Oct 28 04:52 libjvm.so*
//  -rw-r--r-- 1 root root    1423 Oct 28 04:44 Xusage.txt
//  address@hidden oct370+]$


## Setting JAVA_HOME to the relevant symlink:
## /usr/lib/jvm/java/jre/bin/java  ->  /etc/alternatives/java_sdk  -> 
/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.6
:
checking for java... /usr/lib/jvm/java/jre/bin/java
checking for javac... /usr/lib/jvm/java/bin/javac
checking for jar... /usr/lib/jvm/java/bin/jar
checking for Java version... 1.7.0_06-icedtea
configure: WARNING: Library libjvm not found.  Octave will not be able to
call Java methods.
:
  Java home:                   /usr/lib/jvm/java
  Java JVM path:               
  Java CPPFLAGS:               
  Java libraries:              

// Same issue
  
 ## Setting JAVA_HOME directly:
 :
 checking for java... /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.6/jre/bin/java
checking for javac... /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.6/bin/javac
checking for jar... /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.6/bin/jar
checking for Java version... 1.7.0_06-icedtea
configure: WARNING: Library libjvm not found.  Octave will not be able to
call Java methods.
:
  Java home:                   /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.6
  Java JVM path:               
  Java CPPFLAGS:               
  Java libraries:              

// Same issue

Does configure expect the jvm lib to be in ...../server/ (which is only
valid for 64-bit systems) or ..../client/ (for 32bit systems) ?

Philip

 




--
View this message in context: 
http://octave.1599824.n4.nabble.com/Overhaul-of-Java-auto-detection-tp4647726p4647767.html
Sent from the Octave - Maintainers mailing list archive at Nabble.com.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]