Files
Fred WrightandMojca Miklavec a6bc011eaf libaes_siv: new port
A C implementation of AES-SIV.

This is likely to become a dependency of ntpsec.

The patches here have already been accepted upstream.

TESTED:
Ran 'test' and 'install' on a Mac Pro 10.9 and 10.14, a MacBook Pro
10.9, a PowerBook 10.5, and VMs for 10-5-10.13, both with and without
the 'doc' variant.
2019-02-28 23:33:47 +01:00

29 lines
1.2 KiB
Diff

--- CMakeLists.txt.orig 2017-02-28 14:56:44.000000000 -0800
+++ CMakeLists.txt 2019-02-15 19:07:22.000000000 -0800
@@ -23,19 +23,24 @@ set(CMAKE_C_FLAGS_MINSIZEREL "-Wall -Wco
endif(CMAKE_C_COMPILER_ID STREQUAL Clang OR CMAKE_C_COMPILER_ID STREQUAL AppleClang)
find_package(OpenSSL 1.0.1 REQUIRED COMPONENTS Crypto)
-find_program(A2X a2x)
+if(NOT DISABLE_DOCS)
+ find_program(A2X a2x)
+endif(NOT DISABLE_DOCS)
configure_file(config.h.in config.h)
add_library(aes_siv SHARED aes_siv.c)
+target_include_directories(aes_siv PUBLIC ${OPENSSL_INCLUDE_DIR})
target_link_libraries(aes_siv ${OPENSSL_CRYPTO_LIBRARY})
set_target_properties(aes_siv PROPERTIES VERSION "1.0.0" SOVERSION 1)
add_library(aes_siv_static STATIC aes_siv.c)
+target_include_directories(aes_siv_static PUBLIC ${OPENSSL_INCLUDE_DIR})
target_link_libraries(aes_siv_static ${OPENSSL_CRYPTO_LIBRARY})
set_target_properties(aes_siv_static PROPERTIES OUTPUT_NAME aes_siv)
add_executable(runtests aes_siv_test.c tests.c)
+target_include_directories(runtests PUBLIC ${OPENSSL_INCLUDE_DIR})
target_link_libraries(runtests ${OPENSSL_CRYPTO_LIBRARY})
if(ENABLE_COVERAGE)
target_compile_options(runtests PRIVATE "--coverage")