Skip to content

Commit bc8835b

Browse files
committed
hera for geth-evmc as a static lib
1 parent 18d50c0 commit bc8835b

File tree

4 files changed

+8
-4
lines changed

4 files changed

+8
-4
lines changed

cmake/ProjectWAVM.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ ExternalProject_Add(wavm
4040
-DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
4141
-DCMAKE_BUILD_TYPE=Release
4242
-DLLVM_DIR=${LLVM_DIR}
43-
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
43+
-DCMAKE_POSITION_INDEPENDENT_CODE=OFF
4444
-DCMAKE_CXX_FLAGS=-Wno-error
4545
INSTALL_COMMAND ""
4646
BUILD_BYPRODUCTS ${runtime_library} ${other_libraries}

cmake/ProjectWabt.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ ExternalProject_Add(wabt
2222
CMAKE_ARGS
2323
-DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
2424
-DCMAKE_BUILD_TYPE=Release
25-
-DWITH_EXCEPTIONS=ON
25+
-DWITH_EXCEPTIONS=OFF
2626
-DBUILD_TESTS=OFF
2727
-DBUILD_TOOLS=OFF
28-
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
28+
-DCMAKE_POSITION_INDEPENDENT_CODE=OFF
2929
INSTALL_COMMAND ""
3030
BUILD_BYPRODUCTS ${wabt_library}
3131
)

src/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ endif()
3333
target_include_directories(hera
3434
PUBLIC $<BUILD_INTERFACE:${hera_include_dir}>$<INSTALL_INTERFACE:include>
3535
)
36-
target_link_libraries(hera PUBLIC evmc::evmc PRIVATE hera-buildinfo evmc::instructions)
36+
target_link_libraries(hera PUBLIC evmc::evmc PUBLIC hera-buildinfo evmc::instructions)
3737
if(NOT WIN32)
3838
if(CMAKE_COMPILER_IS_GNUCXX)
3939
set_target_properties(hera PROPERTIES LINK_FLAGS "-Wl,--no-undefined")

src/binaryen.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -569,11 +569,15 @@ void BinaryenEngine::verifyContract(wasm::Module & module)
569569
"Contract export (\"memory\") missing."
570570
);
571571

572+
/*
573+
***** in the metering benchmarks, inline-block and inline-super both export the inline useGas functions
574+
// just going to comment this out since here since we need to change Hera for static libs anyway
572575
ensureCondition(
573576
module.exports.size() == 2,
574577
ContractValidationFailure,
575578
"Contract exports more than (\"main\") and (\"memory\")."
576579
);
580+
*/
577581

578582
// The existence of this is ensured above.
579583
wasm::Export* main_export = module.getExport(wasm::Name("main"));

0 commit comments

Comments
 (0)