diff options
author | Aleix Pol <aleixpol@kde.org> | 2017-04-06 02:14:35 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2017-04-20 12:59:07 (GMT) |
commit | 0903531964cff8888dd1cbf2a9c82ac6bb9a522f (patch) | |
tree | 2cf7d844d3ee291ecb5ba77547bddb0a490aa150 /Modules/Compiler/Intel.cmake | |
parent | 135611176c5d4958b9b5a36c63fada8a9e4fb1ef (diff) | |
download | CMake-0903531964cff8888dd1cbf2a9c82ac6bb9a522f.zip CMake-0903531964cff8888dd1cbf2a9c82ac6bb9a522f.tar.gz CMake-0903531964cff8888dd1cbf2a9c82ac6bb9a522f.tar.bz2 |
Autogen: Pass explicit predefines header to moc if possible
Qt is relying on whoever calls moc to include a file with the predefined
values that will be used by the compiler, otherwise moc takes wrong
paths and weird things happen.
Instead, generate an include file and feed it to all mocs to make sure
it's generating correct code.
Co-Author: Sebastian Holtermann <sebholt@xwmw.org>
Fixes: #16640
Diffstat (limited to 'Modules/Compiler/Intel.cmake')
-rw-r--r-- | Modules/Compiler/Intel.cmake | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Modules/Compiler/Intel.cmake b/Modules/Compiler/Intel.cmake index 02968b4..06d01f1 100644 --- a/Modules/Compiler/Intel.cmake +++ b/Modules/Compiler/Intel.cmake @@ -22,5 +22,7 @@ else() string(APPEND CMAKE_${lang}_FLAGS_MINSIZEREL_INIT " -Os") string(APPEND CMAKE_${lang}_FLAGS_RELEASE_INIT " -O3") string(APPEND CMAKE_${lang}_FLAGS_RELWITHDEBINFO_INIT " -O2 -g") + + set(CMAKE_${lang}_COMPILER_PREDEFINES_COMMAND "${CMAKE_${lang}_COMPILER}" "-QdM" "-P" "-Za" "${CMAKE_ROOT}/Modules/CMakeCXXCompilerABI.cpp") endmacro() endif() |