Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 320600 - Launcher (eclipse.exe) might use incompatible JRE when a jre folder is present
Summary: Launcher (eclipse.exe) might use incompatible JRE when a jre folder is present
Status: CLOSED WONTFIX
Alias: None
Product: Equinox
Classification: Eclipse Project
Component: Launcher (show other bugs)
Version: 3.6   Edit
Hardware: PC Windows 7
: P3 normal with 1 vote (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-22 05:18 EDT by Juergen Baier CLA
Modified: 2019-05-02 08:39 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Juergen Baier CLA 2010-07-22 05:18:16 EDT
Build Identifier: I20100608-0911

When you put a jre folder in your eclipse installation, then the launcher will use this jre folder always. However, if you have a 64-bit eclipse installed and the eclipse folder contains a 32-bit JRE then the launcher will use this JRE. This will (of course) fail with the following message

Failed to load the JNI shared library "C:\Program Files\eclipse\jre\bin\client\jvm.dll
.

I think this is not a very good error message. I can think of two possible actions when this kind of error occurs:

1. Show an appropriate error message ("64-bit Eclipse cannot work with 32-bit JRE located in ...").

2. If the launcher detects an incompatible JRE it could ignore this JRE and proceed with the other options for finding a compatible JRE.

Details:

If I run with -consolelog -debug I get

Start VM: -Xms40m
-Xmx1000m
-XX:MaxPermSize=256m
-Djava.class.path=c:\Program Files\eclipse\plugins/org.eclipse.equinox.launcher_
1.1.0.v20100507.jar
-os win32
-ws win32
-arch x86_64
-showsplash c:\Program Files\eclipse\\plugins\org.eclipse.platform_3.6.0.v201006
080911\splash.bmp
-launcher c:\Program Files\eclipse\eclipse.exe
-name Eclipse
--launcher.library c:\Program Files\eclipse\plugins/org.eclipse.equinox.launcher
.win32.win32.x86_64_1.1.0.v20100503\eclipse_1307.dll
-startup c:\Program Files\eclipse\plugins/org.eclipse.equinox.launcher_1.1.0.v20
100507.jar
-consolelog
-debug
-vm c:\Program Files\eclipse\jre\bin\client\jvm.dll
-vmargs
-Xms40m
-Xmx1000m
-XX:MaxPermSize=256m
-Djava.class.path=c:\Program Files\eclipse\plugins/org.eclipse.equinox.launcher_
1.1.0.v20100507.jar


Reproducible: Always

Steps to Reproduce:
1. Download and install a 64-bit Eclipse
2. Copy a 32-bit JRE in $ECLIPSE_INSTALL_DIR/jre
3. Start Eclipse

=> Strange error message appears.
Comment 1 John Arthorne CLA 2010-07-28 17:16:47 EDT
I guess this can be viewed as a general request to improve the error message when attempting to launch Eclipse 64-bit with a 32-bit JRE.
Comment 2 Eclipse Genie CLA 2019-05-02 08:39:14 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.