Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Export CMake libraries with aliases for easy use #675

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -664,6 +664,7 @@ if (EMSCRIPTEN AND enable_emscripten_asyncify)
endif()

add_library(gc ${SRC})
add_library(bdwgc::gc ALIAS gc)
target_link_libraries(gc
PRIVATE ${ATOMIC_OPS_LIBS_CMAKE} ${THREADDLLIBS_LIST})
target_include_directories(gc INTERFACE
Expand All @@ -676,6 +677,7 @@ if (enable_cplusplus)
else()
add_library(gccpp gc_badalc.cc gc_cpp.cc)
endif()
add_library(bdwgc::gccpp ALIAS gccpp)
target_link_libraries(gccpp PRIVATE gc)
target_include_directories(gccpp INTERFACE
"$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>"
Expand All @@ -687,6 +689,7 @@ if (enable_cplusplus)
else()
add_library(gctba gc_badalc.cc)
endif()
add_library(bdwgc::gctba ALIAS gctba)
target_link_libraries(gctba PRIVATE gc)
target_include_directories(gctba INTERFACE
"$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>"
Expand All @@ -697,6 +700,7 @@ endif()
if (build_cord)
set(CORD_SRC cord/cordbscs.c cord/cordprnt.c cord/cordxtra.c)
add_library(cord ${CORD_SRC})
add_library(bdwgc::cord ALIAS cord)
target_link_libraries(cord PRIVATE gc)
target_include_directories(cord INTERFACE
"$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>"
Expand Down
Loading