Merge pull request #829 from yegorich/cmake-install-liavrdude

CMake: add initial support for installing lib and include files
This commit is contained in:
Jörg Wunsch 2022-01-21 21:37:21 +01:00 committed by GitHub
commit 512cce405c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 11 additions and 1 deletions

View File

@ -586,7 +586,12 @@ add_library(libavrdude
${BISON_Parser_OUTPUTS}
)
set_target_properties(libavrdude PROPERTIES PREFIX "")
set_target_properties(libavrdude PROPERTIES
PREFIX ""
PUBLIC_HEADER "libavrdude.h"
VERSION 1.0.0
SOVERSION 1
)
target_include_directories(libavrdude
PUBLIC
@ -625,5 +630,10 @@ target_link_libraries(avrdude PUBLIC libavrdude)
# =====================================
install(TARGETS avrdude DESTINATION bin)
install(TARGETS libavrdude
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
PUBLIC_HEADER DESTINATION include COMPONENT dev
)
install(FILES "${PROJECT_BINARY_DIR}/avrdude.conf" TYPE SYSCONF)
install(FILES avrdude.1 TYPE MAN)