Tests/Assembler: Drop -g when generating sample assembly source
Some compilers, such as Clang on OS X, do not want the -g flag for both generating assembly code and assembling it. Drop the -g flag from generation of main.s in the Assembler test.
This commit is contained in:
parent
20bb609171
commit
f60797f75b
|
@ -15,6 +15,9 @@ if("${CMAKE_GENERATOR}" MATCHES "Makefile|Xcode" AND
|
||||||
if(CMAKE_OSX_SYSROOT AND CMAKE_C_SYSROOT_FLAG AND NOT ";${C_FLAGS};" MATCHES ";${CMAKE_C_SYSROOT_FLAG};")
|
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})
|
list(APPEND C_FLAGS ${CMAKE_C_SYSROOT_FLAG} ${CMAKE_OSX_SYSROOT})
|
||||||
endif()
|
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)
|
set(SRCS main.s)
|
||||||
add_custom_command(
|
add_custom_command(
|
||||||
OUTPUT main.s
|
OUTPUT main.s
|
||||||
|
|
Loading…
Reference in New Issue