mirror of
https://github.com/Kitware/CMake.git
synced 2026-02-11 09:39:49 -06:00
Modify how cmExportBuildFileGenerator::FindExportInfo collects target export information to properly record the export sets which export a target. (The old behavior treated every invocation as a separate set, which is reasonable for export(TARGETS) but does not allow referencing a target exported multiple times via export(EXPORT). This reflects recent changes to allow this for installed exports.)
10 lines
419 B
CMake
10 lines
419 B
CMake
add_library(doubleexported INTERFACE)
|
|
install(TARGETS doubleexported EXPORT exportset)
|
|
export(EXPORT exportset
|
|
FILE "${CMAKE_CURRENT_BINARY_DIR}/export1.cmake")
|
|
export(EXPORT exportset NAMESPACE test::
|
|
FILE "${CMAKE_CURRENT_BINARY_DIR}/export2.cmake")
|
|
add_library(exported INTERFACE)
|
|
target_link_libraries(exported INTERFACE doubleexported)
|
|
export(TARGETS exported FILE "${CMAKE_CURRENT_BINARY_DIR}/exports.cmake")
|