From c5ec4896fef4ce53b2c64ee48dc27c6a987be82e Mon Sep 17 00:00:00 2001 From: Mathieu Malaterre Date: Sat, 2 Aug 2008 16:40:10 +0000 Subject: [PATCH] ENH: remove INLINE from forward decl. Fix CMakeLists.txt for UNIX platforms --- ChangeLog | 3 +++ Free_CMakeImport.cmake | 8 ++++++-- libopenjpeg/CMakeLists.txt | 4 ++++ libopenjpeg/dwt.c | 2 +- 4 files changed, 14 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 4a594249..d0c312d1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,9 @@ What's New for OpenJPEG ! : changed + : added +August 2nd, 2008 +* [Mathieu Malaterre] remove INLINE from forward decl. Fix CMakeLists.txt for UNIX platforms + August 1st, 2008 - [antonin] removed t1_generate_luts.c, useless in version 2. ! [antonin] updated XCode project file for mac users. diff --git a/Free_CMakeImport.cmake b/Free_CMakeImport.cmake index 9b8aaf24..c0bc03f5 100644 --- a/Free_CMakeImport.cmake +++ b/Free_CMakeImport.cmake @@ -7,8 +7,12 @@ INCLUDE_DIRECTORIES(${OPENJPEG_SOURCE_DIR}/libs/FreeImage) # Link libraries - LINK_DIRECTORIES(${OPENJPEG_SOURCE_DIR}/libs/FreeImage) +IF(WIN32) + LINK_DIRECTORIES(${OPENJPEG_SOURCE_DIR}/libs/FreeImage) LINK_LIBRARIES(freeimage.s) - ADD_DEFINITIONS ( -DFREEIMAGE_LIB ) +ELSE(WIN32) + LINK_LIBRARIES(freeimage) +ENDIF(WIN32) + ADD_DEFINITIONS ( -DFREEIMAGE_LIB ) diff --git a/libopenjpeg/CMakeLists.txt b/libopenjpeg/CMakeLists.txt index e310e1bb..c1075389 100644 --- a/libopenjpeg/CMakeLists.txt +++ b/libopenjpeg/CMakeLists.txt @@ -63,6 +63,10 @@ ENDIF(ENABLE_PROFILING) ADD_LIBRARY(${OPENJPEG_LIBRARY_NAME} ${OPENJPEG_SRCS}) SET_TARGET_PROPERTIES(${OPENJPEG_LIBRARY_NAME} PROPERTIES ${OPENJPEG_LIBRARY_PROPERTIES}) +IF(UNIX) + TARGET_LINK_LIBRARIES(${OPENJPEG_LIBRARY_NAME} m) +ENDIF(UNIX) + # Install library INSTALL(TARGETS ${OPENJPEG_LIBRARY_NAME} diff --git a/libopenjpeg/dwt.c b/libopenjpeg/dwt.c index a6ffd180..0c4cde49 100644 --- a/libopenjpeg/dwt.c +++ b/libopenjpeg/dwt.c @@ -128,7 +128,7 @@ static bool dwt_decode_tile(opj_tcd_tilecomp_t* tilec, OPJ_UINT32 i, DWT1DFN fn) static OPJ_UINT32 dwt_max_resolution(opj_tcd_resolution_t* restrict r, OPJ_UINT32 i); -static INLINE bool dwt_encode_procedure(opj_tcd_tilecomp_t * tilec,void (*p_function)(OPJ_INT32 *, OPJ_INT32,OPJ_INT32,OPJ_INT32) ); +static bool dwt_encode_procedure(opj_tcd_tilecomp_t * tilec,void (*p_function)(OPJ_INT32 *, OPJ_INT32,OPJ_INT32,OPJ_INT32) ); /*@}*/ /*@}*/