Skip to main content
GameDev.net gamedev.net
🔒 Locked

Eclipse on linux can't find jre!

Started by johnnyBravo Jul 4, 2005 at 11:55 PM 15 replies 4.9k views
Original Post
johnnyBravo
johnnyBravo
Hi, I'm trying run eclipse on linux. So I installed the jre sdk, then I extracted eclipse. It says it can't find the jre directory which is inside the sdk. So i cut and paste that directory into the eclipse, which it could then find so it ran. But I want eclipse to find and use the jre directory inside the java sdk instead. I looked inside the ini and config files, but I cannot see when I set the jre directory path. Any ideas? Thanks
tHiSiSbOb
tHiSiSbOb
You need to put the java bin directory in your environment variable list.
----------------------------------------------------"Plant a tree. Remove a Bush" -A bumper sticker I saw.
johnnyBravo
johnnyBravo
Thanks, in the 'Terminal' i'm entering:
PATH=$PATH:/mydirectory

And when i echo it, it returns all those directories that it contains aswell as my directory.

But when I run Eclipse, it still can't find it, and when I restart the computer, and I echo the path, mydirectory is no longer in the list.

I don't see why eclipse can't see it once i've entered it, and why it isn't saving the modified path when i restart the computer, anyone know whats going on here?

Thanks alot.
Toolmaker
Toolmaker
Why on earth would one use Eclipse? I'm running it on an AMD Athlon XP-64 3000+, and even at regular occassions, it just stops responding for half a second.

I freakin' hate it. Not to mention it places closing } and ) itself, which kinda mangles with my own habit of immediatly placing the closing tags myself.

Toolmaker
 
Toolmaker
Toolmaker
Quote:
Original post by johnnyBravo
its good for big projects


Eclipse isn't even good for small projects... I'm doing a big project for school with it right now, and I hate it. After this project is done, I'll delete it faster than a mofo and crawl back to MSVC.

I remember people bashing VS IDE, well, those people should try Eclipse for once. [grin]

Toolmaker
 
George2
George2
put this :

#!/bin/sh
export JAVA_HOME=/usr/lib/java
export MANPATH="$MANPATH:/usr/lib/java/man"
export PATH="$PATH:/usr/lib/java/bin:/usr/lib/java/jre/bin"

in /etc/profile.d/jre.sh

And make the script executable. (Obviously replace the paths by your own)

This is how slackware does it, I don't know how other distros do it, you could also append the 3 last lines to /etc/profile
"THE INFORMATION CONTAINED IN THIS REPORT IS CLASSIFIED; DO NOT GO TO FOX NEWS TO READ OR OBTAIN A COPY." , the pentagon
johnnyBravo
johnnyBravo
You can do things like make it run other processes when u build the project, so u can deploy webpages etc. u have to know how to use it before its any good, its the best one ive used that is fully featured
Witchcraven
Witchcraven
I fully agree with the eclipse haters. I honestly would prefer to and do use pico (or nano). I dont like VS either, but it sure beats the crap out of eclipse.
--------------------------I present for tribute this haiku:Inane Ravings OfThe Haunting JubilationA Mad Engineer©Copyright 2005 ExtrariusAll Rights Reserved
SticksandStones
SticksandStones
Quote:
Original post by Toolmaker
Why on earth would one use Eclipse? I'm running it on an AMD Athlon XP-64 3000+, and even at regular occassions, it just stops responding for half a second.

I freakin' hate it. Not to mention it places closing } and ) itself, which kinda mangles with my own habit of immediatly placing the closing tags myself.

Toolmaker
That's funny, my 600mhz celeron runs it with only a few slow downs, mostly when starting up.

hippopotomonstrosesquippedaliophobia- the fear of big words
amannis
amannis
I have no clue of the eclipse's C/C++ module, but with Java it's really one of the best choices. Very actively developed, lots of features & refactorings and probably has more plugins than any other IDE. It also runs perfectly on my 1200mhz computer. And not to mention it's completely free.

Quote:

I freakin' hate it. Not to mention it places closing } and ) itself, which kinda mangles with my own habit of immediatly placing the closing tags myself.

That's like saying, damn Windows sucks because it doesnt default to 1600x1200 resolution.
SamLowry
SamLowry
You seem to go through the same pain as I did on Sunday (getting Ubuntu, installing the JDK, and now Eclipse too)

I tried several things to get java in the path, but it just wouldn't work. Also tried to make a script which would do the necessary things with the path, it worked in the terminal, but wouldn't work with an icon (a "launcher").

