From d9c51f9ca1aa48696c148fd9e3abff83777b8280 Mon Sep 17 00:00:00 2001 From: Alexander Arlt Date: Mon, 5 Feb 2018 22:15:05 +0100 Subject: Set stack-size to 16MB for darwin clang. By default Apple's clang defines a stack size of 8MB, some tests require more. --- cmake/EthCompilerSettings.cmake | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/cmake/EthCompilerSettings.cmake b/cmake/EthCompilerSettings.cmake index 6d4dadeb..ddb6c426 100644 --- a/cmake/EthCompilerSettings.cmake +++ b/cmake/EthCompilerSettings.cmake @@ -93,10 +93,15 @@ if (("${CMAKE_CXX_COMPILER_ID}" MATCHES "GNU") OR ("${CMAKE_CXX_COMPILER_ID}" MA # testing on at least OS X and Ubuntu. add_compile_options(-Wno-unused-function) add_compile_options(-Wno-dangling-else) - + + if ("${CMAKE_SYSTEM_NAME}" MATCHES "Darwin") + # Set stack size to 16MB - by default Apple's clang defines a stack size of 8MB, some tests require more. + set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-stack_size -Wl,0x1000000") + endif() + # Some Linux-specific Clang settings. We don't want these for OS X. if ("${CMAKE_SYSTEM_NAME}" MATCHES "Linux") - + # TODO - Is this even necessary? Why? # See http://stackoverflow.com/questions/19774778/when-is-it-necessary-to-use-use-the-flag-stdlib-libstdc. add_compile_options(-stdlib=libstdc++) -- cgit v1.2.3