[1.5] Fix Java binding issues.
Properly link to math lib on UNIX Make JNI install location a user configuration Remove SONAME property from the java module
This commit is contained in:
parent
75175b715c
commit
15488c94d2
|
@ -136,6 +136,14 @@ IF(NOT OPENJPEG_INSTALL_DOC_DIR)
|
||||||
SET(OPENJPEG_INSTALL_DOC_DIR "share/doc/${OPENJPEG_INSTALL_SUBDIR}")
|
SET(OPENJPEG_INSTALL_DOC_DIR "share/doc/${OPENJPEG_INSTALL_SUBDIR}")
|
||||||
ENDIF(NOT OPENJPEG_INSTALL_DOC_DIR)
|
ENDIF(NOT OPENJPEG_INSTALL_DOC_DIR)
|
||||||
|
|
||||||
|
if(NOT OPENJPEG_INSTALL_JNI_DIR)
|
||||||
|
if(WIN32)
|
||||||
|
set(OPENJPEG_INSTALL_JNI_DIR ${OPENJPEG_INSTALL_BIN_DIR})
|
||||||
|
else()
|
||||||
|
set(OPENJPEG_INSTALL_JNI_DIR ${OPENJPEG_INSTALL_LIB_DIR})
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
IF(NOT OPENJPEG_INSTALL_PACKAGE_DIR)
|
IF(NOT OPENJPEG_INSTALL_PACKAGE_DIR)
|
||||||
# We could install *.cmake files in share/ however those files contains
|
# We could install *.cmake files in share/ however those files contains
|
||||||
# hardcoded path to libraries on a multi-arch system (fedora/debian) those
|
# hardcoded path to libraries on a multi-arch system (fedora/debian) those
|
||||||
|
|
|
@ -24,13 +24,14 @@ include_directories(
|
||||||
add_library(openjpegjni MODULE
|
add_library(openjpegjni MODULE
|
||||||
${openjpegjni_SRCS}
|
${openjpegjni_SRCS}
|
||||||
)
|
)
|
||||||
|
# Java module should not have a SONAME:
|
||||||
|
set_property(TARGET openjpegjni PROPERTY NO_SONAME 1)
|
||||||
|
|
||||||
TARGET_LINK_LIBRARIES(openjpegjni ${OPENJPEG_LIBRARY_NAME})
|
TARGET_LINK_LIBRARIES(openjpegjni ${OPENJPEG_LIBRARY_NAME})
|
||||||
|
|
||||||
IF(WIN32)
|
if(UNIX)
|
||||||
SET(OPENJPEG_INSTALL_JNI_DIR ${OPENJPEG_INSTALL_BIN_DIR})
|
target_link_libraries(openjpegjni m)
|
||||||
ELSE()
|
endif()
|
||||||
SET(OPENJPEG_INSTALL_JNI_DIR ${OPENJPEG_INSTALL_LIB_DIR})
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
INSTALL(TARGETS openjpegjni
|
INSTALL(TARGETS openjpegjni
|
||||||
EXPORT OpenJPEGTargets
|
EXPORT OpenJPEGTargets
|
||||||
|
|
Loading…
Reference in New Issue