From 366fba38af105be606c8bca2afe54ccacfe13df2 Mon Sep 17 00:00:00 2001 From: Martin Grund Date: Wed, 9 Dec 2015 10:06:51 -0800 Subject: [PATCH] IMPALA-2761: OS X: Open SSL and Standard Library On OS X we need to link to the toolchain OpenSSL since Apple's version is too old. In addition, we need to manually specify the version of the standard library to avoid linker errors because Apple's default is libc++. Change-Id: I1e3d580fb94f5a731ef53fa3d7a7e89e58155147 Reviewed-on: http://gerrit.cloudera.org:8080/1605 Reviewed-by: Martin Grund Readability: Martin Grund Tested-by: Internal Jenkins --- CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index d231fe86c..4c4795b4a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -73,6 +73,9 @@ if (IMPALA_TOOLCHAIN) set_dep_root(SNAPPY) set_dep_root(THRIFT) set_dep_root(ZLIB) + if (APPLE) + set_dep_root(OPENSSL) + endif() endif () # find libraries that will be statically linked if they were compiled with -fPIC @@ -278,3 +281,5 @@ add_custom_target(loadtestdata add_custom_target(benchmark_run COMMAND ${CMAKE_SOURCE_DIR}/be/bin/run_hive_benchmark.py ) + +SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -stdlib=libstdc++") \ No newline at end of file