jruby SWT MacOSX Launcher


/ Published in: Other
Save to your folder(s)



Copy this code and paste it in your HTML
  1. #!/bin/bash
  2. #
  3. # This command is used to launch jruby SWT apps on MacOSX
  4. # The key to run SWT apps on MacOSX you must pass Java two arguments
  5. # arguments:
  6. # -J -XstartOnFirstThread
  7. # -J -Djava.library.path=/path/to/swt.jar/directory/
  8. #
  9. # the -J option passes options directly to the java command
  10.  
  11. # Set SWT_PATH to the directory that contains your swt.jar file
  12. # For instance my swt.jar file is located at /Users/jamie/lib/swt/swt.jar
  13. # So the SWT_PATH var will be:
  14. # SWT_PATH=/Users/jamie/lib/swt
  15.  
  16. SWT_PATH="/path/to/swt.jar/directory"
  17. exec jruby -J -Djava.library.path=$SWT_PATH -J -XstartOnFirstThread $@
  18.  

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.