Skip to content

Commit 1703af1

Browse files
committed
Fix downstream build when Flibcpp is compiled as static libs
1 parent ea0f00c commit 1703af1

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

cmake/FlibcppConfig.cmake.in

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,10 @@ endif()
99

1010
set(Flibcpp_LIBRARIES @FLIBCPP_LIBRARIES@)
1111

12+
set(Flibcpp_BUILD_SHARED_LIBS @BUILD_SHARED_LIBS@)
13+
14+
if (NOT "@Flibcpp_BUILD_SHARED_LIBS@")
15+
# Downstream libraries must find and link to the C++ runtimes themselves since
16+
# they can't use the shared library dependencies
17+
enable_language(CXX)
18+
endif()

0 commit comments

Comments
 (0)