From fdc20a0205bb01747055910eb2bb33202edee277 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sun, 17 Feb 2013 18:55:18 +0100 Subject: OSX/Java7 Cleanup: Remove JavaNativeFoundation dependency; NativeWindow-JAWT: Remove c.fixup.jawt.version.macosx (redundant, libjawt.dylib is rpath'ed always) --- make/build-nativewindow.xml | 19 ---------------- make/scripts/make.jogl.all.macosx-java7.sh | 2 +- make/scripts/make.jogl.all.macosx-java7u12ea.sh | 25 ++++++++++++++++++++++ make/scripts/tests-osx-x64-java7.sh | 2 +- make/scripts/tests-osx-x64-java7OnJava6build.sh | 12 +++++++++++ make/scripts/tests-osx-x64-java7u12ea.sh | 12 +++++++++++ .../tests-osx-x64-java7u12eaOnJava6Build.sh | 12 +++++++++++ src/nativewindow/native/macosx/OSXmisc.m | 7 ++---- 8 files changed, 65 insertions(+), 26 deletions(-) create mode 100755 make/scripts/make.jogl.all.macosx-java7u12ea.sh create mode 100755 make/scripts/tests-osx-x64-java7OnJava6build.sh create mode 100755 make/scripts/tests-osx-x64-java7u12ea.sh create mode 100755 make/scripts/tests-osx-x64-java7u12eaOnJava6Build.sh diff --git a/make/build-nativewindow.xml b/make/build-nativewindow.xml index 3c97d9d9b..a8408eaa7 100644 --- a/make/build-nativewindow.xml +++ b/make/build-nativewindow.xml @@ -361,7 +361,6 @@ - @@ -446,9 +445,6 @@ - - - @@ -735,20 +731,6 @@ - - - - - - - - - - - - diff --git a/make/scripts/make.jogl.all.macosx-java7.sh b/make/scripts/make.jogl.all.macosx-java7.sh index afb72bf8c..fc7ace9d0 100755 --- a/make/scripts/make.jogl.all.macosx-java7.sh +++ b/make/scripts/make.jogl.all.macosx-java7.sh @@ -22,4 +22,4 @@ ant \ -Dtarget.targetlevel=1.6 \ -Dtarget.rt.jar=/opt-share/jre1.6.0_30/lib/rt.jar \ -Drootrel.build=build-macosx-java7 \ - $* 2>&1 | tee make.jogl.all.macosx.log + $* 2>&1 | tee make.jogl.all.macosx-java7.log diff --git a/make/scripts/make.jogl.all.macosx-java7u12ea.sh b/make/scripts/make.jogl.all.macosx-java7u12ea.sh new file mode 100755 index 000000000..88f23b8ee --- /dev/null +++ b/make/scripts/make.jogl.all.macosx-java7u12ea.sh @@ -0,0 +1,25 @@ +#! /bin/sh + +if [ -e /opt-share/etc/profile.ant ] ; then + . /opt-share/etc/profile.ant +fi + + +# -Dc.compiler.debug=true \ +# -Djavacdebug="true" \ +# -Djavacdebuglevel="source,lines,vars" \ +# +# -Dtarget.sourcelevel=1.6 \ +# -Dtarget.targetlevel=1.6 \ +# -Dtarget.rt.jar=/opt-share/jre1.6.0_30/lib/rt.jar \ + +JAVA_HOME=`/usr/libexec/java_home -version 1.7.0_12` +PATH=$JAVA_HOME/bin:$PATH +export JAVA_HOME PATH + +ant \ + -Dtarget.sourcelevel=1.6 \ + -Dtarget.targetlevel=1.6 \ + -Dtarget.rt.jar=/opt-share/jre1.6.0_30/lib/rt.jar \ + -Drootrel.build=build-macosx-java7 \ + $* 2>&1 | tee make.jogl.all.macosx-java7u12ea.log diff --git a/make/scripts/tests-osx-x64-java7.sh b/make/scripts/tests-osx-x64-java7.sh index e1b07202b..e870d0752 100755 --- a/make/scripts/tests-osx-x64-java7.sh +++ b/make/scripts/tests-osx-x64-java7.sh @@ -8,5 +8,5 @@ export JAVA_HOME PATH spath=`dirname $0` -. $spath/tests.sh $JAVA_HOME/bin/java -d64 ../build-macosx $* +. $spath/tests.sh $JAVA_HOME/bin/java -d64 ../build-macosx-java7 $* diff --git a/make/scripts/tests-osx-x64-java7OnJava6build.sh b/make/scripts/tests-osx-x64-java7OnJava6build.sh new file mode 100755 index 000000000..e1b07202b --- /dev/null +++ b/make/scripts/tests-osx-x64-java7OnJava6build.sh @@ -0,0 +1,12 @@ +#! /bin/bash + +export DYLD_LIBRARY_PATH=/usr/local/lib:$DYLD_LIBRARY_PATH + +JAVA_HOME=`/usr/libexec/java_home -version 1.7` +PATH=$JAVA_HOME/bin:$PATH +export JAVA_HOME PATH + +spath=`dirname $0` + +. $spath/tests.sh $JAVA_HOME/bin/java -d64 ../build-macosx $* + diff --git a/make/scripts/tests-osx-x64-java7u12ea.sh b/make/scripts/tests-osx-x64-java7u12ea.sh new file mode 100755 index 000000000..a8c9bed77 --- /dev/null +++ b/make/scripts/tests-osx-x64-java7u12ea.sh @@ -0,0 +1,12 @@ +#! /bin/bash + +export DYLD_LIBRARY_PATH=/usr/local/lib:$DYLD_LIBRARY_PATH + +JAVA_HOME=`/usr/libexec/java_home -version 1.7.0_12` +PATH=$JAVA_HOME/bin:$PATH +export JAVA_HOME PATH + +spath=`dirname $0` + +. $spath/tests.sh $JAVA_HOME/bin/java -d64 ../build-macosx-java7 $* + diff --git a/make/scripts/tests-osx-x64-java7u12eaOnJava6Build.sh b/make/scripts/tests-osx-x64-java7u12eaOnJava6Build.sh new file mode 100755 index 000000000..dad9c430e --- /dev/null +++ b/make/scripts/tests-osx-x64-java7u12eaOnJava6Build.sh @@ -0,0 +1,12 @@ +#! /bin/bash + +export DYLD_LIBRARY_PATH=/usr/local/lib:$DYLD_LIBRARY_PATH + +JAVA_HOME=`/usr/libexec/java_home -version 1.7.0_12` +PATH=$JAVA_HOME/bin:$PATH +export JAVA_HOME PATH + +spath=`dirname $0` + +. $spath/tests.sh $JAVA_HOME/bin/java -d64 ../build-macosx $* + diff --git a/src/nativewindow/native/macosx/OSXmisc.m b/src/nativewindow/native/macosx/OSXmisc.m index 8d876c175..4c07b4df7 100644 --- a/src/nativewindow/native/macosx/OSXmisc.m +++ b/src/nativewindow/native/macosx/OSXmisc.m @@ -39,7 +39,6 @@ #include "jogamp_nativewindow_jawt_macosx_MacOSXJAWTWindow.h" #include -#import // #define VERBOSE 1 // @@ -740,8 +739,7 @@ JNIEXPORT jint JNICALL Java_jogamp_nativewindow_macosx_OSXUtil_GetScreenRefreshR (JNIEnv *env, jclass unused, jint scrn_idx) { int res = 0; - JNF_COCOA_ENTER(env); - // NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] init]; + NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] init]; NSScreen *screen = NewtScreen_getNSScreenByIndex((int)scrn_idx); DBG_PRINT("GetScreenRefreshRate.0: screen %p\n", (void *)screen); if(NULL != screen) { @@ -760,8 +758,7 @@ JNIEXPORT jint JNICALL Java_jogamp_nativewindow_macosx_OSXUtil_GetScreenRefreshR res = 60; // default .. (experienced on OSX 10.6.8) } DBG_PRINT("GetScreenRefreshRate.X: %d\n", (int)res); - // [pool release]; - JNF_COCOA_EXIT(env); + [pool release]; return res; } -- cgit v1.2.3