Updated macosx_ant build.xml, removed PPC support, bumped the minimum OS X SDK for 32/64bit native to SDK 10.5. Commented out some code in Display.m that required SDK 10.7+, namely NSApplicationPresentationFullScreen, etc

This commit is contained in:
kappa1 2012-11-01 22:21:23 +00:00
parent c09f5698b4
commit 2c811ac289
2 changed files with 14 additions and 13 deletions

View File

@ -3,7 +3,7 @@
<property name="native" location="../../src/native"/>
<target name="init">
<mkdir dir="ppc"/>
<!--mkdir dir="ppc"/-->
<mkdir dir="i386"/>
<mkdir dir="x86_64"/>
</target>
@ -12,7 +12,7 @@
<delete failonerror="false">
<fileset dir="i386"/>
<fileset dir="x86_64"/>
<fileset dir="ppc"/>
<!--fileset dir="ppc"/-->
<fileset dir="." includes="liblwjgl.jnilib"/>
<fileset dir="." includes="lwjgl.symbols"/>
</delete>
@ -46,21 +46,21 @@
<target name="nativelibrary" depends="init">
<property name="universal_sdkroot" location="/Developer/SDKs/MacOSX10.6.sdk"/>
<property name="ppc_sdkroot" location="/Developer/SDKs/MacOSX10.6.sdk"/>
<!--property name="ppc_sdkroot" location="/Developer/SDKs/MacOSX10.6.sdk"/-->
<property name="x86_64_sdkroot" location="/Developer/SDKs/MacOSX10.6.sdk"/>
<property name="universal_flags" value="-isysroot ${universal_sdkroot}"/>
<property name="ppc_flags" value="-isysroot ${ppc_sdkroot}"/>
<!--property name="ppc_flags" value="-isysroot ${ppc_sdkroot}"/>
<antcall target="compile">
<param name="dstdir" location="ppc"/>
<param name="compiler" value="gcc-4.2"/>
<param name="sdkroot" location="${ppc_sdkroot}"/>
<param name="cflags" value="${universal_flags} -arch ppc -mmacosx-version-min=10.3"/>
</antcall>
</antcall-->
<antcall target="compile">
<param name="dstdir" location="i386"/>
<param name="compiler" value="gcc-4.2"/>
<param name="sdkroot" location="${universal_sdkroot}"/>
<param name="cflags" value="${universal_flags} -arch i386 -mmacosx-version-min=10.4"/>
<param name="cflags" value="${universal_flags} -arch i386 -mmacosx-version-min=10.5"/>
</antcall>
<antcall target="compile">
<param name="dstdir" location="x86_64"/>
@ -72,12 +72,12 @@
<arg path="../../platform_build/macosx_ant/build-symbol-list"/>
<arg path="i386"/>
</exec>
<antcall target="link">
<!--antcall target="link">
<param name="objdir" location="ppc"/>
<param name="libname" value="liblwjgl-ppc.jnilib"/>
<param name="linker" value="gcc-4.2"/>
<param name="linkerflags" value="${universal_flags} -arch ppc -mmacosx-version-min=10.3"/>
</antcall>
</antcall-->
<antcall target="link">
<param name="objdir" location="i386"/>
<param name="libname" value="liblwjgl-i386.jnilib"/>
@ -95,7 +95,7 @@
<srcfile/>
<arg value="-output"/>
<arg path="liblwjgl.jnilib"/>
<fileset file="ppc/liblwjgl-ppc.jnilib"/>
<!--fileset file="ppc/liblwjgl-ppc.jnilib"/-->
<fileset file="i386/liblwjgl-i386.jnilib"/>
<fileset file="x86_64/liblwjgl-i86_64.jnilib"/>
</apply>

View File

@ -315,7 +315,7 @@ static NSOpenGLPixelFormat *default_format = nil;
}
- (void)scrollWheel:(NSEvent *)event {
JNIEnv *env = attachCurrentThread();
/*JNIEnv *env = attachCurrentThread();
if (env == nil || event == nil || _parent == nil) {
return;
}
@ -328,6 +328,7 @@ static NSOpenGLPixelFormat *default_format = nil;
jmethodID mousemove = (*env)->GetMethodID(env, mouse_class, "mouseMoved", "(FFFFFJ)V");
NSPoint loc = [self convertPoint:[event locationInWindow] toView:self];
(*env)->CallVoidMethod(env, _parent->jmouse, mousemove, loc.x, loc.y, [event deltaX], [event deltaY], dz, time);
*/
}
- (void)viewDidMoveToWindow
@ -492,9 +493,9 @@ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_MacOSXDisplay_nHideUI(JNIEnv *env,
MacOSXWindowInfo *window_info = (MacOSXWindowInfo *)(*env)->GetDirectBufferAddress(env, window_handle);
if(floor(NSAppKitVersionNumber) > NSAppKitVersionNumber10_5) {
NSApplicationPresentationOptions options = NSApplicationPresentationDefault;
/*NSApplicationPresentationOptions options = NSApplicationPresentationDefault;
if (hide == JNI_TRUE) {
options = NSApplicationPresentationFullScreen;
options = NSApplicationPresentationFullScreen; // this requires OS X 10.7+ to compile
options |= NSApplicationPresentationHideDock;
options |= NSApplicationPresentationHideMenuBar;
}
@ -502,7 +503,7 @@ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_MacOSXDisplay_nHideUI(JNIEnv *env,
window_info->window_options = options;
if (window_info->window != nil) {
[[NSApplication sharedApplication] setPresentationOptions:options];
}
}*/
} else {
if (hide == JNI_TRUE) {
SetSystemUIMode(kUIModeContentSuppressed, 0);