diff options
author | Stephen Kelly <steveire@gmail.com> | 2014-06-05 11:05:20 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2014-06-05 12:02:52 (GMT) |
commit | 78acaafebe4821f7a62f835f8ced6330097745f2 (patch) | |
tree | 9602245fa0fd39b5642d2625e3d3c37da05d8cae /Modules/CMakeCompilerIdDetection.cmake | |
parent | 567af1a596455b096c9261317b1562ceb89f2e95 (diff) | |
download | CMake-78acaafebe4821f7a62f835f8ced6330097745f2.zip CMake-78acaafebe4821f7a62f835f8ced6330097745f2.tar.gz CMake-78acaafebe4821f7a62f835f8ced6330097745f2.tar.bz2 |
Project: Separate simulated compiler id from version detection.
Diffstat (limited to 'Modules/CMakeCompilerIdDetection.cmake')
-rw-r--r-- | Modules/CMakeCompilerIdDetection.cmake | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Modules/CMakeCompilerIdDetection.cmake b/Modules/CMakeCompilerIdDetection.cmake index d8a0d67..a2f9a1c 100644 --- a/Modules/CMakeCompilerIdDetection.cmake +++ b/Modules/CMakeCompilerIdDetection.cmake @@ -17,6 +17,7 @@ function(_readFile file) get_filename_component(name ${file} NAME_WE) string(REGEX REPLACE "-.*" "" CompilerId ${name}) set(_compiler_id_version_compute_${CompilerId} ${_compiler_id_version_compute} PARENT_SCOPE) + set(_compiler_id_simulate_${CompilerId} ${_compiler_id_simulate} PARENT_SCOPE) set(_compiler_id_pp_test_${CompilerId} ${_compiler_id_pp_test} PARENT_SCOPE) endfunction() @@ -114,7 +115,9 @@ function(compiler_id_detection outvar lang) endif() set(id_content "${pp_if} ${_compiler_id_pp_test_${Id}}\n") if (CID_ID_STRING) - set(id_content "${id_content}# define ${CID_PREFIX}COMPILER_ID \"${Id}\"") + set(PREFIX ${CID_PREFIX}) + string(CONFIGURE "${_compiler_id_simulate_${Id}}" SIMULATE_BLOCK @ONLY) + set(id_content "${id_content}# define ${CID_PREFIX}COMPILER_ID \"${Id}\"${SIMULATE_BLOCK}") endif() if (CID_ID_DEFINE) set(id_content "${id_content}# undef ${CID_PREFIX}COMPILER_IS_${Id}\n") |