Re: [CMake] [PATCH] Support multiple arguments in CC,CXX,FC values

2010-03-15 Thread Alan W. Irwin
On 2010-03-15 09:07-0400 Brad King wrote: Teach compiler identification to support values such as export CC='gcc -g -O2' by separating the arguments on spaces. We already do this for the values of CFLAGS, CXXFLAGS, and FFLAGS. --- Hi Alan, Anyway, this patch should fix it. Please test. I

Re: [CMake] [PATCH] Support multiple arguments in CC,CXX,FC values

2010-03-15 Thread Michael Wild
On 15. Mar, 2010, at 14:59 , Brad King wrote: > Michael Wild wrote: >> On 15. Mar, 2010, at 14:37 , Brad King wrote: >>> using the "PROGRAM/PROGRAM_ARGS" option of get_filename_component() >>> which already accounts for spaces in the path. It uses an algorithm >>> similar to what the Windows com

Re: [CMake] [PATCH] Support multiple arguments in CC,CXX,FC values

2010-03-15 Thread Brad King
Michael Wild wrote: > On 15. Mar, 2010, at 14:37 , Brad King wrote: >> using the "PROGRAM/PROGRAM_ARGS" option of get_filename_component() >> which already accounts for spaces in the path. It uses an algorithm >> similar to what the Windows command prompt does. It works backwards >> from the end

Re: [CMake] [PATCH] Support multiple arguments in CC,CXX,FC values

2010-03-15 Thread Michael Wild
On 15. Mar, 2010, at 14:37 , Brad King wrote: > Michael Wild wrote: >> Won't that fail for compiler-installations with spaces in the path >> (admittedly a bad idea, but on Windows probably not that unlikely)? > > By the time the new code is reached we've already split the arguments > from the co

Re: [CMake] [PATCH] Support multiple arguments in CC,CXX,FC values

2010-03-15 Thread Brad King
Michael Wild wrote: > Won't that fail for compiler-installations with spaces in the path > (admittedly a bad idea, but on Windows probably not that unlikely)? By the time the new code is reached we've already split the arguments from the compiler itself. This is done in CMakeDetermineCCompiler.cm

Re: [CMake] [PATCH] Support multiple arguments in CC,CXX,FC values

2010-03-15 Thread Michael Wild
On 15. Mar, 2010, at 14:07 , Brad King wrote: > Anyway, this patch should fix it. Please test. > > Thanks, > -Brad > > > Modules/CMakeDetermineCompilerId.cmake |1 + > 1 files changed, 1 insertions(+), 0 deletions(-) > > diff --git a/Modules/CMakeDetermineCompilerId.cmake > b/Modules/CMak

[CMake] [PATCH] Support multiple arguments in CC,CXX,FC values

2010-03-15 Thread Brad King
Teach compiler identification to support values such as export CC='gcc -g -O2' by separating the arguments on spaces. We already do this for the values of CFLAGS, CXXFLAGS, and FFLAGS. --- Hi Alan, The standard way to do the "set and forget" approach with environment variables is export C