Skip to content

Commit

Permalink
create db_find_secondary_test.wasm from wast when cdt enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
spoonincode committed Nov 12, 2024
1 parent 5266c59 commit a97b75c
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion unittests/test-contracts/db_find_secondary_test/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,10 @@
configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/db_find_secondary_test.wasm ${CMAKE_CURRENT_BINARY_DIR}/db_find_secondary_test.wasm COPYONLY )
if(EOSIO_COMPILE_TEST_CONTRACTS)
add_custom_command(OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/db_find_secondary_test.wasm"
COMMAND "${CDT_ROOT}/bin/eosio-wast2wasm" "${CMAKE_CURRENT_SOURCE_DIR}/db_find_secondary_test.wast" -o "${CMAKE_CURRENT_BINARY_DIR}/db_find_secondary_test.wasm"
DEPENDS "${CMAKE_CURRENT_SOURCE_DIR}/db_find_secondary_test.wast")

add_custom_target(gen_db_find_secondary_test_wasm ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/db_find_secondary_test.wasm")
else()
configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/db_find_secondary_test.wasm ${CMAKE_CURRENT_BINARY_DIR}/db_find_secondary_test.wasm COPYONLY )
endif()
configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/db_find_secondary_test.abi ${CMAKE_CURRENT_BINARY_DIR}/db_find_secondary_test.abi COPYONLY )

0 comments on commit a97b75c

Please sign in to comment.