diff options
author | Ben Boeckel <mathstuf@gmail.com> | 2015-02-04 11:39:06 -0500 |
---|---|---|
committer | Ben Boeckel <mathstuf@gmail.com> | 2015-02-07 20:51:06 -0500 |
commit | 91498e200292ef5f309fc0b7420f8a5bc8e308cc (patch) | |
tree | 90e00d8968364a95df999779fdde013631e77e97 /src/inc/CMakeLists.txt | |
parent | 6f9408efe3bfe1fd8db54cb8537412d8bd95d969 (diff) | |
download | coreclr-91498e200292ef5f309fc0b7420f8a5bc8e308cc.tar.gz coreclr-91498e200292ef5f309fc0b7420f8a5bc8e308cc.tar.bz2 coreclr-91498e200292ef5f309fc0b7420f8a5bc8e308cc.zip |
Use foreach(IN LISTS) syntax in CMake code
It avoids extra separation on semicolons if there are any and skips a
variable expansion.
Diffstat (limited to 'src/inc/CMakeLists.txt')
-rw-r--r-- | src/inc/CMakeLists.txt | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/inc/CMakeLists.txt b/src/inc/CMakeLists.txt index e8f52de6d1..d27a3b89c4 100644 --- a/src/inc/CMakeLists.txt +++ b/src/inc/CMakeLists.txt @@ -31,7 +31,7 @@ get_include_directories(MIDL_INCLUDE_DIRECTORIES) # Run custom midl command over each idl file FIND_PROGRAM( MIDL midl.exe ) -foreach(GENERATE_IDL ${CORGUIDS_IDL_SOURCES}) +foreach(GENERATE_IDL IN LISTS CORGUIDS_IDL_SOURCES) get_filename_component(IDLNAME ${GENERATE_IDL} NAME_WE) set(OUT_NAME ${CMAKE_CURRENT_BINARY_DIR}/idls_out/${IDLNAME}_i.c) set(CORGUIDS_SOURCES ${CORGUIDS_SOURCES} ${OUT_NAME}) @@ -50,7 +50,7 @@ add_compile_options(/TC) else() #The MIDL tool exists for Windows only, so for other systems, we have the prebuilt xxx_i.c files checked in -foreach(IDL_SOURCE ${CORGUIDS_IDL_SOURCES}) +foreach(IDL_SOURCE IN LISTS CORGUIDS_IDL_SOURCES) get_filename_component(IDLNAME ${IDL_SOURCE} NAME_WE) set(C_SOURCE ../pal/prebuilt/idl/${IDLNAME}_i.c) set(CORGUIDS_SOURCES ${CORGUIDS_SOURCES} ${C_SOURCE}) |