Question

I just created a new project using webAppCreator from GWT which worked fine. However, when I try to run ant hosted it fails with the following output:

 [java] On Mac OS X, ensure that you have Safari 3 installed.
 [java] Exception in thread "main" java.lang.UnsatisfiedLinkError: Unable to load required native library 'gwt-ll'.  Detailed error:
 [java] Can't load library: /usr/local/gwt-mac-1.7.1/libgwt-ll.dylib)
 [java] 
 [java] Your GWT installation may be corrupt
 [java]     at com.google.gwt.dev.shell.LowLevel.init(LowLevel.java:106)
 [java]     at com.google.gwt.dev.shell.mac.LowLevelSaf.init(LowLevelSaf.java:135)
 [java]     at com.google.gwt.dev.BootStrapPlatform.initHostedMode(BootStrapPlatform.java:68)
 [java]     at com.google.gwt.dev.HostedModeBase.<init>(HostedModeBase.java:362)
 [java]     at com.google.gwt.dev.SwtHostedModeBase.<init>(SwtHostedModeBase.java:127)
 [java]     at com.google.gwt.dev.HostedMode.<init>(HostedMode.java:271)
 [java]     at com.google.gwt.dev.HostedMode.main(HostedMode.java:230)

Related ANT task "hosted": <target name="hosted" depends="javac" description="Run hosted mode"> <java failonerror="true" fork="true" classname="com.google.gwt.dev.HostedMode"> <classpath> <pathelement location="src"/> <path refid="project.class.path"/> </classpath> <jvmarg value="-Xmx256M"/> <jvmarg value="${XstartOnFirstThreadFlag}"/> <!--<jvmarg value="${d32Flag}"/>--> <jvmarg value="-d32" /> <arg value="-startupUrl"/> <arg value="MyApplication.html"/> <!-- Additional arguments like -style PRETTY or -logLevel DEBUG --> <arg value="com.disney.MyApplication"/> </java> </target>

Was it helpful?

Solution

Copy or make a dynamic link of libgwt-ll.jnilib to libgwt-ll.dylib and try it again. Looks like someone else had a similar issue when using SoyLatte JVM. Details can be found here.

OTHER TIPS

Your hosted session is probably running in 64 bits and needs to run in 32 bit. See here for full details. Basically add the -d32 flag to the vm arguments in the Arguments section of the run configuration. You should only have to do this for run configs that existed before updating to 1.7.1. When I create a new run config the -d32 is populated for me.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top