[CMake] Static and DLL builds in single solution
Klaim - Joël Lamotte
mjklaim at gmail.com
Sat Dec 8 10:34:35 EST 2012
For example:
add_library( mylibStatic STATIC ${MYLIB_ALL_SOURCES} ) # generate the
static version of the lib
add_library( mylibDLL SHARED ${MYLIB_ALL_SOURCES} ) # generate the dll
loaded at startup version of the same lib, same sources
add_library( mylibExtension MODULE ${MYLIB_ALL_SOURCES} ) # generate the
dll loadable when running version of the same lib, same sources
This works well if you keem the names different. Anyway, adding some CMake
options to let the user choose what is generated could be good too.
Joel Lamotte
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20121208/743e185e/attachment.htm>
More information about the CMake
mailing list