linamh/dev-util/cmake/files/cmake-FindJNI.patch

72 lines
2.0 KiB
Diff
Raw Normal View History

diff -ru ./Modules/FindJNI.cmake ../a/Modules/FindJNI.cmake
--- ./Modules/FindJNI.cmake 2009-02-21 21:36:50.000000000 +0100
+++ ../a/Modules/FindJNI.cmake 2008-11-24 04:44:06.000000000 +0100
@@ -2,7 +2,7 @@
# This module finds if Java is installed and determines where the
# include files and libraries are. It also determines what the name of
# the library is. This code sets the following variables:
-#
+#
# JNI_INCLUDE_DIRS = the include dirs to use
# JNI_LIBRARIES = the libraries to use
# JAVA_AWT_LIBRARY = the path to the jawt library
@@ -51,6 +51,8 @@
"${dir}"
"${dir}/client"
"${dir}/server"
+ "${dir}/j9vm"
+ "${dir}/classic"
)
ENDFOREACH(dir)
@@ -60,7 +62,7 @@
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\JavaSoft\\Java Development Kit\\1.3;JavaHome]/include"
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\JavaSoft\\Java Development Kit\\${java_install_version};JavaHome]/include"
$ENV{JAVA_HOME}/include
- /usr/include
+ /usr/include
/usr/local/include
/usr/lib/java/include
/usr/local/lib/java/include
@@ -126,7 +128,7 @@
)
ENDIF(JAVA_HAVE_FRAMEWORK)
ELSE(APPLE)
- FIND_LIBRARY(JAVA_AWT_LIBRARY jawt
+ FIND_LIBRARY(JAVA_AWT_LIBRARY jawt
PATHS ${JAVA_AWT_LIBRARY_DIRECTORIES}
)
FIND_LIBRARY(JAVA_JVM_LIBRARY NAMES jvm JavaVM
@@ -134,18 +136,23 @@
)
ENDIF(APPLE)
-# add in the include path
-FIND_PATH(JAVA_INCLUDE_PATH jni.h
+# add in the include path
+FIND_PATH(JAVA_INCLUDE_PATH jni.h
${JAVA_AWT_INCLUDE_DIRECTORIES}
)
-FIND_PATH(JAVA_INCLUDE_PATH2 jni_md.h
+FIND_PATH(JAVA_INCLUDE_PATH2 jni_md.h
${JAVA_AWT_INCLUDE_DIRECTORIES}
${JAVA_INCLUDE_PATH}/win32
${JAVA_INCLUDE_PATH}/linux
${JAVA_INCLUDE_PATH}/freebsd
)
+FIND_PATH(JAVA_INCLUDE_PATH2 jniport.h
+ ${JAVA_AWT_INCLUDE_DIRECTORIES}
+ ${JAVA_INCLUDE_PATH}
+)
+
FIND_PATH(JAVA_AWT_INCLUDE_PATH jawt.h
${JAVA_AWT_INCLUDE_DIRECTORIES}
${JAVA_INCLUDE_PATH}
@@ -169,4 +176,3 @@
${JAVA_INCLUDE_PATH2}
${JAVA_AWT_INCLUDE_PATH}
)
-