Pass -std=c99 when compiling mach_override.c

llvm-svn: 163717
This commit is contained in:
Alexander Potapenko 2012-09-12 15:44:56 +00:00
parent f3a96894a6
commit c7a7522f83
1 changed files with 6 additions and 1 deletions

View File

@ -6,11 +6,16 @@ set(INTERCEPTION_SOURCES
interception_win.cc
)
set(MACH_OVERRIDE_SOURCES
mach_override/mach_override.c
)
# Only add this C file if we're building on a Mac. Other source files can be
# harmlessly compiled on any platform, but the C file is complained about due
# to pedantic rules about empty translation units.
if (APPLE)
list(APPEND INTERCEPTION_SOURCES mach_override/mach_override.c)
list(APPEND INTERCEPTION_SOURCES ${MACH_OVERRIDE_SOURCES})
set_source_files_properties(${MACH_OVERRIDE_SOURCES} PROPERTIES COMPILE_FLAGS "-std=c99 ${INTERCEPTION_CFLAGS}")
endif ()
set(INTERCEPTION_CFLAGS ${SANITIZER_COMMON_CFLAGS})