File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -125,12 +125,17 @@ endif()
125125unset (${PROJECT_NAME} _soversion)
126126
127127if (SECP256K1_BUILD_BENCHMARK)
128+ find_library (RT_LIBRARY rt)
129+ add_library (optional_rt INTERFACE )
130+ if (RT_LIBRARY)
131+ target_link_libraries (optional_rt INTERFACE rt)
132+ endif ()
128133 add_executable (secp256k1_bench bench.c)
129134 add_executable (secp256k1_bench_internal bench_internal.c)
130135 add_executable (secp256k1_bench_ecmult bench_ecmult.c)
131- target_link_libraries (secp256k1_bench secp256k1)
132- target_link_libraries (secp256k1_bench_internal secp256k1_precomputed secp256k1_asm)
133- target_link_libraries (secp256k1_bench_ecmult secp256k1_precomputed secp256k1_asm)
136+ target_link_libraries (secp256k1_bench secp256k1 optional_rt )
137+ target_link_libraries (secp256k1_bench_internal secp256k1_precomputed secp256k1_asm optional_rt )
138+ target_link_libraries (secp256k1_bench_ecmult secp256k1_precomputed secp256k1_asm optional_rt )
134139endif ()
135140
136141if (SECP256K1_BUILD_TESTS)
You can’t perform that action at this time.
0 commit comments