added static library (by Jose)

pull/40/head
Nestal Wan 2012-06-07 00:14:21 +08:00
parent 01effa1f60
commit d24440fa48
1 changed files with 4 additions and 0 deletions

View File

@ -69,6 +69,7 @@ add_definitions(
)
add_library( grive SHARED ${LIBGRIVE_SRC} ${OPT_SRC} )
add_library( grive-static STATIC ${LIBGRIVE_SRC} ${OPT_SRC} )
target_link_libraries( grive
${CURL_LIBRARIES}
@ -85,12 +86,15 @@ set_target_properties(grive PROPERTIES
SOVERSION 0 VERSION ${GRIVE_VERSION}
)
set_target_properties(grive grive-static PROPERTIES OUTPUT_NAME grive)
if ( LIB_INSTALL_DIR )
else()
set ( LIB_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/lib )
endif()
install(TARGETS grive LIBRARY DESTINATION ${LIB_INSTALL_DIR} )
install(TARGETS grive-static ARCHIVE DESTINATION ${LIB_INSTALL_DIR} )
install(FILES ${DRIVE_HEADERS} DESTINATION include/grive/drive)
install(FILES ${PROTOCOL_HEADERS} DESTINATION include/grive/protocol)
install(FILES ${UTIL_HEADERS} DESTINATION include/grive/util)