Main Page
Cookbook/Overview ImageMeister the jcprops file Licensing Please Vote! Binary Installation & Configuration [ Win · Mac · Nix · OSX ] Changes Public API Source Code Main Page Java [ Common · Win · Mac · Nix ] Native Code [ Common · Win · Mac · Nix ] Manifest Native Code Overviews [ Common · Win · Mac · Nix · Strings ] Macros [ General · Native Macros ] Walkthroughs [ Java only · Java and native ] Building [ Win · Mac · Nix · OSX ] Distribution Issues |
This version has been tested on OSX Server 10.1.
No special installation is required. It is recommended that you unzip the distribution file into/home/jconfig
. That way,mm.sh
might only require minimal editing. As described below, place libJConfigOSX.jnilib from thesamizdat/common
folder next to your application, or wherever it is in the application's library search path.
Other test apps include:
- Open MRJAppBuilder.
- In the 'Main classname' field, put
com.tolstoy.testjc.Tester
.- In the 'Classpath' box, enter the full path to JConfig.zip, followed by a colon, followed by the folder containing the CocoaJava classes. For instance,
/home/jconfig/samizdat/common/JConfig.zip:/System/Library/Java
. To find the CocoaJava classes, search for NSBundle.class.- Save the output file into the
/home/jconfig/samizdat/jconfig
folder, for instance asTester.app
.- Copy libJConfigOSX.jnilib from the
samizdat/common
folder next to your application, in this case in thesamizdat/jconfig
folder.com.tolstoy.testjc.DiskBrowser
,com.tolstoy.testjc.FileAttributesTest
,com.tolstoy.testjc.TestResFork
, andcom.tolstoy.testjc.MakeLink
.
- In order to properly initialize the MRJ VM, FileRegistryMRJ has to call an AWT method so AWT gets initialized before other calls to native code are made. This is an issue only if your application is non-GUI and you did not want to have any GUI code loaded. It only affects the amount of memory used by your application, and it shouldn't have any functional affect. FileRegistryMRJ initializes AWT by calling java.awt.Toolkit.getDefaultToolkit().getScreenSize(). It may be possible to remove that call if absolutely necessary, however that hasn't been tested and is not recommended.
- Likewise, FileRegistryMRJ initializes CocoaJava by calling CocoaUtilsOSX's init() method. The latter method calls NSBundle.mainBundle(), which causes the CocoaJava native code to be loaded correctly. It may be possible to remove that call if absolutely necessary, perhaps by stubbing out CocoaUtilsOSX.getFileTypes() to return null. However, of course, in that case you could not get the file types of an application. Currently, CocoaJava is only used by the CocoaUtilsOSX.getFileTypes() method.
Please send both the log file output (stdout/stderr) and the contents of the DebugWindow window. DebugWindow is included with the JConfig SDK.