I had some problems building the JNI code for Cocoa SWT on my MBP. First, I didn't want to get sidetracked by building a specific XulRunner SDK, so I just downloaded the 22.214.171.124 binary available from mozilla.org. Next, I had to make a couple minor modifications to org.eclipse.swt/Eclipse SWT PI/cocoa/library/make_macosx.mak. After specifying the proper location for XULRUNNER_SDK, I still ran into the following problem in the build:
[exec] /Library/Frameworks/XUL.framework/Versions/126.96.36.199-sdk/sdk/include/nsStringAPI.h:1053: error: size of array 'arg' is negativeThat line contains:
PR_STATIC_ASSERT(sizeof(wchar_t) == 2);A quick C program proved that wchar_t was actually 4 bytes on my machine. After commenting out the HAVE_CPP_2BYTE_WCHAR_T define in mozilla-config.h within my xulrunner install, I reran the build from Eclipse, and everything compiled. Now on to the actual work of adding NSFormatter and NSNumberFormatter to the JNI code.