]> wagner.pp.ru Git - openssl-gost/engine.git/commitdiff
MSVC: Skip building Linux-only binaries
authorVitaly Chikunov <vt@altlinux.org>
Sat, 4 Dec 2021 09:35:46 +0000 (12:35 +0300)
committerDmitry Belyavskiy <beldmit@users.noreply.github.com>
Sat, 11 Dec 2021 16:45:14 +0000 (19:45 +0300)
Signed-off-by: Vitaly Chikunov <vt@altlinux.org>
CMakeLists.txt

index 26161961fb113093f9c2288e1ad44c853d1bcf72..684a93d6003f2ac7406c16eed28d733688e4c82d 100644 (file)
@@ -260,11 +260,13 @@ add_test(NAME sign/verify-with-engine COMMAND test_sign)
 set_tests_properties(sign/verify-with-engine
   PROPERTIES ENVIRONMENT "${TEST_ENVIRONMENT_ENGINE}")
 
-add_executable(test_tls test_tls.c)
-target_link_libraries(test_tls OpenSSL::SSL)
-add_test(NAME TLS-with-engine COMMAND test_tls)
-set_tests_properties(TLS-with-engine
-  PROPERTIES ENVIRONMENT "${TEST_ENVIRONMENT_ENGINE}")
+if(NOT MSVC)
+  add_executable(test_tls test_tls.c)
+  target_link_libraries(test_tls OpenSSL::SSL)
+  add_test(NAME TLS-with-engine COMMAND test_tls)
+  set_tests_properties(TLS-with-engine
+    PROPERTIES ENVIRONMENT "${TEST_ENVIRONMENT_ENGINE}")
+endif()
 
 add_executable(test_context test_context.c)
 target_link_libraries(test_context OpenSSL::Crypto)
@@ -301,8 +303,10 @@ if(NOT SKIP_PERL_TESTS)
     endif()
 endif()
 
-add_executable(sign benchmark/sign.c)
-target_link_libraries(sign gost_core gost_err ${CLOCK_GETTIME_LIB})
+if(NOT MSVC)
+  add_executable(sign benchmark/sign.c)
+  target_link_libraries(sign gost_core gost_err ${CLOCK_GETTIME_LIB})
+endif()
 
 # All that may need to load just built engine will have path to it defined.
 set(BINARY_TESTS_TARGETS
@@ -315,8 +319,10 @@ set(BINARY_TESTS_TARGETS
         test_context
         test_keyexpimp
         test_gost89
-       test_tls
         )
+if(NOT MSVC)
+  list(APPEND BINARY_TESTS_TARGETS test_tls)
+endif()
 set_property(TARGET ${BINARY_TESTS_TARGETS} APPEND PROPERTY COMPILE_DEFINITIONS ENGINE_DIR="${OUTPUT_DIRECTORY}")
 
 add_library(gost_core STATIC ${GOST_LIB_SOURCE_FILES})