Hi,
I'd like to be able to write a macro like this:
macro(my_macro SOME_TARGET)
if (isStaticLibraryTarget(${SOME_TARGET})
message(FATAL "This macro can only be used with shared libraries")
endif()
endmacro()
add_library(libshared SHARED shared.cpp)
my_macro(libshared) # Works
add_library(libstatic static.cpp)
my_macro(libstatic) # Fatal
Is it possible to whether a target library is shared or static in a macro?
Thanks,
Steve.
_______________________________________________
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake