On 29. Oct, 2009, at 13:35 , Bill Hoffman wrote:

Mathieu Malaterre wrote:

# ok we found jni.h, now derive other location from it:
get_filename_component(jni_path ${JAVA_INCLUDE_PATH} PATH)
FIND_PATH(JAVA_INCLUDE_PATH2 jni_md.h
 ${jni_path}
 ${jni_path}/win32
 ${jni_path}/linux
 ${jni_path}/freebsd
)
FIND_PATH(JAVA_AWT_INCLUDE_PATH jawt.h
 ${jni_path}
)

This looks reasonable.  Is there a case where this will not work?

-Bill

Sorry for dropping in on this, but shouldn't the above FIND_PATH calls use HINTS for the derived paths (after all, that's what the manpage says it's for)?

FIND_PATH(JAVA_INCLUDE_PATH2 jni_md.h
  HINTS
  ${jni_path}
  ${jni_path}/win32
  ${jni_path}/linux
  ${jni_path}/freebsd
)

FIND_PATH(JAVA_AWT_INCLUDE_PATH jawt.h
  HINTS ${jni_path}
)

Michael
_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to