Coding in geany

313 views
Skip to first unread message

Hina Jain

unread,
Sep 16, 2010, 7:41:05 AM9/16/10
to foss-bi...@googlegroups.com

hi,
i wrote a java source file in geany, and when i try to compile it, it says. 

/bin/sh:javac not found
compilation failed.

Please suggest ways to remove this.

Thanks,

Shrainik jain

unread,
Sep 16, 2010, 7:46:41 AM9/16/10
to foss-bi...@googlegroups.com
javac package is missing.. 
best way to install it and many other packages is to install ubuntu-restricted-extras

run this command

sudo apt-get install ubuntu-restricted-extras 
--
Shrainik Jain,
President,
CSA, BITS-Pilani

Hina Jain

unread,
Sep 16, 2010, 7:52:26 AM9/16/10
to foss-bi...@googlegroups.com
i already have this package installed, it is still giving me the same error. 
there isn't anything like saving to a particular target or something in geany right ? and my file has extension .java i hope that isn't a problem.

Shrainik jain

unread,
Sep 16, 2010, 8:02:40 AM9/16/10
to foss-bi...@googlegroups.com
i have never used geany but mostly the error is because it is not able to find the java compiler, which is either because javac is not installed or the path is not set. Since you have already installed javac, i guess the path to the jdk bin is not set. Try and search if geany has an option to set the javac path and set it to the path to bin(which is /usr/lib/jvm/java-6-openjdk/jre/bin/java, if not sure about the path check for the output of ls -l /usr/bin/java and ls -l /etc/alternatives/java).


On Thu, Sep 16, 2010 at 5:22 PM, Hina Jain <hi.hi...@gmail.com> wrote:
i already have this package installed, it is still giving me the same error. 
there isn't anything like saving to a particular target or something in geany right ? and my file has extension .java i hope that isn't a problem.



Shrainik jain

unread,
Sep 16, 2010, 8:16:43 AM9/16/10
to foss-bi...@googlegroups.com
I just installed geany. Its working fine on my comp. But i did see the option of manually setting the path in edit->preferences, under the general tab. Try and see if setting the path there works.

Hina Jain

unread,
Sep 16, 2010, 9:16:10 PM9/16/10
to foss-bi...@googlegroups.com
hi,
i separately installed the packages sun-java6-jre, sun-java6-bin & sun-java6-jdk from synaptic; set the path as Shrainik said and now it's working.

Thanks,

Hina.
Reply all
Reply to author
Forward
0 new messages