Been awhile since I’d set this up…
IIRC and assuming that nothing has changed in Eclipse the past few variations,
- You don’t need to “properly” install Java in a machine to use in Eclipse. If you look at the Eclipse advanced settings, you will see a section devoted to Java and all you need to do is configure those paths to point to the Java you want. Re-configuration if this section is required regardless how Java exists on the system.
Now, as for multiple Java on the same machine…
Several distros use the update-alternatives subsystem, and openSUSE was one of the first to do so. When you configure Java as an update-alternatives option, it’s easy to switch from one Java to another.
So, here are a few links to get you started…
The official guide (SDB) how to install the Oracle JDK (and less importantly the JRE) on openSUSE
https://en.opensuse.org/SDB:Installing_Java
Note that the SDB only describes installing Oracle Java 7, I’ve taken a deep look at the procedure and it won’t work for Oracle 8. Unless and until someone is willing to do the work (or work with me on doing so) I don’t know when the SDB will be updated to support Oracle 8. If you do decide to install Oracle 7, I strongly recommend you look at the discussion to the SDB
https://en.opensuse.org/SDB_Talk:Installing_Java
And even consider simply running the 3 scripts I created that IMO vastly improve on the basic stuff the SDB describes. Instead of a half hour or longer, you’ll have Oracle 7 installed in about 15 seconds (after downloading the Oracle package)
https://github.com/putztzu/openSUSE_Oracle_Java_Install
If anyone is interested in seeing how it’s possible to maintain separate Java implementations, you can inspect either the guts of the SDB or my scripts, they describe how the actual files are kept separate but sym-linked to the library location all apps expect to find Java.
For those who may have only a passing interest why this is important, it’s because only Oracle Java can provide a fully functional Java compiler. If you’re not a developer and only need the JRE, then “any” non-Oracle Java is sufficient and is why openJDK is distributed as only a JRE (despite its name). You can build an openJDK Java compiler, but the packages you build won’t run on all Java.
For the time being, If you must run Oracle 8 and not Oracle 7, I recommend using virtualization to run your Oracle 8 Dev environment in its own configuration. When the Oracle 8 install on openSUSE install is worked out, then an update-alternatives configuration can be created and then you’ll be able to run multiple Java on the same machine.
TSU