Skip to content

Commit

Permalink
Add an install build target (#18)
Browse files Browse the repository at this point in the history
  • Loading branch information
reneme authored and hrantzsch committed Dec 18, 2019
1 parent 09fd0c3 commit a85ac82
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,15 @@ else (WIN32) # assuming Linux

endif (WIN32)

add_library (${PROJECT_NAME} ${SOURCES})
add_library(${PROJECT_NAME} ${SOURCES})
target_include_directories(${PROJECT_NAME} PRIVATE ${KEYCHAIN_INCLUDE_DIRS})
target_link_libraries(${PROJECT_NAME} ${KEYCHAIN_LIBRARIES})
set_target_properties(${PROJECT_NAME} PROPERTIES PUBLIC_HEADER "keychain.h")
target_link_libraries(${PROJECT_NAME} PUBLIC ${KEYCHAIN_LIBRARIES})

install(TARGETS ${PROJECT_NAME}
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
PUBLIC_HEADER DESTINATION include/keychain)

if (BUILD_TESTS)
add_subdirectory("test")
Expand Down

0 comments on commit a85ac82

Please sign in to comment.