From f57ac9d1d9869f6b462be634cdc98c7d396075e1 Mon Sep 17 00:00:00 2001 From: "gregory.hainaut" Date: Sun, 4 Jul 2010 12:37:42 +0000 Subject: [PATCH] [cmake] * move build options to the build module * Add some documentation about the default cmake build options git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3389 96395faa-99c1-11dd-bbfe-3dabce05a288 --- CMakeLists.txt | 5 ----- cmake/BuildParameters.cmake | 16 ++++++++++++++++ 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 764bb5e166..69ed9b1b40 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -16,11 +16,6 @@ include(Pcsx2Utils) # Detect current OS detectOperatingSystem() -# These lines remove some defaults options that can cause some failure later. -# In particular, it remove the build option -rdynamic on pcsx2 -SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS " ") -SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS " ") - #------------------------------------------------------------------------------- # Include specific module # BuildParameters Must be done before SearchForStuff diff --git a/cmake/BuildParameters.cmake b/cmake/BuildParameters.cmake index 37922b1178..4645b0b1ee 100644 --- a/cmake/BuildParameters.cmake +++ b/cmake/BuildParameters.cmake @@ -7,6 +7,22 @@ # Use zlib internal lib: -DFORCE_INTERNAL_ZLIB=TRUE #------------------------------------------------------------------------------- +### Cmake set default value for various compilation variable +### Here the list of default value for documentation purpose +# ${CMAKE_SHARED_LIBRARY_CXX_FLAGS} = "-fPIC" +# ${CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS} = "-rdynamic" +# +# Use in debug mode +# ${CMAKE_CXX_FLAGS_DEBUG} = "-g" +# Use in release mode +# ${CMAKE_CXX_FLAGS_RELEASE} = "-O3 -DNDEBUG" + +#------------------------------------------------------------------------------- +# Remove bad default option +#------------------------------------------------------------------------------- +# Remove -rdynamic option that can some segmentation fault when openining pcsx2 plugins +SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS " ") +SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS " ") #------------------------------------------------------------------------------- # if no build type is set, use Devel as default