2007-09-06 12:13:05 +02:00
|
|
|
# Makefile for the MJ2 codecs of the OpenJPEG library: frames_to_mj2, mj2_to_frames, extract_j2k_from_mj2 and wrap_j2k_in_mj2
|
|
|
|
|
2012-09-28 10:11:41 +02:00
|
|
|
set(common_SRCS ${OPENJPEG_SOURCE_DIR}/src/bin/common/opj_getopt.c)
|
2011-01-02 19:10:09 +01:00
|
|
|
|
2012-08-30 19:14:39 +02:00
|
|
|
if(WIN32)
|
2012-10-15 11:44:34 +02:00
|
|
|
if(BUILD_SHARED_LIBS)
|
|
|
|
add_definitions(-DOPJ_EXPORTS)
|
|
|
|
else()
|
|
|
|
add_definitions(-DOPJ_STATIC)
|
|
|
|
endif()
|
2012-08-30 19:20:03 +02:00
|
|
|
endif()
|
2011-01-02 19:10:09 +01:00
|
|
|
|
2007-09-06 12:13:05 +02:00
|
|
|
# Headers file are located here:
|
2012-08-30 19:14:39 +02:00
|
|
|
include_directories(
|
2012-10-01 09:49:52 +02:00
|
|
|
${OPENJPEG_BINARY_DIR}/src/lib/openjp2 # opj_config.h
|
2013-03-17 23:22:11 +01:00
|
|
|
${OPENJPEG_BINARY_DIR}/src/bin/common # opj_apps_config.h
|
2012-09-28 10:51:14 +02:00
|
|
|
${OPENJPEG_SOURCE_DIR}/src/lib/openmj2
|
2012-09-28 10:11:41 +02:00
|
|
|
${OPENJPEG_SOURCE_DIR}/src/bin/common
|
2011-03-20 23:45:24 +01:00
|
|
|
${LCMS_INCLUDE_DIRNAME}
|
2007-09-06 12:13:05 +02:00
|
|
|
)
|
|
|
|
|
2012-09-28 11:52:57 +02:00
|
|
|
foreach(exe
|
|
|
|
opj_mj2_wrap
|
|
|
|
opj_mj2_extract
|
|
|
|
opj_mj2_decompress
|
|
|
|
opj_mj2_compress
|
|
|
|
)
|
2012-11-16 10:31:12 +01:00
|
|
|
add_definitions(-DOPJ_USE_LEGACY)
|
2012-09-28 11:52:57 +02:00
|
|
|
add_executable(${exe}
|
|
|
|
${exe}.c
|
2011-01-02 19:10:09 +01:00
|
|
|
${common_SRCS}
|
|
|
|
${MJ2_SRCS}
|
2012-09-28 10:11:41 +02:00
|
|
|
${OPENJPEG_SOURCE_DIR}/src/bin/common/color.c
|
2010-09-05 23:59:25 +02:00
|
|
|
)
|
2012-09-28 11:52:57 +02:00
|
|
|
target_link_libraries(${exe} ${LCMS_LIBNAME} openmj2)
|
|
|
|
|
|
|
|
if(UNIX)
|
|
|
|
target_link_libraries(${exe} m)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
install(TARGETS ${exe}
|
|
|
|
DESTINATION ${OPENJPEG_INSTALL_BIN_DIR})
|
|
|
|
endforeach()
|