I finally got it working by using eclipse's command line option. I'm under WinXP now, so I can't go look, but IIRC, it's something like

eclipse -vm /usr/local/java1.5.0_04/bin/java.exe

(of course, use the path where you installed it in)


Oh, and Eclipse is a great Java-IDE. It does need a little getting used to, and it is rather slow (I'm always surprised with VS.NET's speed when I switch back to C#), and it has a few bugs, but otherwise... lots of good features, very customizable.
johnnyBravo
johnnyBravo
Quote:
Original post by SamLowry
but wouldn't work with an icon (a "launcher").

I finally got it working by using eclipse's command line option. I'm under WinXP now, so I can't go look, but IIRC, it's something like

eclipse -vm /usr/local/java1.5.0_04/bin/java.exe

(of course, use the path where you installed it in)



Did you edit a link file to the eclipse and put that line next to it?

Because I've created a link to eclipse.exe on the desktop, and I can't work out how to edit it so I can add the -vm /usr/..etc

Thanks

....Hey you didn't happen to install j2ee aswell? Because I'm trying to install that, which for some reason it does nothing when I try to use:
chmod +x /home/admin/Desktop/j2eesdk-1_4_02_2005Q2-linux.bin

as i have the j2ee bin on the desktop.

Like it worked fine for installing the jre sdk... but not j2ee
SamLowry
SamLowry
I'm a total linux newbie, so be careful with your terminology; I haven't got a clue what a "link file" is :). I'll assume for now that it is the linux equivalent of Windows's shortcuts.

I did create a shortcut ("launcher" as Ubuntu seems to call it), and I think you can right-click on it to edit its properties or something. It must be something simple (like you would do it with Windows), otherwise I never would've managed to do it.



No, I didn't try installing J2EE; I wasn't sure if I could have Java 1.5's new features (but now that I go look at sun's site, it seems I would).


The chmod +x thing just makes the file executable as far as I know. You still need to actually run it. (Sorry if I'm stating the obvious :))


I'll go take a look in Linux now.
SamLowry
SamLowry
Back.

I didn't actually install it, but I was only one press of a button away (didn't install it because I wouldn't know what to do with it).


So, I downloaded the same file as you, j2eesdk-1_4_02_2005Q2-linux.bin. It should be executable (if I'm not mistaken, if it's colored green when doing an ls, it is executable, or it should have an x next to it with ls -l.

-rwxr-xr-x 1 sam sam 132641077 2005-07-05 16:50 j2eesdk-1_4_02_2005Q2-linux.bin


I went to /usr/local, where I wanted to run it with

sudo ../../home/sam/Downloads/j2eesdk-1_4_02_2005Q2-linux.bin

but it gave me

../../home/sam/Downloads/j2eesdk-1_4_02_2005Q2-linux.bin: error while loading shared libraries: libstdc++- libc6.2-2.so.3: cannot open shared object file: No such file or directory


Forums said I needed to download that library, I tried with the package manager, but it seems it needs that exact version, which unfortunately wasn't available.
I found this. I downloaded the RPM containing the library..
This instructed me what how to convert it to a .deb: back in my Downloads directory, I did

sudo alien -d compat-libstdc++-7.3-2.96.118.i386.rpm

followed by

sudo dpkg -i compat-libstdc++_7.3-3.96_i386.deb


Then back to my /usr/local/ dir, I tried running the J2EE .bin file again

sudo ../../home/sam/Downloads/j2eesdk-1_4_02_2005Q2-linux.bin

and it gave me a nice little installation wizard. I stopped at the page with the overview of what was going to be installed, so possible there will be extra problems after that with which I can't help you :).

Good luck with it.
antareus
antareus
Quote:
Original post by Toolmaker
I'm running it on an AMD Athlon XP-64 3000+, and even at regular occassions, it just stops responding for half a second.

Ahhhh, the benefits of Java desktop applications. I have yet to find one I can stomach for daily use.
--God has paid us the intolerable compliment of loving us, in the deepest, most tragic, most inexorable sense.- C.S. Lewis
OrangyTang
OrangyTang
Quote:
Original post by Toolmaker
Why on earth would one use Eclipse? I'm running it on an AMD Athlon XP-64 3000+, and even at regular occassions, it just stops responding for half a second.

Theres a known issue where running Eclipse with the 1.5 JRE can cause strange stuttery behaviour like that. Perhaps try with 1.4 as that runs fine.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.