Skip to content

Commit 434335e

Browse files
committed
Fix install public header 'RCSwitch.h' file
1 parent 706f809 commit 434335e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,12 @@ set_target_properties( ${PROJECT_NAME}-dynamic PROPERTIES SOVERSION ${SO_VERSION
8787
# Add static library, file extension OS depends, like: RCSwitch.a or RCSwitch.lib
8888
add_library( ${PROJECT_NAME} STATIC $<TARGET_OBJECTS:${PROJECT_NAME}-obj> )
8989

90+
# Add library header file
91+
set_property(TARGET ${PROJECT_NAME} PROPERTY PUBLIC_HEADER RCSwitch.h )
92+
9093
# Add install targets
91-
install(TARGETS ${PROJECT_NAME} DESTINATION lib)
9294
install(TARGETS ${PROJECT_NAME}-dynamic DESTINATION lib)
95+
install(TARGETS ${PROJECT_NAME} PUBLIC_HEADER DESTINATION include)
9396

9497
# If no has parent directory, add uninstall targets
9598
if(NOT hasParent)

0 commit comments

Comments
 (0)