[FIXED] OSX / Java 7

Started by normen, August 14, 2012, 17:07:59

Previous topic - Next topic

avm1979

Gave this a try just now, with Starfarer on OS X 10.6

Having some issues running Java 7 - getting:
Symbol not found: _JNFRunLoopDidStartNotification
  Referenced from: /Users/amosolov/starfarer/Starfarer.app/Contents/Home/lib/server/../libosxapp.dylib


That may be me doing something silly, and doesn't seem to be related to LWJGL (would appreciate any advice, though!)


Then I tried running the test build with Java 6 (should work, right?). That ran, but had a few issues (apologies if these are already known):
Mouse.getX() / Mouse.getY():
Once you press and hold down a mouse button, it returns the coordinates where the press originally happened, and doesn't update when you move the mouse. Once you release the button, the coordinates are still stuck on where the button was originally pressed until you move the mouse again, at which point it updates. This happens for both the left and right buttons.

Mouse.getDWheel() always returns 0.

Also got a segmentation fault on exit.


This is awesome, though - can't wait to be able to ship with Java 7. Although, for some reason, the JRE is 170 megs? Need to take a closer look to see why in the world it's so much bigger.

macdonag

Using the libs in the zip, I get the following error trying to run TheQuadExampleColored.java (OSX 10.8.2):

Window handle is null
Resizeable
2012-11-03 21:25:55.226 java[9055:1703] An uncaught exception was raised
2012-11-03 21:25:55.227 java[9055:1703] *** Collection <__NSSetM: 0x7fa13b485c50> was mutated while being enumerated.
2012-11-03 21:25:55.228 java[9055:1703] (
   0   CoreFoundation                      0x00007fff8c58f0a6 __exceptionPreprocess + 198
   1   libobjc.A.dylib                     0x00007fff8f8d83f0 objc_exception_throw + 43
   2   CoreFoundation                      0x00007fff8c622f98 __NSFastEnumerationMutationHandler + 232
   3   AppKit                              0x00007fff8d3d195e -[NSView trackingAreas] + 254
   4   AppKit                              0x00007fff8d4b835b -[NSView(NSInternal) _enableOrDisableTrackingAreas] + 96
   5   AppKit                              0x00007fff8d4c18f5 -[NSFrameView _windowChangedKeyState] + 93
   6   AppKit                              0x00007fff8d4c138e -[NSWindow _setFrameNeedsDisplay:] + 169
   7   AppKit                              0x00007fff8d4c5770 -[NSWindow becomeMainWindow] + 41
   8   AppKit                              0x00007fff8d4bf073 -[NSWindow _changeKeyAndMainLimitedOK:] + 830
   9   AppKit                              0x00007fff8d4be86b -[NSWindow _makeKeyRegardlessOfVisibility] + 104
   10  AppKit                              0x00007fff8d4be7c5 -[NSWindow makeKeyAndOrderFront:] + 25
   11  liblwjgl.jnilib                     0x0000000164490e3a Java_org_lwjgl_opengl_MacOSXDisplay_nCreateWindow + 538
   12  ???                                 0x0000000108b51f90 0x0 + 4441055120
   13  ???                                 0x0000000108b46333 0x0 + 4441006899
   14  ???                                 0x0000000108b46806 0x0 + 4441008134
   15  ???                                 0x0000000108b46158 0x0 + 4441006424
   16  ???                                 0x0000000108b46158 0x0 + 4441006424
)
2012-11-03 21:25:55.228 java[9055:1703] *** Terminating app due to uncaught exception 'NSGenericException', reason: '*** Collection <__NSSetM: 0x7fa13b485c50> was mutated while being enumerated.'
*** First throw call stack:
(
   0   CoreFoundation                      0x00007fff8c58f0a6 __exceptionPreprocess + 198
   1   libobjc.A.dylib                     0x00007fff8f8d83f0 objc_exception_throw + 43
   2   CoreFoundation                      0x00007fff8c622f98 __NSFastEnumerationMutationHandler + 232
   3   AppKit                              0x00007fff8d3d195e -[NSView trackingAreas] + 254
   4   AppKit                              0x00007fff8d4b835b -[NSView(NSInternal) _enableOrDisableTrackingAreas] + 96
   5   AppKit                              0x00007fff8d4c18f5 -[NSFrameView _windowChangedKeyState] + 93
   6   AppKit                              0x00007fff8d4c138e -[NSWindow _setFrameNeedsDisplay:] + 169
   7   AppKit                              0x00007fff8d4c5770 -[NSWindow becomeMainWindow] + 41
   8   AppKit                              0x00007fff8d4bf073 -[NSWindow _changeKeyAndMainLimitedOK:] + 830
   9   AppKit                              0x00007fff8d4be86b -[NSWindow _makeKeyRegardlessOfVisibility] + 104
   10  AppKit                              0x00007fff8d4be7c5 -[NSWindow makeKeyAndOrderFront:] + 25
   11  liblwjgl.jnilib                     0x0000000164490e3a Java_org_lwjgl_opengl_MacOSXDisplay_nCreateWindow + 538
   12  ???                                 0x0000000108b51f90 0x0 + 4441055120
   13  ???                                 0x0000000108b46333 0x0 + 4441006899
   14  ???                                 0x0000000108b46806 0x0 + 4441008134
   15  ???                                 0x0000000108b46158 0x0 + 4441006424
   16  ???                                 0x0000000108b46158 0x0 + 4441006424
)
libc++abi.dylib: terminate called throwing an exception

