commit 0d61882d80d474b49e7f1c3103731310249c1d5f
parent 9440f9aefec9a264a8f148718ff0cc2ff25127d5
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
Date: Sun, 30 Oct 2022 14:12:38 +0300
configure: minor refactoring for check for libcurl-based tests
Diffstat:
3 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/configure.ac b/configure.ac
@@ -2410,7 +2410,11 @@ AS_IF([test "$enable_curl" != "no"],
enable_curl=no
])
])
-AM_CONDITIONAL([HAVE_CURL], [test "x$enable_curl" = "xyes"])
+AM_CONDITIONAL([RUN_LIBCURL_TESTS], [test "x$enable_curl" = "xyes"])
+AS_IF([test "x$enable_curl" = "xyes"],
+ [MSG_CURL="yes"],
+ [MSG_CURL="no, many unit tests will not run"]
+)
mhd_have_libmagic="no"
SAVE_LIBS="$LIBS"
@@ -4247,10 +4251,6 @@ AS_UNSET([fin_lib_CPPFLAGS])
AS_UNSET([fin_lib_CFLAGS])
AS_UNSET([fin_lib_LDFLAGS])
-AS_IF([test "x$enable_curl" != "xyes"],
- [MSG_CURL="no, many unit tests will not run"],
- [MSG_CURL="yes"])
-
AS_VAR_IF([os_is_windows], ["yes"],
[os_ver_msg="
Target W32 ver: ${mhd_w32_ver_msg}"], [AS_UNSET([[os_ver_msg]])])
diff --git a/src/Makefile.am b/src/Makefile.am
@@ -1,5 +1,5 @@
# This Makefile.am is in the public domain
-if HAVE_CURL
+if RUN_LIBCURL_TESTS
curltests = testcurl
if HAVE_ZZUF
if HAVE_SOCAT
diff --git a/src/testcurl/Makefile.am b/src/testcurl/Makefile.am
@@ -80,7 +80,7 @@ THREAD_ONLY_TESTS += \
endif
endif
-if HAVE_CURL
+if RUN_LIBCURL_TESTS
check_PROGRAMS = \
test_get \
test_head \