summaryrefslogtreecommitdiffstats
path: root/Tests/BuildDepends
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2009-02-19 20:24:44 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2009-02-19 20:24:44 (GMT)
commit819a4f2e57831b5c53bdca6812b4317fdea92ada (patch)
tree543f291322dfe5060c694cca4c2d996a3b8dd2b8 /Tests/BuildDepends
parent756cb547f3c9462ce4c2276160a73cc174bcd2b0 (diff)
downloadCMake-819a4f2e57831b5c53bdca6812b4317fdea92ada.zip
CMake-819a4f2e57831b5c53bdca6812b4317fdea92ada.tar.gz
CMake-819a4f2e57831b5c53bdca6812b4317fdea92ada.tar.bz2
ENH: make sure multiple archs are only tested when the work
Diffstat (limited to 'Tests/BuildDepends')
-rw-r--r--Tests/BuildDepends/Project/CMakeLists.txt8
1 files changed, 7 insertions, 1 deletions
diff --git a/Tests/BuildDepends/Project/CMakeLists.txt b/Tests/BuildDepends/Project/CMakeLists.txt
index a8bb445..e9d1296 100644
--- a/Tests/BuildDepends/Project/CMakeLists.txt
+++ b/Tests/BuildDepends/Project/CMakeLists.txt
@@ -1,6 +1,12 @@
cmake_minimum_required(VERSION 2.6)
project(testRebuild)
-set(CMAKE_OSX_ARCHITECTURES "ppc;i386")
+if(APPLE)
+ # only use multi-arch if the sysroot exists on this machine
+ if(EXISTS "${CMAKE_OSX_SYSROOT}")
+ set(CMAKE_OSX_ARCHITECTURES "ppc;i386")
+ endif(EXISTS "${CMAKE_OSX_SYSROOT}")
+endif(APPLE)
+
add_library(foo STATIC ${testRebuild_BINARY_DIR}/foo.cxx)
set_target_properties(foo PROPERTIES OUTPUT_NAME "foolib")
# Add a generated header that regenerates when the generator is