refD

I'm getting a similar hang when trying to run my game (JVM is 1.7.0_05-b06 and OS X 10.8.2) :

   Window handle is null
    Resizeable


Which occurs in my GLDisplay.create() call (requesting the core profile 3.2).

The furthest I can see down the stack trace (using a debug session):

main@1, prio=5, in group 'main', status: 'RUNNING'
    at org.lwjgl.opengl.MacOSXDisplay.nCreateWindow(MacOSXDisplay.java:-1)
    at org.lwjgl.opengl.MacOSXDisplay.createWindow(MacOSXDisplay.java:138)
    at org.lwjgl.opengl.Display.createWindow(Display.java:303)
    at org.lwjgl.opengl.Display.create(Display.java:845)
    at org.lwjgl.opengl.Display.create(Display.java:794)
    ...


I'm not sure how to get the full stack trace, it's just strangely hanging when it reaches the error, even with a debug session attached, and I'm not getting any native stack frames ... hell, it's not even raising an exception, this is really odd.

Edit: Happy to test builds/nightlies/anything ... having LWJGL on JRE7 (especially now that 10.8.2 no longer offers easy switching) would be an insanely good thing and makes me wish I knew enough about OS X's windowing system to help.

kappa

Thanks for all the reports and testing. As way of summary from all the above information the following issues are outstanding:-

1) A native crash on exist when calling Display.destroy() on window close, happens in two locations nDestroyWindow method inside Display.m and nUnregisterMouseListenermethod inside method MacOSXNativeMouse.m.

2) Another native crash related to "Collection <__NSSetM: 0x7f911905f3c0> was mutated while being enumerated". A full exception reported here and again here and again here.

3) Mouse.getDWheel() not yet implemented properly, there is working code in the source code inside Display.m in method scrollWheel. However this is currently implemented using OS X 10.7+ API's therefore commented out to allow compilation and compatibility on lower OS X versions.

4) When you go fullscreen, then go back to windowed mode, resizing no longer appears to work.

5) When you go fullscreen, the menu bar and dock do not disappear, there is some code in Display.m inside method nHideUI, however was using OS X 10.7 API's so was commented out to allow compilation and compatibility on lower OS X versions.

6) Native cursor support not yet implemented.

7) Mouse.getX() / Mouse.getY() not being properly polled when button is held down.

8 ) Clean up debug code (println's etc) once above is fixed.

9) Implement Display.getX() and Display.getY() to update on window move.

10) Mouse.setCursorPosition() doesn't set the mouse to the correct location.

@avm1979 As a guess to your Java 7 issue, from the information provided, it seems it can't find JNF (Java Native Foundation) a helper library by Apple, as far as I recall this wasn't included in earlier builds of Java 7 for OS X, not sure if they added it to newer Oracle Java 7 releases, maybe try a newer version of Java 7 (just curious, which version of Java 7 were you testing with?).

Hope the above is a helpful summary, especially for those wanting to have a go at trying to fix some of the above issues.

avm1979

