Draft: Use configure_file to generate compiler script
Summary
- The compiler script is now based on a template file
cmake/scripts/compiler.sh.in - It is generated using
configure_file()command of cmake - The cmake variables
CMAKE_CXX_FLAGSandCMAKE_CXX_COMPILERare not touched anymore - Filtering flags happens inside of the compiler script not by modifying the cmake environment
- The output of the compiler script can be activated using the
VERBOSEflag - Instead of setting the compiler, this MR uses the
CMAKE_CXX_COMPILER_LAUNCHERtechnique, i.e., the original compiler is forwarded to the script as first argument and the originalCMAKE_CXX_COMPILERvariable does not need to be touched.
Edited by Simon Praetorius