X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=CMakeLists.txt;h=df1230e7a1d49948cb04a58b31dd058d83c0a7a3;hb=4da178b0d83b6009e82bca1d9b7b2d5e1bceb6ad;hp=dc3783b8cdf7632a32727d69514959415f0cb588;hpb=6265dcfb119e80ce02a11d116ab3d06a2afa1795;p=openjpeg.git diff --git a/CMakeLists.txt b/CMakeLists.txt index dc3783b8..df1230e7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,7 +7,6 @@ # For this purpose you can define a CMake var: OPENJPEG_NAMESPACE to whatever you like # e.g.: # SET(OPENJPEG_NAMESPACE "GDCMOPENJPEG") -PROJECT(OPENJPEG C) CMAKE_MINIMUM_REQUIRED(VERSION 2.4) IF(NOT OPENJPEG_NAMESPACE) @@ -17,7 +16,7 @@ ENDIF(NOT OPENJPEG_NAMESPACE) # In all cases: STRING(TOLOWER ${OPENJPEG_NAMESPACE} OPENJPEG_LIBRARY_NAME) -PROJECT(${JPEG_NAMESPACE} C) +PROJECT(${OPENJPEG_NAMESPACE} C) # Do full dependency headers. INCLUDE_REGULAR_EXPRESSION("^.*$") @@ -25,7 +24,7 @@ INCLUDE_REGULAR_EXPRESSION("^.*$") #----------------------------------------------------------------------------- # OPENJPEG version number, useful for packaging and doxygen doc: SET(OPENJPEG_VERSION_MAJOR 1) -SET(OPENJPEG_VERSION_MINOR 2) +SET(OPENJPEG_VERSION_MINOR 3) SET(OPENJPEG_VERSION_BUILD 0) SET(OPENJPEG_VERSION "${OPENJPEG_VERSION_MAJOR}.${OPENJPEG_VERSION_MINOR}.${OPENJPEG_VERSION_BUILD}") @@ -116,3 +115,12 @@ FIND_PATH(JPEG2000_CONFORMANCE_DATA_ROOT testimages.html $ENV{JPEG2000_CONFORMANCE_DATA_ROOT} ) +#----------------------------------------------------------------------------- +# Compiler specific flags: +IF(CMAKE_COMPILER_IS_GNUCC) + # For all builds, make sure openjpeg is std99 compliant: + SET(CMAKE_C_FLAGS "-Wall -std=c99 ${CMAKE_C_FLAGS}") + # Do not use ffast-math for all build, it would produce incorrect results, only set for release: + SET(CMAKE_C_FLAGS_RELEASE "-ffast-math ${CMAKE_C_FLAGS_RELEASE}") +ENDIF(CMAKE_COMPILER_IS_GNUCC) +