Rename option BUILD_STATIC_LIBRARY to WITH_STATIC_LIBRARIES
to conform to the bare Makefiles Signed-off-by: Lance Chen <cyen0312@gmail.com>
This commit is contained in:
parent
f18e8e12a8
commit
97847fa95b
@ -1,4 +1,4 @@
|
||||
option(BUILD_STATIC_LIBRARY "Build the static library?" ON)
|
||||
option(WITH_STATIC_LIBRARIES "Build the static libraries?" ON)
|
||||
option(WITH_PIC "Build the static library with PIC(Position Independent Code) enabled archives?" OFF)
|
||||
add_subdirectory(cpp)
|
||||
|
||||
@ -98,7 +98,7 @@ set_target_properties(libmosquitto PROPERTIES
|
||||
|
||||
install(TARGETS libmosquitto RUNTIME DESTINATION ${BINDIR} LIBRARY DESTINATION ${LIBDIR})
|
||||
|
||||
if (${BUILD_STATIC_LIBRARY} STREQUAL ON)
|
||||
if (${WITH_STATIC_LIBRARIES} STREQUAL ON)
|
||||
if (${WITH_PIC} STREQUAL OFF)
|
||||
add_library(libmosquitto_static STATIC ${C_SRC})
|
||||
else (${WITH_PIC} STREQUAL OFF)
|
||||
@ -114,7 +114,7 @@ if (${BUILD_STATIC_LIBRARY} STREQUAL ON)
|
||||
|
||||
target_compile_definitions(libmosquitto_static PUBLIC "LIBMOSQUITTO_STATIC")
|
||||
install(TARGETS libmosquitto_static RUNTIME DESTINATION ${BINDIR} ARCHIVE DESTINATION ${LIBDIR})
|
||||
endif (${BUILD_STATIC_LIBRARY} STREQUAL ON)
|
||||
endif (${WITH_STATIC_LIBRARIES} STREQUAL ON)
|
||||
|
||||
install(FILES mosquitto.h DESTINATION ${INCLUDEDIR})
|
||||
|
||||
|
@ -18,7 +18,7 @@ set_target_properties(mosquittopp PROPERTIES
|
||||
)
|
||||
install(TARGETS mosquittopp RUNTIME DESTINATION ${BINDIR} LIBRARY DESTINATION ${LIBDIR})
|
||||
|
||||
if (${BUILD_STATIC_LIBRARY} STREQUAL ON)
|
||||
if (${WITH_STATIC_LIBRARIES} STREQUAL ON)
|
||||
if (${WITH_PIC} STREQUAL OFF)
|
||||
add_library(mosquittopp_static STATIC
|
||||
$<TARGET_OBJECTS:libmosquitto_obj>
|
||||
@ -40,7 +40,7 @@ if (${BUILD_STATIC_LIBRARY} STREQUAL ON)
|
||||
|
||||
target_compile_definitions(mosquittopp_static PUBLIC "LIBMOSQUITTO_STATIC")
|
||||
install(TARGETS mosquittopp_static RUNTIME DESTINATION ${BINDIR} ARCHIVE DESTINATION ${LIBDIR})
|
||||
endif (${BUILD_STATIC_LIBRARY} STREQUAL ON)
|
||||
endif (${WITH_STATIC_LIBRARIES} STREQUAL ON)
|
||||
|
||||
install(FILES mosquittopp.h DESTINATION ${INCLUDEDIR})
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user