aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorchriseth <chris@ethereum.org>2018-02-21 13:27:11 +0800
committerGitHub <noreply@github.com>2018-02-21 13:27:11 +0800
commit16c7eabc1c01328954af35c2e93f601ed26b9776 (patch)
tree40321727602d7c4bde43d1f6bbf013c964ad6583
parent2f862b472861c384ce2ed4e8550d6794148fbee1 (diff)
parentc43953f9fe25066881938944c6a33817be8f424f (diff)
downloaddexon-solidity-16c7eabc1c01328954af35c2e93f601ed26b9776.tar
dexon-solidity-16c7eabc1c01328954af35c2e93f601ed26b9776.tar.gz
dexon-solidity-16c7eabc1c01328954af35c2e93f601ed26b9776.tar.bz2
dexon-solidity-16c7eabc1c01328954af35c2e93f601ed26b9776.tar.lz
dexon-solidity-16c7eabc1c01328954af35c2e93f601ed26b9776.tar.xz
dexon-solidity-16c7eabc1c01328954af35c2e93f601ed26b9776.tar.zst
dexon-solidity-16c7eabc1c01328954af35c2e93f601ed26b9776.zip
Merge pull request #3559 from ethereum/emscripten-fail-on-undefined
CMake: abort if linking results in undefined symbols with emscripten
-rw-r--r--cmake/EthCompilerSettings.cmake3
1 files changed, 3 insertions, 0 deletions
diff --git a/cmake/EthCompilerSettings.cmake b/cmake/EthCompilerSettings.cmake
index 7199f537..a9ed0a74 100644
--- a/cmake/EthCompilerSettings.cmake
+++ b/cmake/EthCompilerSettings.cmake
@@ -140,6 +140,9 @@ if (("${CMAKE_CXX_COMPILER_ID}" MATCHES "GNU") OR ("${CMAKE_CXX_COMPILER_ID}" MA
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -s NO_DYNAMIC_EXECUTION=1")
# Disable greedy exception catcher
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -s NODEJS_CATCH_EXIT=0")
+ # Abort if linking results in any undefined symbols
+ # Note: this is on by default in the CMake Emscripten module which we aren't using
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -s ERROR_ON_UNDEFINED_SYMBOLS=1")
add_definitions(-DETH_EMSCRIPTEN=1)
endif()
endif()