Merge branch 'master' into gtk3

This commit is contained in:
Beep6581
2016-02-23 09:26:00 +01:00
17 changed files with 132 additions and 73 deletions

View File

@@ -98,6 +98,8 @@ option (BUILD_SHARED "Build rawtherapee with shared libraries" OFF)
option (WITH_BZIP "Build with Bzip2 support" ON)
option (WITH_MYFILE_MMAP "Build using memory mapped file" ON)
option (WITH_LTO "Build with link-time optimizations" OFF)
option (WITH_SAN "Build with run-time sanitizer" OFF)
option (WITH_PROF "Build with profiling instrumentation" OFF)
option (OPTION_OMP "Build with OpenMP support" ON)
option (STRICT_MUTEX "True (recommended): MyMutex will behave like POSIX Mutex; False: MyMutex will behave like POSIX RecMutex; Note: forced to ON for Debug builds" ON)
option (TRACE_MYRWMUTEX "Trace RT's custom R/W Mutex (Debug builds only); redirecting std::out to a file is strongly recommended!" OFF)
@@ -274,6 +276,18 @@ if (WITH_LTO)
SET (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -flto")
endif (WITH_LTO)
if (WITH_SAN)
SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=${WITH_SAN}")
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=${WITH_SAN}")
SET (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fsanitize=${WITH_SAN}")
endif (WITH_SAN)
if (WITH_PROF)
SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pg")
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pg")
SET (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -pg")
endif (WITH_PROF)
if (OPTION_OMP)
find_package(OpenMP)
if (OPENMP_FOUND)