Skip to content

Commit c20bb9b

Browse files
steve-downeyClausKlein
authored andcommitted
Add back cmake export file
Add the EXPORT component for the header install components.
1 parent ab33068 commit c20bb9b

File tree

2 files changed

+20
-1
lines changed

2 files changed

+20
-1
lines changed

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ set(CMAKE_VERIFY_INTERFACE_HEADER_SETS ON)
3737
add_library(beman_optional26 INTERFACE)
3838
target_sources(
3939
beman_optional26
40-
PUBLIC FILE_SET beman_optional26_headers TYPE HEADERS BASE_DIRS src include
40+
PUBLIC FILE_SET beman_optional26_headers TYPE HEADERS BASE_DIRS include
4141
)
4242

4343
if(OPTIONAL26_ENABLE_TESTING)

include/beman/optional26/CMakeLists.txt

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,22 @@ install(
2020
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
2121
COMPONENT beman_optional26_development
2222
)
23+
24+
install(
25+
TARGETS beman_optional26
26+
EXPORT beman_optional26_export
27+
DESTINATION
28+
${CMAKE_INSTALL_LIBDIR}
29+
FILE_SET beman_optional26_headers
30+
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
31+
COMPONENT beman_optional26_development
32+
)
33+
34+
install(
35+
EXPORT beman_optional26_export
36+
DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/beman/optional26/
37+
NAMESPACE Beman::Optional26::
38+
FILE beman_optional26.cmake
39+
EXPORT_LINK_INTERFACE_LIBRARIES
40+
COMPONENT beman_optional26_development
41+
)

0 commit comments

Comments
 (0)