summaryrefslogtreecommitdiff
path: root/src/ilasm
diff options
context:
space:
mode:
authorJeremy Koritzinsky <jekoritz@microsoft.com>2019-06-05 14:48:55 -0700
committerGitHub <noreply@github.com>2019-06-05 14:48:55 -0700
commit90dd13ee1bd497d7724c2b1d0fd833d42f7001ad (patch)
treeae6167d368f59598c6dd6c71e3280d1af0485f02 /src/ilasm
parentd7e49efa6b41afb2b7a9ee3adc8f0850b968562a (diff)
downloadcoreclr-90dd13ee1bd497d7724c2b1d0fd833d42f7001ad.tar.gz
coreclr-90dd13ee1bd497d7724c2b1d0fd833d42f7001ad.tar.bz2
coreclr-90dd13ee1bd497d7724c2b1d0fd833d42f7001ad.zip
Use Modern CMake features instead of CMAKE_CXX_FLAGS (#24861)
* Convert C++ standard settings and warning options from CMAKE_<LANG>_FLAGS to Modern CMake isms. * More $<COMPILE_LANGUAGE> generator expressions instead of CMAKE_CXX_FLAGS. * Use $<COMPILE_LANGUAGE:CXX> for all -fpermissive usage * Fix generator expression that generates multiple flags * Fix invalid use of CMAKE_CXX_FLAGS instead of CMAKE_C_FLAGS. * Treat AppleClang as though it is Clang (match pre-3.0 behavior). * Update our build system to understand that AppleClang is distinct from Clang and remove CMP0025 policy setting. * PR Feedback.
Diffstat (limited to 'src/ilasm')
-rw-r--r--src/ilasm/CMakeLists.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ilasm/CMakeLists.txt b/src/ilasm/CMakeLists.txt
index 3d1a74dae6..f780dcae11 100644
--- a/src/ilasm/CMakeLists.txt
+++ b/src/ilasm/CMakeLists.txt
@@ -51,7 +51,7 @@ if(CLR_CMAKE_PLATFORM_UNIX)
# Need generate a right form of asmparse.cpp to avoid the following options.
# Clang also produces a bad-codegen on this prebuilt file with optimization.
# https://github.com/dotnet/coreclr/issues/2305
- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-delete-non-virtual-dtor -Wno-register")
+ add_compile_options("$<$<COMPILE_LANGUAGE:CXX>:-Wno-delete-non-virtual-dtor;-Wno-register>")
add_compile_options(-Wno-array-bounds)
add_compile_options(-Wno-unused-label)
set_source_files_properties( prebuilt/asmparse.cpp PROPERTIES COMPILE_FLAGS "-O0" )