Quote from: kappa on November 04, 2012, 14:45:39
@avm1979 As a guess to your Java 7 issue, from the information provided, it seems it can't find JNF (Java Native Foundation) a helper library by Apple, as far as I recall this wasn't included in earlier builds of Java 7 for OS X, not sure if they added it to newer Oracle Java 7 releases, maybe try a newer version of Java 7 (just curious, which version of Java 7 were you testing with?).

$ ./java -version
java version "1.7.0_09"
Java(TM) SE Runtime Environment (build 1.7.0_09-b05)
Java HotSpot(TM) 64-Bit Server VM (build 23.5-b02, mixed mode)


That looks to be the latest, as far as I can tell - downloaded the .tar.gz from Oracle yesterday. The .dmg doesn't support 10.6, says it requires OS X Lion (10.7) to install. I wonder if this means that Java 7 isn't supported on 10.6, period? Do you know if there's somewhere I can grab JNF to give it a try? Spent a while googling around for it, to no avail.

kappa

Quote from: avm1979 on November 04, 2012, 19:32:21
Quote from: kappa on November 04, 2012, 14:45:39
@avm1979 As a guess to your Java 7 issue, from the information provided, it seems it can't find JNF (Java Native Foundation) a helper library by Apple, as far as I recall this wasn't included in earlier builds of Java 7 for OS X, not sure if they added it to newer Oracle Java 7 releases, maybe try a newer version of Java 7 (just curious, which version of Java 7 were you testing with?).

$ ./java -version
java version "1.7.0_09"
Java(TM) SE Runtime Environment (build 1.7.0_09-b05)
Java HotSpot(TM) 64-Bit Server VM (build 23.5-b02, mixed mode)


That looks to be the latest, as far as I can tell - downloaded the .tar.gz from Oracle yesterday. The .dmg doesn't support 10.6, says it requires OS X Lion (10.7) to install. I wonder if this means that Java 7 isn't supported on 10.6, period? Do you know if there's somewhere I can grab JNF to give it a try? Spent a while googling around for it, to no avail.
Yeh IIRC, Java 7 will be OS X 10.7+ only so the system JRE's on OS X 10.5 and 10.6 will need to be used. JNF comes with Java 6 but don't think it'll work with Java 7 since Apple haven't released the code for it.

In any event, I had a look further into the LWJGL OS X code to see why JavaNativeFoundation was needed and found a few unused references to it, have removed them now, I'm guessing it should work now, please do test build below.

Latest test build: https://www.dropbox.com/s/b6gj27dmoyo0h0j/macosx.zip

avm1979

Gave that a try - same thing, but looks like it's actually not being triggered from LWJGL. Sorry for not pasting the whole thing earlier.

Exception in thread "main" java.lang.UnsatisfiedLinkError: /Users/amosolov/starfarer/Starfarer.app/Contents/Home/lib/lwawt/liblwawt.dylib: dlopen(/Users/amosolov/starfarer/Starfarer.app/Contents/Home/lib/lwawt/liblwawt.dylib, 1): Symbol not found: _JNFRunLoopDidStartNotification
  Referenced from: /Users/amosolov/starfarer/Starfarer.app/Contents/Home/lib/server/../libosxapp.dylib
  Expected in: /System/Library/Frameworks/JavaVM.framework/Versions/A/Frameworks/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation
 in /Users/amosolov/starfarer/Starfarer.app/Contents/Home/lib/server/../libosxapp.dylib
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1939)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1864)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1825)
	at java.lang.Runtime.load0(Runtime.java:792)
	at java.lang.System.load(System.java:1059)
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1939)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1864)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1846)
	at java.lang.Runtime.loadLibrary0(Runtime.java:845)
	at java.lang.System.loadLibrary(System.java:1084)
	at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:67)
	at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:47)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.Toolkit.loadLibraries(Toolkit.java:1648)
	at java.awt.Toolkit.<clinit>(Toolkit.java:1670)
	at java.awt.Color.<clinit>(Color.java:275)
	at com.fs.starfarer.StarfarerLauncher.<init>(Unknown Source)
	at com.fs.starfarer.StarfarerLauncher.main(Unknown Source)


Thank you for clarifying about JNF. Seems kind of weird for Java to have a dependency like that, but oh well.

kappa

Oh it looks like its AWT that has dependencies on JNF (you have a launcher or something that uses it?). It would be expected for AWT on OS X since Apple use to maintain it. However what is odd is that they didn't include it with Java 7 and/or left the dependencies in there (maybe a Java 7 bug?).

