Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: Java binaries seem to ignore JAVA_HOME

  1. #1
    Junior Member
    Join Date
    Aug 2022
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Java binaries seem to ignore JAVA_HOME

    I apologize for not picking a better topic, but this seemed the most fitting :D

    I recently cross compiled openjdk11u to sparc64/linux. I needed to apply one patch for it to build, but the binaries seem to run fine. I tried compiling and running several different java programs I wrote.

    However, when adding these binaries to PATH (java, javac, etc), they start to complain:

    * Home for VM '' does not exist: 
    * Invalid System VM:

    However, I set the variable JAVA_HOME, and the output does not change:

    echo $JAVA_HOME
    /jdk/linux-sparcv9-normal-server-release/jdk
     
    echo $PATH
    /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/bin:/jdk/linux-sparcv9-normal-server-release/jdk/bin
     
    java -version
    * Home for VM '' does not exist: 
    * Invalid System VM: 
     
    /jdk/linux-sparcv9-normal-server-release/jdk/bin/java -version
     
    openjdk version "11.0.15-internal" 2022-04-19
    OpenJDK Runtime Environment (build 11.0.15-internal+0-adhoc.rich.jdk11u-jdk-11.0.15-ga)
    OpenJDK 64-Bit Minimal VM (build 11.0.15-internal+0-adhoc.rich.jdk11u-jdk-11.0.15-ga, mixed mode)

    I have 0 idea on where to go next, I can't find a trace of an issue like this on the web.... am I correct that this isn't expected behavior?

  2. #2
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,042
    Thanks
    63
    Thanked 2,708 Times in 2,658 Posts

    Default Re: Java binaries seem to ignore JAVA_HOME

    I use the Oracle JDK on Win10 and have no suggestions.
    Try asking your question on this forum: https://coderanch.com/forums
    If you don't understand my answer, don't ignore it, ask a question.

Similar Threads

  1. Ignore certain characters in a string.
    By JaAnTr in forum What's Wrong With My Code?
    Replies: 3
    Last Post: April 5th, 2014, 03:18 PM
  2. How to ignore numbers after space
    By fahman_khan75@yahoo.com in forum What's Wrong With My Code?
    Replies: 2
    Last Post: February 13th, 2014, 04:23 AM
  3. Turn off/ignore win, alt, and ctrl keys
    By Melawe in forum What's Wrong With My Code?
    Replies: 18
    Last Post: August 31st, 2012, 05:38 PM
  4. Replies: 1
    Last Post: July 28th, 2012, 12:05 AM
  5. how to ignore upper and lower case
    By mohamed_saleh2012 in forum Java Theory & Questions
    Replies: 1
    Last Post: March 10th, 2012, 03:49 PM