diff options
author | Vitaly Chikunov <vt@altlinux.org> | 2021-12-07 12:33:41 +0300 |
---|---|---|
committer | Dmitry Belyavskiy <beldmit@users.noreply.github.com> | 2021-12-11 19:45:14 +0300 |
commit | 7255dcf52d88fb99468023466b0554d76a48f862 (patch) | |
tree | f2f94aa74b2b15f0a24e59b2d1cbfb16945f6849 /CMakeLists.txt | |
parent | fd3fc7d7ab1006a5e2768cfe62bb51dd82d2fb7d (diff) | |
download | gost-engine-7255dcf52d88fb99468023466b0554d76a48f862.zip gost-engine-7255dcf52d88fb99468023466b0554d76a48f862.tar.gz gost-engine-7255dcf52d88fb99468023466b0554d76a48f862.tar.bz2 |
CMake: Test presence of prove for perl tests
This will skip tests on Windows, due to prove being `.bat' file and cmake will
be unable to run it.
Also, `HAVE_TEST2_V0' is renamed to be more meaningful.
Signed-off-by: Vitaly Chikunov <vt@altlinux.org>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index e1c4e1d..0a53cba 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -290,8 +290,9 @@ add_test(NAME gost89 COMMAND test_gost89) if(NOT SKIP_PERL_TESTS) execute_process(COMMAND perl -MTest2::V0 -e "" - ERROR_QUIET RESULT_VARIABLE HAVE_TEST2_V0) - if(NOT HAVE_TEST2_V0) + ERROR_QUIET RESULT_VARIABLE MISSING_TEST2_V0) + find_program(HAVE_PROVE NAMES prove) + if(NOT MISSING_TEST2_V0 AND HAVE_PROVE) add_test(NAME engine COMMAND prove --merge -PWrapOpenSSL ${CMAKE_CURRENT_SOURCE_DIR}/test :: engine) set_tests_properties(engine PROPERTIES ENVIRONMENT "${TEST_ENVIRONMENT_ENGINE}") |