Help needed in building xruby (for java newbie)

Discussion in 'Ruby' started by Axel Etzold, Jun 18, 2007.

  1. Axel Etzold

    Axel Etzold Guest

    Dear all,

    when trying to build xruby for Linux i586, OpenSuSE 10.2,
    I get the following errors:


    dhcppc1:/usr/local/xruby # export JAVA_HOME=/usr
    dhcppc1:/usr/local/xruby # which javac
    /usr/bin/javac
    dhcppc1:/usr/local/xruby # javac -version
    javac 1.5.0_10
    <snip>

    dhcppc1:/usr/local/xruby # sh build.sh
    Buildfile: build.xml

    parser:

    treeparser:

    compile:
    [javac] Compiling 273 source files to /usr/local/xruby/build

    BUILD FAILED
    /usr/local/xruby/build.xml:59: Unable to find a javac compiler;
    com.sun.tools.javac.Main is not on the classpath.
    Perhaps JAVA_HOME does not point to the JDK

    Total time: 0 seconds

    How could I tell the build script where to look for javac - if
    this is the real problem here?

    Thank you very much,

    Best regards

    Axel
    --
    GMX FreeMail: 1 GB Postfach, 5 E-Mail-Adressen, 10 Free SMS.
    Alle Infos und kostenlose Anmeldung: http://www.gmx.net/de/go/freemail
     
    Axel Etzold, Jun 18, 2007
    #1
    1. Advertising

  2. Axel Etzold wrote:

    > /usr/local/xruby/build.xml:59: Unable to find a javac compiler;
    > com.sun.tools.javac.Main is not on the classpath.
    > Perhaps JAVA_HOME does not point to the JDK



    Hi Axel.

    Looks like you need to add the directory containing javac to your PATH.
    In teh example below I did a find to get that, then modified the path.

    quicksilver:~ dougal$ sudo find / -name javac
    /usr/bin/javac
    quicksilver:~ dougal$ export PATH=/usr/bin:$PATH

    Obviously this example is a little silly, as /usr/bin will always be in
    your path (On OS X anyway), but on your system it may be located
    differently.

    In sumary..

    1 - Find where javac and friends live.
    2 - Add the directory to your PATH.
    3 - Run your compilation.

    Hope this helps.

    D.
    http://douglasfshearer.com

    --
    Posted via http://www.ruby-forum.com/.
     
    Douglas Shearer, Jun 18, 2007
    #2
    1. Advertising

  3. Axel Etzold

    Axel Etzold Guest

    Dear Douglas,

    thank you for responding.
    I actually verified that javac is on my system, and
    can be found by the system to compile a "Hello-World"
    program in java.
    So I don't think that the $JAVA_HOME
    variable is the problem here anymore, but I am a java
    newbie, so I don't understand what could be wrong otherwise...

    Please, Java experts, help me again...

    Best regards,

    Axel



    -------- Original-Nachricht --------
    Datum: Tue, 19 Jun 2007 05:31:29 +0900
    Von: Douglas Shearer <>
    An:
    Betreff: Re: Help needed in building xruby (for java newbie)

    > Axel Etzold wrote:
    >
    > > /usr/local/xruby/build.xml:59: Unable to find a javac compiler;
    > > com.sun.tools.javac.Main is not on the classpath.
    > > Perhaps JAVA_HOME does not point to the JDK

    >
    >
    > Hi Axel.
    >
    > Looks like you need to add the directory containing javac to your PATH.
    > In teh example below I did a find to get that, then modified the path.
    >
    > quicksilver:~ dougal$ sudo find / -name javac
    > /usr/bin/javac
    > quicksilver:~ dougal$ export PATH=/usr/bin:$PATH
    >
    > Obviously this example is a little silly, as /usr/bin will always be in
    > your path (On OS X anyway), but on your system it may be located
    > differently.
    >
    > In sumary..
    >
    > 1 - Find where javac and friends live.
    > 2 - Add the directory to your PATH.
    > 3 - Run your compilation.
    >
    > Hope this helps.
    >
    > D.
    > http://douglasfshearer.com
    >
    > --
    > Posted via http://www.ruby-forum.com/.


    --
    Psssst! Schon vom neuen GMX MultiMessenger gehört?
    Der kanns mit allen: http://www.gmx.net/de/go/multimessenger
     
    Axel Etzold, Jun 19, 2007
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Midex
    Replies:
    24
    Views:
    974
  2. Xueyong Zhi

    [ANN]XRuby compiler 0.1.0 released

    Xueyong Zhi, Jan 30, 2007, in forum: Ruby
    Replies:
    4
    Views:
    136
    dreamhead
    Jan 31, 2007
  3. Axel Etzold
    Replies:
    1
    Views:
    111
    Luis Parravicini
    Jun 21, 2007
  4. Robert Dober

    Ever heared of XRuby before?

    Robert Dober, Nov 18, 2008, in forum: Ruby
    Replies:
    3
    Views:
    109
    Charles Oliver Nutter
    Nov 19, 2008
  5. Tim Sheets
    Replies:
    15
    Views:
    252
    Jim Cochrane
    May 8, 2004
Loading...

Share This Page