aboutsummaryrefslogtreecommitdiffstats
path: root/libsolc/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'libsolc/CMakeLists.txt')
-rw-r--r--libsolc/CMakeLists.txt3
1 files changed, 3 insertions, 0 deletions
diff --git a/libsolc/CMakeLists.txt b/libsolc/CMakeLists.txt
index dfdf8162..7fb4aa05 100644
--- a/libsolc/CMakeLists.txt
+++ b/libsolc/CMakeLists.txt
@@ -1,4 +1,7 @@
if (EMSCRIPTEN)
+ # Specify which functions to export in soljson.js.
+ # Note that additional Emscripten-generated methods needed by solc-js are
+ # defined to be exported in cmake/EthCompilerSettings.cmake.
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -s EXPORTED_FUNCTIONS='[\"_solidity_license\",\"_solidity_version\",\"_solidity_compile\"]' -s RESERVED_FUNCTION_POINTERS=20")
add_executable(soljson libsolc.cpp libsolc.h)
target_link_libraries(soljson PRIVATE solidity)