summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosé Fonseca <jose.r.fonseca@gmail.com>2011-09-27 14:13:56 +0100
committerJosé Fonseca <jose.r.fonseca@gmail.com>2011-09-27 14:13:56 +0100
commit5971d6a409e88044672911d960b355a425db7479 (patch)
tree60c408f6aacd4fb9c98c7a228de12f437f1ffc9d
parentff3abc666dd2fa955ced1e0d6472ea3d94ab66a2 (diff)
Build fat binaries with i386 and x86_64 architectures by default on Mac OS X.
-rwxr-xr-xCMakeLists.txt8
1 files changed, 6 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 21b46df..e31f753 100755
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -5,12 +5,16 @@ project (apitrace)
##############################################################################
# Options
-#
+
+# On Mac OS X build fat binaries with i386 and x86_64 architectures by default.
+if (APPLE AND NOT CMAKE_OSX_ARCHITECTURES)
+ set (CMAKE_OSX_ARCHITECTURES "i386;x86_64" CACHE STRING "Build architectures for OSX" FORCE)
+endif ()
+
# We use a cached string variable instead of the standard (boolean) OPTION
# command so that we can default to auto-detecting optional depencies, while
# still providing a mechanism to force/disable these optional dependencies, as
# prescribed in http://www.gentoo.org/proj/en/qa/automagic.xml
-
set (ENABLE_GUI "AUTO" CACHE STRING "Enable Qt GUI.")