[CMake] Adding C(XX)FLAGS by using an environment variable?

2008-07-02 Thread Mike Arthur
I'm wanting to try and add C(XX)FLAGS by using an environment variable so I can pass -fmessage-length=0 only when compiling inside Eclipse. Is there any way to do this? CMake doesn't seem to respect C(XX)FLAGS as environment variables at make time. -- Cheers, Mike Arthur

Re: [CMake] Adding C(XX)FLAGS by using an environment variable?

2008-07-02 Thread Alan W. Irwin
On 2008-07-02 11:41+0100 Mike Arthur wrote: I'm wanting to try and add C(XX)FLAGS by using an environment variable so I can pass -fmessage-length=0 only when compiling inside Eclipse. Is there any way to do this? CMake doesn't seem to respect C(XX)FLAGS as environment variables at make time.

Re: [CMake] Adding C(XX)FLAGS by using an environment variable?

2008-07-02 Thread Mike Jackson
On Jul 2, 2008, at 6:41 AM, Mike Arthur wrote: I'm wanting to try and add C(XX)FLAGS by using an environment variable so I can pass -fmessage-length=0 only when compiling inside Eclipse. Is there any way to do this? CMake doesn't seem to respect C(XX) FLAGS as environment variables at

Re: [CMake] Adding C(XX)FLAGS by using an environment variable?

2008-07-02 Thread Mike Jackson
On Jul 2, 2008, at 11:10 AM, Mike Arthur wrote: On Wednesday 02 July 2008 16:05:09 you wrote: Are you using the Eclipse generator or just the Makefiles generator? Also what version of CMake. Makefiles generator, CMake 2.6 so I don't want to do it at generation time. I'll try Alan's

Re: [CMake] Adding C(XX)FLAGS by using an environment variable?

2008-07-02 Thread Mike Arthur
On Wednesday 02 July 2008 16:24:25 you wrote: What problems does having the -fmessage-length=0 flag in a   makefile cause? It makes the output ugly if you are building from the console. Sounds like a lame reason I know! Really this is working around a limitation in Eclipse's CDT. -- Cheers,

Re: [CMake] Adding C(XX)FLAGS by using an environment variable?

2008-07-02 Thread Mike Jackson
Huh.. I thought it actually made it look better. Beauty is in the eyes of the beholder. :-) You might just want to put and OPTION(..) in your cmake file to toggle it on and off. Although each time you toggle the value everything is going to get rebuilt because the flags get changed.

Re: [CMake] Adding C(XX)FLAGS by using an environment variable?

2008-07-02 Thread Mike Arthur
On Wednesday 02 July 2008 15:51:03 you wrote: export CC='gcc -g' Is it just 'export CXX' for C++ compiler? -- Cheers, Mike Arthur ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake

Re: [CMake] Adding C(XX)FLAGS by using an environment variable?

2008-07-02 Thread Alan W. Irwin
On 2008-07-02 18:23+0100 Mike Arthur wrote: On Wednesday 02 July 2008 15:51:03 you wrote: export CC='gcc -g' Is it just 'export CXX' for C++ compiler? Yes. For future reference the only documentation for setting compiler flags through environment variables that I can find at the present