[CMake] Re: [cmake 2.5 CVS] CMAKE_${LANG}_FLAGS is initialized with
space
Rodolfo Schulz de Lima
rodolfo at rodsoft.org
Fri Dec 14 15:07:13 EST 2007
Brandon Van Every escreveu:
> On Dec 14, 2007 7:43 AM, Rodolfo Lima <rodolfo at rodsoft.org> wrote:
> If CMAKE_CXX_FLAGS is actually null, then your script should terminate
> with an error. Correct syntax is either plain CMAKE_CXX_FLAGS or
> "${CMAKE_CXX_FLAGS}". What you've written would work only if the
> variable evaluates to a single variable name, or a single string
> constant.
Sorry, my mistake, I'd normally surround it with quotation marks.
> A cmake -P script has no cache. On my Windows Vista machine, your
> code gives me:
>
> C:\devel\moz>cmake -P flags.cmake
> CMake Error: Error in cmake code at
> C:/devel/moz/flags.cmake:1:
> if had incorrect arguments: ${CMAKE_CXX_FLAGS} STREQUAL " " (Unknown arguments s
> pecified).
> Called from: [1] C:/devel/moz/flags.cmake
It seems to be a unix problem... I'll dig cmake's source code when I get
home, hopefully to find the culprit.
Regards,
rod
More information about the CMake
mailing list