Skip to content

Commit

Permalink
Move cmake modules into own/clearer directory
Browse files Browse the repository at this point in the history
  • Loading branch information
halderen committed Jul 27, 2023
1 parent c97d646 commit a51b6d3
Show file tree
Hide file tree
Showing 19 changed files with 16 additions and 16 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ message(STATUS "Build Configuration: ${CMAKE_BUILD_TYPE}")

# Build Modules Path
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH}
${CMAKE_SOURCE_DIR}/modules
${CMAKE_SOURCE_DIR}/cmake/modules
)

# Custom Modules
Expand Down
6 changes: 3 additions & 3 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ EXTRA_DIST = $(srcdir)/CMakeLists.txt \
$(srcdir)/FIPS-NOTES.md \
$(srcdir)/LICENSE \
$(srcdir)/m4/*.m4 \
$(srcdir)/modules/*.cmake \
$(srcdir)/modules/tests/*.c \
$(srcdir)/modules/tests/*.cpp \
$(srcdir)/cmake/modules/*.cmake \
$(srcdir)/cmake/modules/tests/*.c \
$(srcdir)/cmake/modules/tests/*.cpp \
$(srcdir)/OSX-NOTES.md \
$(srcdir)/README.md \
$(srcdir)/win32/convarch/convarch.vcxproj.in \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ if(WITH_CRYPTO_BACKEND STREQUAL "botan")

# acx_botan_ecc.m4
if(ENABLE_ECC)
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_botan_ecc.cpp)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_botan_ecc.cpp)
try_run(RUN_ECC COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -198,7 +198,7 @@ if(WITH_CRYPTO_BACKEND STREQUAL "botan")
# acx_botan_eddsa.m4
if(ENABLE_EDDSA)
# ED25519
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_botan_ed25519.cpp)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_botan_ed25519.cpp)
try_run(RUN_ED25519 COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -218,7 +218,7 @@ if(WITH_CRYPTO_BACKEND STREQUAL "botan")

# acx_botan_gost.m4
if(ENABLE_GOST)
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_botan_gost.cpp)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_botan_gost.cpp)
try_run(RUN_GOST COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -244,7 +244,7 @@ if(WITH_CRYPTO_BACKEND STREQUAL "botan")
set(HAVE_AES_KEY_WRAP 1)

# acx_botan_rfc5649.m4
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_botan_rfc5649.cpp)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_botan_rfc5649.cpp)
try_run(RUN_AES_KEY_WRAP_PAD COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -259,7 +259,7 @@ if(WITH_CRYPTO_BACKEND STREQUAL "botan")
endif()

# acx_botan_rawpss.m4
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_botan_rawpss.cpp)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_botan_rawpss.cpp)
try_run(RUN_RAWPSS COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand Down Expand Up @@ -299,7 +299,7 @@ elseif(WITH_CRYPTO_BACKEND STREQUAL "openssl")

# acx_openssl_ecc.m4
if(ENABLE_ECC)
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_openssl_ecc.c)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_openssl_ecc.c)
try_run(RUN_ECC COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -320,7 +320,7 @@ elseif(WITH_CRYPTO_BACKEND STREQUAL "openssl")
# acx_openssl_eddsa.m4
if(ENABLE_EDDSA)
# ED25519
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_openssl_ed25519.c)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_openssl_ed25519.c)
try_run(RUN_ED25519 COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -335,7 +335,7 @@ elseif(WITH_CRYPTO_BACKEND STREQUAL "openssl")
message(FATAL_ERROR ${error_msg})
endif()
# ED448
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_openssl_ed448.c)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_openssl_ed448.c)
try_run(RUN_ED448 COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -354,7 +354,7 @@ elseif(WITH_CRYPTO_BACKEND STREQUAL "openssl")

# acx_openssl_gost.m4
if(ENABLE_GOST)
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_openssl_gost.c)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_openssl_gost.c)
try_run(RUN_GOST COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -374,7 +374,7 @@ elseif(WITH_CRYPTO_BACKEND STREQUAL "openssl")

# acx_openssl_fips.m4
if(ENABLE_FIPS)
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_openssl_fips.c)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_openssl_fips.c)
try_run(RUN_FIPS COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -393,7 +393,7 @@ elseif(WITH_CRYPTO_BACKEND STREQUAL "openssl")
endif(ENABLE_FIPS)

# acx_openssl_rfc3349
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_openssl_rfc3394.c)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_openssl_rfc3394.c)
try_run(RUN_AES_KEY_WRAP COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand All @@ -408,7 +408,7 @@ elseif(WITH_CRYPTO_BACKEND STREQUAL "openssl")
endif()

# acx_openssl_rfc5649
set(testfile ${CMAKE_SOURCE_DIR}/modules/tests/test_openssl_rfc5649.c)
set(testfile ${CMAKE_SOURCE_DIR}/cmake/modules/tests/test_openssl_rfc5649.c)
try_run(RUN_AES_KEY_WRAP_PAD COMPILE_RESULT
"${CMAKE_BINARY_DIR}/prebuild_santity_tests" ${testfile}
LINK_LIBRARIES ${CRYPTO_LIBS}
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit a51b6d3

Please sign in to comment.