4 Replies Latest reply: Oct 9, 2013 4:11 AM by 984537 RSS

    UnsatisfiedLinkError starting from commandline


      when I start my JavaFX application from Netbeans, all is fine.
      When I start it from the commandline ( Java -jar inventarum.jar ) I get a Runtimeexception.
      Do you have any hint for me.

      java.lang.UnsatisfiedLinkError: com.sun.deploy.config.WinPlatform.getPlatformUserHome()Ljava/lang/String;
           at com.sun.deploy.config.WinPlatform.getPlatformUserHome(Native Method)
           at com.sun.deploy.config.WinPlatform.getUserHome(Unknown Source)
           at com.sun.deploy.config.WinPlatform.getLocalStorageDir(Unknown Source)
           at com.sun.deploy.config.Config.getLocalStorageDir(Unknown Source)
           at com.sun.deploy.config.Config.getDefaultCacheDirectory(Unknown Source)
           at com.sun.deploy.config.DefaultConfig.init(Unknown Source)
           at com.sun.deploy.config.DefaultConfig.<init>(Unknown Source)
           at com.sun.deploy.config.DefaultConfig.getDefaultConfig(Unknown Source)
           at com.sun.deploy.config.Config.get(Unknown Source)
           at com.sun.deploy.net.proxy.UserDefinedProxyConfig.getBrowserProxyInfo(Unknown Source)
           at com.sun.deploy.net.proxy.DynamicProxyManager.reset(Unknown Source)
           at com.sun.deploy.net.proxy.DeployProxySelector.reset(Unknown Source)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.lang.reflect.Method.invoke(Method.java:601)
           at com.javafx.main.Main.tryToSetProxy(Main.java:572)
           at com.javafx.main.Main.launchApp(Main.java:640)
           at com.javafx.main.Main.main(Main.java:805)
        • 1. Re: UnsatisfiedLinkError starting from commandline
          Are you using 64bit windows, and 64bit JDK? You might need to install 32 bit JDK, and start your app with that.

          Edited by: Steven Tong on 2012-12-11 上午5:34
          • 2. Re: UnsatisfiedLinkError starting from commandline
            I think 'UnsatisfiedLinkError' means that java can't find the necessary JNI-related files.

            You can use -Djava.library.path to specify additional paths where Java should search for JNI files.
            For example,
            java -Djava.library.path=./additional_directory -jar myRunnable.jar

            Btw, I'm using Mac.
            • 3. Re: UnsatisfiedLinkError starting from commandline
              For the problem "java.lang.UnsatisfiedLinkError: com.sun.deploy.config.WinPlatform.getPlatformUserHome()Ljava/lang/String;"
              I have also encounter the problem with 64 bit Windows7 SP1 and 64 bit JRE6 enviorment.

              And after I install 32bit JRE6 and login JNPL file, can open JNPL file, then use 64bit JRE6 can also login JNPl file, there would no above problem.

              But I don't know why and how to resolve the just 64bit JRE6 problem.

              Edited by: 981534 on May 20, 2013 7:23 PM
              • 4. Re: UnsatisfiedLinkError starting from commandline

                I encounter the same case, but the case is not launch JavaFX, is normal Swing program. But it just for some one's machine, for others, there is no related problem.

                And after uninstall the 64bit JRE and then install the JRE again, can not reproduce the problem.


                For other machine, can not reproduce the case easily.