aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/test/CMakeLists.txt
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2015-06-18 03:43:17 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2015-06-18 03:43:17 +0300
commit7fa14cde1b878f4a04daf1c1f16ca21a2bc9f6fd (patch)
treed25d0a86280595b7fa32a2055f0373c070ce93c7 /test/CMakeLists.txt
parentignore Intel SDE's logs (diff)
downloadaes-tools-7fa14cde1b878f4a04daf1c1f16ca21a2bc9f6fd.tar.gz
aes-tools-7fa14cde1b878f4a04daf1c1f16ca21a2bc9f6fd.zip
test: merge block utilities
Diffstat (limited to 'test/CMakeLists.txt')
-rw-r--r--test/CMakeLists.txt37
1 files changed, 7 insertions, 30 deletions
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 4ca993e..199388d 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -1,34 +1,11 @@
-macro(test prefix)
- add_executable(test_${prefix}_encrypt_block ${prefix}_encrypt_block.c)
- target_link_libraries(test_${prefix}_encrypt_block libaesni)
- set_target_properties(test_${prefix}_encrypt_block PROPERTIES OUTPUT_NAME ${prefix}_encrypt_block)
+find_package(Boost REQUIRED COMPONENTS program_options)
- add_executable(test_${prefix}_decrypt_block ${prefix}_decrypt_block.c)
- target_link_libraries(test_${prefix}_decrypt_block libaesni)
- set_target_properties(test_${prefix}_decrypt_block PROPERTIES OUTPUT_NAME ${prefix}_decrypt_block)
-endmacro()
-
-test(aes128ecb)
-test(aes128cbc)
-test(aes128cfb)
-test(aes128ofb)
-test(aes128ctr)
-test(aes192ecb)
-test(aes192cbc)
-test(aes192cfb)
-test(aes192ofb)
-test(aes192ctr)
-test(aes256ecb)
-test(aes256cbc)
-test(aes256cfb)
-test(aes256ofb)
-test(aes256ctr)
-
-add_executable(test_encrypt_block_aes encrypt_block_aes.cpp)
-target_link_libraries(test_encrypt_block_aes libaesni libaesnixx)
+add_executable(test_encrypt_block_aes encrypt_block_aes.cpp common_aes.hpp)
+target_include_directories(test_encrypt_block_aes PRIVATE ${Boost_INCLUDE_DIRS})
+target_link_libraries(test_encrypt_block_aes libaesni libaesnixx ${Boost_LIBRARIES})
set_target_properties(test_encrypt_block_aes PROPERTIES OUTPUT_NAME encrypt_block_aes)
-add_executable(test_decrypt_block_aes decrypt_block_aes.cpp)
-target_link_libraries(test_decrypt_block_aes libaesni libaesnixx)
+add_executable(test_decrypt_block_aes decrypt_block_aes.cpp common_aes.hpp)
+target_include_directories(test_decrypt_block_aes PRIVATE ${Boost_INCLUDE_DIRS})
+target_link_libraries(test_decrypt_block_aes libaesni libaesnixx ${Boost_LIBRARIES})
set_target_properties(test_decrypt_block_aes PROPERTIES OUTPUT_NAME decrypt_block_aes)
-