In any event it was good you ran into the above issues as we've cleared out dependences on JNF from LWJGL because of it.

abcdef

The JNF Framework with Oracle is a Framework within a Framework, in the build.xml you need to tell it the location. I had this working is some really early tests I did (before EMUMog started). I'm at work at the moment but I'll post something later showing how I fixed that issue.

avm1979

Quote from: kappa on November 04, 2012, 21:36:22
Oh it looks like its AWT that has dependencies on JNF (you have a launcher or something that uses it?). It would be expected for AWT on OS X since Apple use to maintain it. However what is odd is that they didn't include it with Java 7 and/or left the dependencies in there (maybe a Java 7 bug?).

Yeah, a launcher, and java.awt.Color pretty much everywhere. If I can nuke the latter with some broad-spectrum search & replace, I'll bypass the launcher and try it again on 10.6 - curious to see if it can work, or if some other internal Java dependency on it will pop up.

Edit: Gave bypassing the launcher a try. This is the result:
java.lang.UnsatisfiedLinkError: /Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/lwawt/liblwawt.dylib: dlopen(/Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/lwawt/liblwawt.dylib, 1): Symbol not found: _JNFRunLoopDidStartNotification
  Referenced from: /Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/server/../libosxapp.dylib
  Expected in: /System/Library/Frameworks/JavaVM.framework/Versions/A/Frameworks/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation
 in /Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/server/../libosxapp.dylib
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1939)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1864)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1825)
	at java.lang.Runtime.load0(Runtime.java:792)
	at java.lang.System.load(System.java:1059)
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1939)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1864)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1846)
	at java.lang.Runtime.loadLibrary0(Runtime.java:845)
	at java.lang.System.loadLibrary(System.java:1084)
	at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:67)
	at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:47)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.Toolkit.loadLibraries(Toolkit.java:1648)
	at java.awt.Toolkit.<clinit>(Toolkit.java:1670)
	at org.lwjgl.MacOSXSysImplementation.<clinit>(MacOSXSysImplementation.java:49)
	at org.lwjgl.Sys.createImplementation(Sys.java:130)
	at org.lwjgl.Sys.<clinit>(Sys.java:111)
	at com.fs.profiler.Profiler.<clinit>(Profiler.java:224)
	at com.fs.starfarer.combat.CombatMain.main(CombatMain.java:88)


So, looks like JNF is still required by something.

macdonag

I should also add, as I don't think it's been mentioned, that the branch doesn't build on my machine.  After I've changed the references to gcc-4.2 to gcc, and the references to the 10.6 SDK path to the 10.7 SDK path, I get the following errors:

    [apply] /Users/graham/Documents/Code/svn/java-game-lib/LWJGL/src/native/macosx/org_lwjgl_opengl_MacOSXNativeKeyboard.m:47:50: error: org_lwjgl_opengl_MacOSXNativeKeyboard.h: No such file or directory

    [apply] /Users/graham/Documents/Code/svn/java-game-lib/LWJGL/src/native/macosx/org_lwjgl_opengl_MacOSXNativeMouse.m:47:47: error: org_lwjgl_opengl_MacOSXNativeMouse.h: No such file or directory


If I remove the #imports, it seems to build correctly.  (Though I then get the mutated collection during enumeration crash.)  I'm building on 10.8.2.

mc78

Attaching my fixes for build.xml:

Adding support for:
- Xcode location discovery
- Mac OS SDK discovery
- JavaVM.framework discovery
- gcc vs gcc-4.2 discovery

kappa

mc78 really nice job, patch committed, keep them coming :)

@macdonag try now with the latest svn code it has mc78's patch applied.

@avm1979 thanks for continuing to test and provide updates, looking into the OS X implementation of LWJGL's Sys class, there was actually some old code in there that started the AWT Toolkit to work around a bug in OS X 10.3, removed it, hopefully there won't any be other dependancies on AWT when running just the native Display.

Latest build for testing: https://www.dropbox.com/s/b6gj27dmoyo0h0j/macosx.zip

avm1979

