summaryrefslogtreecommitdiffstats
path: root/Tests/Assembler/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/Assembler/CMakeLists.txt')
-rw-r--r--Tests/Assembler/CMakeLists.txt5
1 files changed, 4 insertions, 1 deletions
diff --git a/Tests/Assembler/CMakeLists.txt b/Tests/Assembler/CMakeLists.txt
index bb4bccc..fdc5c00 100644
--- a/Tests/Assembler/CMakeLists.txt
+++ b/Tests/Assembler/CMakeLists.txt
@@ -9,12 +9,15 @@ set(SRCS)
# and also generate assembler files from C:
if("${CMAKE_GENERATOR}" MATCHES "Makefile|Xcode" AND
NOT CMAKE_OSX_ARCHITECTURES)
- if(("${CMAKE_C_COMPILER_ID}" MATCHES "^(GNU|Clang|HP|SunPro|XL)$") OR ("${CMAKE_C_COMPILER_ID}" STREQUAL "Intel" AND UNIX))
+ if(("${CMAKE_C_COMPILER_ID}" MATCHES "^(GNU|Clang|AppleClang|HP|SunPro|XL)$") OR ("${CMAKE_C_COMPILER_ID}" STREQUAL "Intel" AND UNIX))
set(C_FLAGS "${CMAKE_C_FLAGS}")
separate_arguments(C_FLAGS)
if(CMAKE_OSX_SYSROOT AND CMAKE_C_SYSROOT_FLAG AND NOT ";${C_FLAGS};" MATCHES ";${CMAKE_C_SYSROOT_FLAG};")
list(APPEND C_FLAGS ${CMAKE_C_SYSROOT_FLAG} ${CMAKE_OSX_SYSROOT})
endif()
+ # Clang on OS X, and perhaps other compilers, do not support -g
+ # for both generating and assembling, so drop it from generating.
+ list(REMOVE_ITEM C_FLAGS -g)
set(SRCS main.s)
add_custom_command(
OUTPUT main.s