Skip to content

Commit

Permalink
build: remove warning until it's reproducible
Browse files Browse the repository at this point in the history
Also remove the interface it was attached to since it's no longer needed.
This removal simplifies the next commit.
  • Loading branch information
theuni committed Mar 21, 2023
1 parent 9c8c4f4 commit 36b0adf
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,6 @@ if(SECP256K1_BUILD_STATIC)
list(APPEND ${PROJECT_NAME}_installables secp256k1_static)
endif()

add_library(binary_interface INTERFACE)
target_compile_definitions(binary_interface INTERFACE
$<$<C_COMPILER_ID:MSVC>:_CRT_SECURE_NO_WARNINGS>
)

add_library(link_library INTERFACE)
if(SECP256K1_BUILD_SHARED)
target_link_libraries(link_library INTERFACE secp256k1)
Expand All @@ -69,21 +64,17 @@ endif()

if(SECP256K1_BUILD_BENCHMARK)
add_executable(bench bench.c)
target_link_libraries(bench binary_interface link_library)
target_link_libraries(bench link_library)
add_executable(bench_internal bench_internal.c ${internal_obj})
target_link_libraries(bench_internal binary_interface)
add_executable(bench_ecmult bench_ecmult.c ${internal_obj})
target_link_libraries(bench_ecmult binary_interface)
endif()

if(SECP256K1_BUILD_TESTS)
add_executable(noverify_tests tests.c ${internal_obj})
target_link_libraries(noverify_tests binary_interface)
add_test(noverify_tests noverify_tests)
if(NOT CMAKE_BUILD_TYPE STREQUAL "Coverage")
add_executable(tests tests.c ${internal_obj})
target_compile_definitions(tests PRIVATE VERIFY)
target_link_libraries(tests binary_interface)
add_test(tests tests)
endif()
endif()
Expand All @@ -92,13 +83,12 @@ if(SECP256K1_BUILD_EXHAUSTIVE_TESTS)
# Note: do not include $<TARGET_OBJECTS:precomputed> in exhaustive_tests (it uses runtime-generated tables).
add_executable(exhaustive_tests tests_exhaustive.c ${common_obj})
target_compile_definitions(exhaustive_tests PRIVATE $<$<NOT:$<CONFIG:Coverage>>:VERIFY>)
target_link_libraries(exhaustive_tests binary_interface)
add_test(exhaustive_tests exhaustive_tests)
endif()

if(SECP256K1_BUILD_CTIME_TESTS)
add_executable(ctime_tests ctime_tests.c)
target_link_libraries(ctime_tests binary_interface link_library)
target_link_libraries(ctime_tests link_library)
endif()

install(TARGETS ${${PROJECT_NAME}_installables}
Expand Down

0 comments on commit 36b0adf

Please sign in to comment.