mirror of
https://github.com/Kitware/CMake.git
synced 2026-05-03 12:49:50 -05:00
c8ccd5a9e3
Add Common Package Specification support to export(EXPORT).
15 lines
363 B
CMake
15 lines
363 B
CMake
add_library(foo INTERFACE)
|
|
add_library(bar INTERFACE)
|
|
|
|
add_library(test INTERFACE)
|
|
target_link_libraries(test INTERFACE foo bar)
|
|
|
|
install(TARGETS foo EXPORT foo DESTINATION .)
|
|
install(TARGETS bar EXPORT bar DESTINATION .)
|
|
|
|
export(EXPORT foo)
|
|
export(EXPORT bar NAMESPACE bar_)
|
|
|
|
install(TARGETS test EXPORT test DESTINATION .)
|
|
export(EXPORT test PACKAGE_INFO test)
|