OpenGL ES build fixes.

This commit is contained in:
Ioannis Tsakpinis 2014-09-14 12:42:18 +03:00
parent f760abeb81
commit 202ce1d522
3 changed files with 9 additions and 11 deletions

View File

@ -4,7 +4,8 @@
<property name="native" location="../../src/native"/>
<property name="libname32" value="liblwjgl.so"/>
<property name="libname64" value="liblwjgl64.so"/>
<property name="libs32" value="-L/home/spasi/lwjgl/libs/linux -lEGL -L/usr/X11R6/lib -L/usr/X11/lib -lm -lX11 -lXext -lXcursor -lXrandr -lpthread -L${java.home}/lib/i386 -ljawt" />
<property name="lib_folder" value="${lwjgl.lib}/linux"/>
<property name="libs32" value="-L${lib_folder} -lEGL -L/usr/X11R6/lib -L/usr/X11/lib -lm -lX11 -lXext -lXcursor -lXrandr -lXxf86vm -lpthread -L${java.home}/lib/i386 -ljawt" />
<property name="libs64" value="-L${lib_folder}/x64 -lEGL -L/usr/X11R6/lib64 -L/usr/X11/lib64 -lm -lX11 -lXext -lXcursor -lXrandr -lXxf86vm -lpthread -L${java.home}/lib/amd64 -ljawt" />
<property name="cflags32" value="-O2 -Wall -c -fPIC -std=c99 -Wunused"/>
@ -21,9 +22,6 @@
<exec executable="uname" outputproperty="hwplatform">
<arg value="-m"/>
</exec>
<condition property="xf86vm_lib" value="-lXxf86vm" else="-Wl,-static,-lXxf86vm,-call_shared">
<os name="SunOS" />
</condition>
<condition property="cflags_pthread" value="-pthreads" else="-pthread">
<os name="SunOS" />
</condition>
@ -39,8 +37,8 @@
<os name="SunOS" />
</condition>
<property name="linker_flags32" value="${version_script_flags32} -shared -O2 -Wall -o ${libname32} ${libs32} ${xf86vm_lib}"/>
<property name="linker_flags64" value="${version_script_flags64} -shared -O2 -Wall -o ${libname64} ${libs64} ${xf86vm_lib}"/>
<property name="linker_flags32" value="${version_script_flags32} -shared -O2 -Wall -o ${libname32} ${libs32}"/>
<property name="linker_flags64" value="${version_script_flags64} -shared -O2 -Wall -o ${libname64} ${libs64}"/>
<condition property="build.32bit.only">
<not>
@ -126,4 +124,4 @@
<fileset file="${libname64}"/>
</apply>
</target>
</project>
</project>

View File

@ -53,7 +53,7 @@ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_CallbackUtil_deleteGlobalRef(JNIEnv
// ----------------- [ KHR_debug ] -----------------
static void APIENTRY debugCallbackKHR(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar* message, GLvoid* userParam) {
static void EGLAPIENTRY debugCallbackKHR(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar* message, GLvoid* userParam) {
JNIEnv *env = attachCurrentThread();
if ( env != NULL && !(*env)->ExceptionOccurred(env) && debugCallbackKHRJ != NULL ) {
@ -78,5 +78,5 @@ JNIEXPORT jlong JNICALL Java_org_lwjgl_opengl_CallbackUtil_getDebugCallbackKHR(J
debugCallbackKHRJ = (*env)->GetMethodID(env, callbackClass, "handleMessage", "(IIIILjava/lang/String;)V");
}
return (jlong)(intptr_t)&debugCallbackKHRJ;
return (jlong)(intptr_t)&debugCallbackKHR;
}

View File

@ -185,8 +185,8 @@ static void setWindowTitle(Display *disp, Window window, jlong title, jint len)
static void setClassHint(Display *disp, Window window, jlong wm_name, jlong wm_class) {
XClassHint* hint = XAllocClassHint();
hint->res_name = (const unsigned char *)(intptr_t)wm_name;
hint->res_class = (const unsigned char *)(intptr_t)wm_class;
hint->res_name = (char *)(intptr_t)wm_name;
hint->res_class = (char *)(intptr_t)wm_class;
XSetClassHint(disp, window, hint);