Error Running Java SWT Application on Mac OSX - Advanced Installer Community
wbinns
Posts: 6
Joined: Fri Jul 19, 2013 12:05 am

Error Running Java SWT Application on Mac OSX

I have a Java Application that uses the Eclipse SWT framework. I created a Mac Application Bundle. When I ran it I got the error below:
9/11/13 11:40:43.483 PM [0x0-0x25025].com.Snap Legal Software LLC.SplitsEase Mac Edition.SplitsEase: ***WARNING: Display must be created on main thread due to Cocoa restrictions.

On the Eclipse SWT site I found that the -XstartOnFirstThread JVM parameter was required to allow SWT programs to run on OSX.

I added this parameter to the JVM Parameters on the Java Virtual Machine tab in AI. Now I get this error when I install and run the application:
9/11/13 11:40:43.233 PM JavaApplicationStub: Unrecognized Java VM option ignored: -XstartOnFirstThread

When I run the application directly from a command line the app launches correctly:
/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/bin/java -XstartOnFirstThread -jar SplitsEase.jar

Any thoughts on what is wrong?

Will Binns
Daniel
Posts: 8283
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Error Running Java SWT Application on Mac OSX

Hello Will,

You can see my response on "Error Running Mac PAckage" thread.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”