зеркало из https://github.com/mozilla/mozjpeg.git
Allow customization of Java compiler flags
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@566 632fc199-4ca6-4c93-a231-07263d6284db
This commit is contained in:
Родитель
df48945d2d
Коммит
db42506734
|
@ -469,6 +469,13 @@ Java front-end classes to support it. This allows the TurboJPEG/OSS dynamic
|
|||
library to be used directly from Java applications. See java/README for more
|
||||
details.
|
||||
|
||||
If you are using CMake 2.8, you can set the Java_JAVAC_EXECUTABLE,
|
||||
Java_JAVA_EXECUTABLE, and Java_JAR_EXECUTABLE CMake variables to specify
|
||||
alternate commands or locations for javac, jar, and java (respectively.) If
|
||||
you are using CMake 2.6, set JAVA_COMPILE, JAVA_RUNTIME, and JAVA_ARCHIVE
|
||||
instead. You can also set the JAVACFLAGS CMake variable to specify arguments
|
||||
that should be passed to the Java compiler when building the front-end classes.
|
||||
|
||||
|
||||
========================
|
||||
Installing libjpeg-turbo
|
||||
|
|
|
@ -118,6 +118,9 @@ include_directories(${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_SOURCE_DIR})
|
|||
if(WITH_JAVA)
|
||||
find_package(Java)
|
||||
find_package(JNI)
|
||||
if(DEFINED JAVACFLAGS)
|
||||
message(STATUS "Java compiler flags = ${JAVACFLAGS}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
|
|
|
@ -39,8 +39,9 @@ set(JAVA_CLASSES ${JAVA_CLASSES}
|
|||
set(JAVA_CLASSES_FULL ${JAVA_CLASSES_FULL}
|
||||
${OBJDIR}/org/libjpegturbo/turbojpeg/TJLoader.class)
|
||||
|
||||
string(REGEX REPLACE " " ";" JAVACFLAGS "${JAVACFLAGS}")
|
||||
add_custom_command(OUTPUT ${JAVA_CLASSES_FULL} DEPENDS ${JAVA_SOURCES}
|
||||
COMMAND ${JAVA_COMPILE} -d ${OBJDIR} ARGS ${JAVA_SOURCES})
|
||||
COMMAND ${JAVA_COMPILE} ARGS ${JAVACFLAGS} -d ${OBJDIR} ${JAVA_SOURCES})
|
||||
|
||||
add_custom_command(OUTPUT ${JAR_FILE} DEPENDS ${JAVA_CLASSES_FULL}
|
||||
${MANIFEST_FILE}
|
||||
|
|
Загрузка…
Ссылка в новой задаче