Modular building of kde modules

Brad King brad.king at kitware.com
Wed Mar 18 13:50:45 CET 2009


Parker Coates wrote:
> I've often wished CMake had a construct equivalent to Python's "if
> __name__ == '__main__' :" that would let you run certain code only if
> the current file was being run as the "top level" CMakeLists.txt.

if("${CMAKE_CURRENT_SOURCE_DIR}" STREQUAL "${CMAKE_SOURCE_DIR}")

-Brad


More information about the Kde-buildsystem mailing list