[CMake] namespace support
Peter Kümmel
syntheticpp at gmx.net
Thu Feb 3 12:20:27 EST 2011
On 03.02.2011 17:20, Peter Kümmel wrote:
> Because good solution is not available
> I've added the mentioned namespace support
> to CMake:
>
> namespace(<string>)
> endnamespace()
>
> With attached patch it is possible to write
> code like this (imagine antiX.cpp does not
> compile when the macro X is set):
>
> namespace(x)
> add_definitions(-DX)
> add_library(X x.cpp)
> endnamespace()
> add_library(antiX antiX.cpp)
>
>
> The ticket is here
> http://www.cmake.org/Bug/view.php?id=11793
>
>
> I hope it could be added in this or an
> similar form to CMake.
>
For simpler testing I've uploaded
Windows and Linux binaries here:
https://sourceforge.net/projects/cmakescript/files/CMake%20namespace/
Peter
More information about the CMake
mailing list