Created
February 12, 2018 18:47
-
-
Save jsierles/c662f12d3ed92584ffc0c5479742160d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Fix a build bug that would cause the linker to try linking against | |
'arrow_static' even when building with -DARROW_BUILD_STATIC=off: | |
https://issues.apache.org/jira/browse/ARROW-1308 | |
Patch copied from upstream pull request: | |
https://github.com/apache/arrow/pull/931/commits/88391fe0685742cff489d0bf1a5b1a09b8d73b3b | |
From 88391fe0685742cff489d0bf1a5b1a09b8d73b3b Mon Sep 17 00:00:00 2001 | |
From: Wes McKinney <[email protected]> | |
Date: Tue, 1 Aug 2017 16:08:49 -0400 | |
Subject: [PATCH] Link utility executables to Arrow shared library if | |
ARROW_BUILD_STATIC=off | |
Change-Id: If418c42ea18aac30eae8482bba7e401c5d8258d1 | |
--- | |
cpp/src/arrow/ipc/CMakeLists.txt | 22 +++++++++++++--------- | |
1 file changed, 13 insertions(+), 9 deletions(-) | |
diff --git a/cpp/src/arrow/ipc/CMakeLists.txt b/cpp/src/arrow/ipc/CMakeLists.txt | |
index 9cc61bced..76e52a0f7 100644 | |
--- a/cpp/src/arrow/ipc/CMakeLists.txt | |
+++ b/cpp/src/arrow/ipc/CMakeLists.txt | |
@@ -90,18 +90,22 @@ install(FILES | |
writer.h | |
DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/arrow/ipc") | |
-if(MSVC) | |
- set(UTIL_LINK_LIBS | |
- arrow_static | |
- ${BOOST_FILESYSTEM_LIBRARY} | |
- ${BOOST_SYSTEM_LIBRARY}) | |
+if (ARROW_BUILD_STATIC) | |
+ set(ARROW_UTIL_LIB arrow_static) | |
else() | |
+ set(ARROW_UTIL_LIB arrow_shared) | |
+endif() | |
+ | |
+set(UTIL_LINK_LIBS | |
+ ${ARROW_UTIL_LIB} | |
+ ${BOOST_FILESYSTEM_LIBRARY} | |
+ ${BOOST_SYSTEM_LIBRARY}) | |
+ | |
+if(NOT MSVC) | |
set(UTIL_LINK_LIBS | |
- arrow_static | |
+ ${UTIL_LINK_LIBS} | |
pthread | |
- ${BOOST_FILESYSTEM_LIBRARY} | |
- ${BOOST_SYSTEM_LIBRARY} | |
- dl) | |
+ ${CMAKE_DL_LIBS}) | |
endif() | |
if (ARROW_BUILD_UTILITIES) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment