Fix semi-colons being inserted into ldflags

It is causing clang++ to error when linking game{cpu}.dylib
This commit is contained in:
scottWakeling 2011-12-23 16:29:05 +00:00 committed by Daniel Gibson
parent 16e2bf160d
commit 0d01f4f90b

View file

@ -152,25 +152,25 @@ if (CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID STREQUAL "Clang")
if (cpu STREQUAL "x86_64")
add_definitions(-arch x86_64 -mmacosx-version-min=10.6)
set(ldflags ${ldflags} "-arch x86_64 -mmacosx-version-min=10.6")
set(ldflags "${ldflags} -arch x86_64 -mmacosx-version-min=10.6")
elseif (cpu STREQUAL "x86")
CHECK_CXX_COMPILER_FLAG("-arch i386" cxx_has_arch_i386)
if (cxx_has_arch_i386)
add_definitions(-arch i386)
set(ldflags ${ldflags} "-arch i386")
set(ldflags "${ldflags} -arch i386")
endif()
add_definitions(-mmacosx-version-min=10.4)
set(ldflags ${ldflags} "-mmacosx-version-min=10.4")
set(ldflags "${ldflags} -mmacosx-version-min=10.4")
elseif (cpu STREQUAL "ppc")
CHECK_CXX_COMPILER_FLAG("-arch ppc" cxx_has_arch_ppc)
if (cxx_has_arch_ppc)
add_definitions(-arch ppc)
set(ldflags ${ldflags} "-arch ppc")
set(ldflags "${ldflags} -arch ppc")
endif()
add_definitions(-mmacosx-version-min=10.4)
set(ldflags ${ldflags} "-mmacosx-version-min=10.4")
set(ldflags "${ldflags} -mmacosx-version-min=10.4")
else()
message(FATAL_ERROR "Unsupported CPU architecture for OSX")
endif()
@ -179,7 +179,7 @@ if (CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID STREQUAL "Clang")
else()
if (cpu STREQUAL "x86" AND X86)
add_definitions(-m32)
set(ldflags ${ldflags} "-m32")
set(ldflags "${ldflags} -m32")
endif()
if (os STREQUAL "linux")