Skip to content

Commit 93bc564

Browse files
authored
fix(cmake): add ALIAS target for build-tree consumption (#941)
The vcpkg usage file documents network_system::network_system as the consumer target, but the CMakeLists.txt lacked an explicit ALIAS. While install(EXPORT ... NAMESPACE network_system::) creates the namespaced target at install time, build-tree consumption via FetchContent or add_subdirectory fails without it. Closes #940
1 parent f6c9126 commit 93bc564

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -533,6 +533,9 @@ add_library(network_system
533533
src/internal/quic_socket.cpp
534534
)
535535

536+
# Alias for build-tree consumers (FetchContent / add_subdirectory)
537+
add_library(network_system::network_system ALIAS network_system)
538+
536539
# Suppress warnings inherited from parent project (especially from ASIO)
537540
# WARNING: Suppressions removed for strict code quality check.
538541
# Fix the code instead of suppressing warnings!

0 commit comments

Comments
 (0)