Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 333087

Summary: UnsatisfiedLinkError in Eclipse
Product: [Eclipse Project] JDT Reporter: Ahmet Ekrem SABAN <AhmetEkrem.Saban>
Component: APTAssignee: Generic inbox for the JDT-APT component <jdt-apt-inbox>
Status: RESOLVED INVALID QA Contact:
Severity: normal    
Priority: P3 CC: eclipse
Version: 3.7   
Target Milestone: ---   
Hardware: PC   
OS: Windows Vista   
Whiteboard:

Description Ahmet Ekrem SABAN CLA 2010-12-22 08:35:12 EST
Build Identifier: 20100517-1415

Hello!

Using Eclipse Helios Release (Build ID: 20100517-1415), I started a new project, but cannot start the run. Interestingly, other projects run without problems on this IDE installation before, but now, the error messages in the console is the same for all projects and reads: UnsatisfiedLinkError (see below). I cannot remember that I have changed anything with this installation so that nothing goes. I confess that I do not know well about Eclipse - I am merely a user.

I tried with the information on http://mindprod.com/applet/wassup.html and found out that the Java version is 1.6.0_22; so, a my version is up-to-date. As recommended on this site, I read out the parameters from the Applett (using the Microsoft Internet Explorer 9 beta; see below).

Probably, I have a path problem, as I myself do not use a native code. Therefore, I tried to add a java.library.path, but it was of no use.

When I call Eclipse, I select the workpath as C:\Users\<user name>\workspace\Java. The code of the new project is in the sub directory of .\src\Chapter01.

If I go in the Package Explorer (on the left) on the project with the right mouse button & select "Close Unrelated Projects", all other projects are closed; but then, I get instead of the error message above another error in a window:

Problem Occured_____________________________[_][O][x]

(x) 'Launching Main' has encountered a problem.
    Launch configuration Main references closed project Mobile.
               [ OK ] [ Details>> ]
____________________________________________________
Launch configuration Main references closed project Mobile
____________________________________________________

If I open the allegedly needed project 'Mobile', I get again the normal error message UnsatisfiedLinkError in the console window.

To your information: My project currently consists of one class only:
/**
 * 
 */
//package Chapter01;

/**
 *
 */
public class Apple {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO Auto-generated method stub

	}
}

I asked on other sites & got the tip that Eclipse assumes that my class is a MIDlet (JavaME). As a matter of fact, the project 'Mobile' I created some time ago is a J2ME project. To get rid of this problem, I saved the code to somewhere outside the workbench directory and removed all the projects. This time, I get the same error message in the dialog ('Launching Main' has encountered a problem) as above.

Thanks for all hints!

_Error message in the console window__________________________
Exception in thread "main" java.lang.UnsatisfiedLinkError: com.sun.midp.main.Configuration.getProperty0(Ljava/lang/String;)Ljava/lang/String;
	at com.sun.midp.main.Configuration.getProperty0(Native Method)
	at com.sun.midp.main.Configuration.getProperty(Configuration.java:32)
	at com.sun.midp.lcdui.Resource.<clinit>(Resource.java:30)
	at com.sun.midp.main.Main.initSystemLabels(Main.java:686)
	at com.sun.midp.main.Main.main(Main.java:103)

_CMP Wassup output____________________________________
acl.write.default = 

deployment.browser.path = C:\Program Files\Internet Explorer\iexplore.exe

deployment.cache.max.size = -1

deployment.console.startup.mode = HIDE

deployment.javapi.trace.filename = 

deployment.javaws.concurrentDownloads = 4

deployment.javaws.home.jnlp.url = http://java.sun.com/products/javawebstart

deployment.max.output.file.size = 10

deployment.repository.askdownloaddialog.show = true

deployment.security.askgrantdialog.notinca = true

deployment.security.blacklist.check = true

deployment.security.sandbox.awtwarningwindow = true

deployment.security.sandbox.jnlp.enhanced = true

deployment.system.security.blacklist = C:\Program Files\Java\jre6\lib\security\blacklist

deployment.system.security.trusted.jssecerts = C:\Program Files\Java\jre6\lib\security\trusted.jssecerts

deployment.user.logdir = C:\Users\<user name>\AppData\LocalLow\Sun\Java\Deployment\log

deployment.user.security.trusted.cacerts = C:\Users\<user name>\AppData\LocalLow\Sun\Java\Deployment\security\trusted.cacerts

deployment.user.security.trusted.jssecacerts = C:\Users\<user name>\AppData\LocalLow\Sun\Java\Deployment\security\trusted.jssecacerts

deployment.user.tmp = C:\Users\<user name>\AppData\LocalLow\Sun\Java\Deployment\tmp

file.encoding.pkg = sun.io

java.endorsed.dirs = C:\Program Files\Java\jre6\lib\endorsed

java.home = C:\Program Files\Java\jre6

java.protocol.handler.pkgs = sun.plugin.net.protocol|com.sun.deploy.net.protocol

java.runtime.name = Java(TM) SE Runtime Environment

java.vendor.applet = true

java.vendor.url = http://java.sun.com/

java.vendor.url.bug = http://java.sun.com/cgi-bin/bugreport.cgi

java.version = 1.6.0_22

java.version.applet = true

package.restrict.access.org.mozilla.jss = true

sun.io.unicode.encoding = UnicodeLittle

sun.jnu.encoding = Cp1252

sun.net.client.defaultConnectTimeout = 120000

sun.os.patch.level = Service Pack 2

user.name = <user name>



Reproducible: Always

Steps to Reproduce:
1. Create with my eclipse installation after removing all other projects a new Java project.
2. Give it a name, select JavaSE1.6 and click on [Finish]
3. Create the class Apple above and try to run it. It results in error messages here, although I am sure it will go with your installation...
Comment 1 Walter Harley CLA 2010-12-22 12:51:34 EST
Hi, Ekrem.  What you are describing does not sound like an Eclipse bug; it sounds like you have misconfigured your workspace, with a dependency on a project that was also misconfigured, and then in the course of trying to fix it by deleting the dependent project I suspect you ended up making it worse.  I would recommend creating a fresh workspace (in a different directory).  You can also post questions to either the eclipse.newcomer or eclipse.webtools forums to get assistance with learning how to use Eclipse.

By the way, I notice that in the configuration details you attached, the paths contain the literal string "<user name>".  Was that something that you edited in the bug report, or is that actually the name of the directory?  If the latter, I would definitely recommend against creating directories that contain the characters '<' or '>'.
Comment 2 Ahmet Ekrem SABAN CLA 2010-12-24 04:23:16 EST
Thank you for your hint. What you advise me is exactly what I have done: I renamed the workspace to another name, created all new and installed eclipse again, after removing the C:\Program Files\eclipse. Now, the project runs successfully.

Thank you again and I wish you the best for the holidays, and a happy new year!
Ekrem.Saban