Looks like Sys.alert still triggers AWT loading (that's probably expected, though):

Exception in thread "main" java.lang.UnsatisfiedLinkError: /Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/lwawt/liblwawt.dylib: dlopen(/Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/lwawt/liblwawt.dylib, 1): Symbol not found: _JNFRunLoopDidStartNotification
  Referenced from: /Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/server/../libosxapp.dylib
  Expected in: /System/Library/Frameworks/JavaVM.framework/Versions/A/Frameworks/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation
 in /Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/server/../libosxapp.dylib
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1939)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1864)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1825)
	at java.lang.Runtime.load0(Runtime.java:792)
	at java.lang.System.load(System.java:1059)
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1939)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1864)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1846)
	at java.lang.Runtime.loadLibrary0(Runtime.java:845)
	at java.lang.System.loadLibrary(System.java:1084)
	at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:67)
	at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:47)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.Toolkit.loadLibraries(Toolkit.java:1648)
	at java.awt.Toolkit.<clinit>(Toolkit.java:1670)
	at javax.swing.UIManager.getSystemLookAndFeelClassName(UIManager.java:608)
	at org.lwjgl.J2SESysImplementation.alert(J2SESysImplementation.java:52)
	at org.lwjgl.Sys.alert(Sys.java:208)
	at com.fs.starfarer.combat.CombatMain.main(CombatMain.java:352)


Hmm. Tried getting a little further, and getting the same JNF dependency from various core Java classes - ImageIO, Preferences, etc. So, it's probably too much of a quagmire, trying to figure out which subset of Java isn't going to set it off.

Tried a more standalone test (a bit of test code for particle systems, creates a display and renders some stuff, doesn't do much else):

Exception in thread "main" java.lang.UnsatisfiedLinkError: /Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/lwawt/liblwawt.dylib: dlopen(/Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/lwawt/liblwawt.dylib, 1): Symbol not found: _JNFRunLoopDidStartNotification
  Referenced from: /Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/server/../libosxapp.dylib
  Expected in: /System/Library/Frameworks/JavaVM.framework/Versions/A/Frameworks/JavaNativeFoundation.framework/Versions/A/JavaNativeFoundation
 in /Users/amosolov/starfarer/java7/jre1.7.0_09.jre/Contents/Home/lib/server/../libosxapp.dylib
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1939)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1864)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1825)
	at java.lang.Runtime.load0(Runtime.java:792)
	at java.lang.System.load(System.java:1059)
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1939)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1864)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1846)
	at java.lang.Runtime.loadLibrary0(Runtime.java:845)
	at java.lang.System.loadLibrary(System.java:1084)
	at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:67)
	at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:47)
	at java.security.AccessController.doPrivileged(Native Method)
	at sun.awt.CGraphicsEnvironment.<clinit>(CGraphicsEnvironment.java:61)
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:186)
	at java.awt.GraphicsEnvironment.createGE(GraphicsEnvironment.java:102)
	at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:81)
	at org.lwjgl.opengl.MacOSXDisplay.getDevice(MacOSXDisplay.java:206)
	at org.lwjgl.opengl.MacOSXDisplay.init(MacOSXDisplay.java:239)
	at org.lwjgl.opengl.Display.<clinit>(Display.java:135)
	at org.lwjgl.util.Display.getAvailableDisplayModes(Display.java:71)
	at com.fs.graphics.LWJGL2DInitializer.setDisplayMode(LWJGL2DInitializer.java:116)
	at com.fs.graphics.LWJGL2DInitializer.init(LWJGL2DInitializer.java:41)
	at com.fs.starfarer.renderers.damage.ExplosionParticleSystem.main(ExplosionParticleSystem.java:224)


Well, the good news is it works with Java 6. Thank you for having taken the time to look into it.

abcdef

This is what I have in the build.xml for the args in compile target for the JNF

<arg line="${cflags} -ObjC -O2 -Wall -Wunused -c -fPIC -I${native}/common -I${native}/common/opengl -I${native}/macosx -I/System/Library/Frameworks/JavaVM.framework/Frameworks/JavaNativeFoundation.framework/Headers  -I/Library/Java/JavaVirtualMachines/jdk1.7.0_06.jdk/Contents/Home/include"/>


and in link

<arg line="${linkerflags} -exported_symbols_list ../lwjgl.symbols -dynamiclib -o ${libname} -F/System/Library/Frameworks/JavaVM.framework/Frameworks -framework /JavaNativeFoundation -L/Library/Java/JavaVirtualMachines/jdk1.7.0_06.jdk/Contents/Home/jre/lib -l libjawt.dylib -framework AppKit -framework CoreFoundation -framework OpenGL"/>