fixing core crash during restore
[quassel.git] / CMakeLists.txt
index e5ffc94..3f074e8 100644 (file)
@@ -3,8 +3,8 @@
 # -DWANT_(CORE|QTCLIENT|MONO)=(ON|OFF)
 #                  : select binaries to build
 # -DQT=/path/to/qt : Choose a Qt4 installation to use instead of the system Qt4
-# -DSTATIC         : Enable static building of Quassel. Use with care.
-# -DSPUTDEV        : Do not use.
+# -DSTATIC=ON      : Enable static building of Quassel. Use with care.
+# -DSPUTDEV=ON     : Do not use.
 #
 # NOTE: You need to remove CMakeCache.txt if you plan to change any of these values!
 
@@ -24,11 +24,12 @@ set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/modules)
 # Various options and variables that can be set on the command line
 option(WANT_CORE     "Build the core (server) binary"           ON)
 option(WANT_QTCLIENT "Build the Qt4 GUI client binary"          ON)
-option(WANT_MONO     "Build the monolithic (all-in-one) binary" ON)
+option(WANT_MONO     "Build the monolithic (all-in-one) binary" OFF)
+
+option(STATIC        "Enable static building (might not be portable)" OFF)
+option(SPUTDEV       "Do not use!" OFF)
 
-set(STATIC 0 CACHE BOOL "Enable static building (might not be portable)")
 set(QT "" CACHE STRING "Path to a Qt installation to use instead of the system Qt")
-set(SPUTDEV CACHE STRING "Do not use!")
 
 if(STATIC)
   set(CMAKE_BUILD_TYPE Release)
@@ -53,6 +54,11 @@ endif(CMAKE_COMPILER_IS_GNUCXX)
 
 set(QT_MIN_VERSION "4.3.0")
 
+if(APPLE)
+  set(CMAKE_OSX_ARCHITECTURES "i386;ppc")
+#  set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mmacosx-version-min=10.4")
+endif(APPLE)
+
 # Enable mostly b0rked stuff (new ChatView), do not enable this unless you know what you do...
 if(SPUTDEV)
   add_definitions(-DSPUTDEV)
@@ -77,6 +83,10 @@ include_directories(${QT_INCLUDES})
 # We need to create a version.gen
 # For this, we create our genversion binary and make sure it is run every time.
 add_executable(genversion ${CMAKE_SOURCE_DIR}/src/common/genversion.cpp)
+#set_target_properties(genversion PROPERTIES 
+#                                 LINK_FLAGS "-mmacosx-version-min=10.4")
+#                                 COMPILE_FLAGS "-mmacosx-version-min=10.4"
+
 target_link_libraries(genversion ${QT_LIBRARIES} ${QT_CORE_LIB_DEPENDENCIES})
 
 add_custom_target(genversion_run ALL ${CMAKE_BINARY_DIR}/genversion