mirror of
https://github.com/curl/curl.git
synced 2026-01-26 15:03:21 +00:00
tests/buildinfo: former "disabled" now provides more info
This tool now contains ON/OFF information about features in the build. This way, runtests gets both positive and negative feature presence with this. Allows for more flexibility and avoids having to duplicate the names. Closes #17180
This commit is contained in:
parent
2ab6b9d405
commit
1968b32afd
@ -518,8 +518,14 @@ sub checksystemfeatures {
|
||||
@version = <$versout>;
|
||||
close($versout);
|
||||
|
||||
open(my $disabledh, "-|", server_exe('disabled', 'TOOL'));
|
||||
@disabled = <$disabledh>;
|
||||
open(my $disabledh, "-|", server_exe('buildinfo', 'TOOL'));
|
||||
while(<$disabledh>) {
|
||||
if($_ =~ /([^:]*): ([ONF]*)/) {
|
||||
my ($val, $toggle) = ($1, $2);
|
||||
push @disabled, $val if($toggle eq "OFF");
|
||||
$feature{$val} = 1 if($toggle eq "ON");
|
||||
}
|
||||
}
|
||||
close($disabledh);
|
||||
|
||||
if($disabled[0]) {
|
||||
@ -812,29 +818,8 @@ sub checksystemfeatures {
|
||||
$feature{"nghttpx"} = !!$ENV{'NGHTTPX'};
|
||||
$feature{"nghttpx-h3"} = !!$nghttpx_h3;
|
||||
|
||||
#
|
||||
# strings that must exactly match the names used in server/disabled.c
|
||||
#
|
||||
$feature{"cookies"} = 1;
|
||||
# Use this as a proxy for any cryptographic authentication
|
||||
$feature{"crypto"} = $feature{"NTLM"} || $feature{"Kerberos"} || $feature{"SPNEGO"};
|
||||
$feature{"DoH"} = 1;
|
||||
$feature{"HTTP-auth"} = 1;
|
||||
$feature{"Mime"} = 1;
|
||||
$feature{"form-api"} = 1;
|
||||
$feature{"netrc"} = 1;
|
||||
$feature{"parsedate"} = 1;
|
||||
$feature{"proxy"} = 1;
|
||||
$feature{"shuffle-dns"} = 1;
|
||||
$feature{"typecheck"} = 1;
|
||||
$feature{"verbose-strings"} = 1;
|
||||
$feature{"wakeup"} = 1;
|
||||
$feature{"headers-api"} = 1;
|
||||
$feature{"xattr"} = 1;
|
||||
$feature{"large-time"} = 1;
|
||||
$feature{"large-size"} = 1;
|
||||
$feature{"sha512-256"} = 1;
|
||||
$feature{"--libcurl"} = 1;
|
||||
$feature{"local-http"} = servers::localhttp();
|
||||
$feature{"codeset-utf8"} = lc(langinfo(CODESET())) eq "utf-8";
|
||||
|
||||
@ -902,10 +887,6 @@ sub checksystemfeatures {
|
||||
# Disable memory tracking when using threaded resolver
|
||||
$feature{"TrackMemory"} = $feature{"TrackMemory"} && !$feature{"threaded-resolver"};
|
||||
|
||||
# toggle off the features that were disabled in the build
|
||||
for my $d(@disabled) {
|
||||
$feature{$d} = 0;
|
||||
}
|
||||
}
|
||||
|
||||
#######################################################################
|
||||
|
||||
3
tests/server/.gitignore
vendored
3
tests/server/.gitignore
vendored
@ -4,8 +4,7 @@
|
||||
|
||||
server_bundle.c
|
||||
servers
|
||||
|
||||
disabled
|
||||
buildinfo
|
||||
mqttd
|
||||
resolve
|
||||
rtspd
|
||||
|
||||
@ -22,7 +22,7 @@
|
||||
#
|
||||
###########################################################################
|
||||
|
||||
SERVERPROGS = resolve rtspd sockfilt sws tftpd socksd disabled mqttd dnsd
|
||||
SERVERPROGS = resolve rtspd sockfilt sws tftpd socksd buildinfo mqttd dnsd
|
||||
|
||||
MEMDEBUG = \
|
||||
../../lib/memdebug.c \
|
||||
@ -123,4 +123,4 @@ dnsd_SOURCES = $(MEMDEBUG) $(CURLX_SRCS) $(CURLX_HDRS) $(UTIL) \
|
||||
dnsd_LDADD = @CURL_NETWORK_AND_TIME_LIBS@
|
||||
dnsd_CFLAGS = $(AM_CFLAGS)
|
||||
|
||||
disabled_SOURCES = disabled.c
|
||||
buildinfo_SOURCES = buildinfo.c
|
||||
|
||||
@ -38,87 +38,195 @@
|
||||
#include <stdio.h>
|
||||
|
||||
static const char *disabled[]={
|
||||
"bindlocal: "
|
||||
#ifdef CURL_DISABLE_BINDLOCAL
|
||||
"bindlocal",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
|
||||
"cookies: "
|
||||
#ifdef CURL_DISABLE_COOKIES
|
||||
"cookies",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
|
||||
"basic-auth: "
|
||||
#ifdef CURL_DISABLE_BASIC_AUTH
|
||||
"basic-auth",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"bearer-auth: "
|
||||
#ifdef CURL_DISABLE_BEARER_AUTH
|
||||
"bearer-auth",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"digest-auth: "
|
||||
#ifdef CURL_DISABLE_DIGEST_AUTH
|
||||
"digest-auth",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"negotiate-auth: "
|
||||
#ifdef CURL_DISABLE_NEGOTIATE_AUTH
|
||||
"negotiate-auth",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"aws: "
|
||||
#ifdef CURL_DISABLE_AWS
|
||||
"aws",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"DoH: "
|
||||
#ifdef CURL_DISABLE_DOH
|
||||
"DoH",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"HTTP-auth: "
|
||||
#ifdef CURL_DISABLE_HTTP_AUTH
|
||||
"HTTP-auth",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"Mime: "
|
||||
#ifdef CURL_DISABLE_MIME
|
||||
"Mime",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
|
||||
"netrc: "
|
||||
#ifdef CURL_DISABLE_NETRC
|
||||
"netrc",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"parsedate: "
|
||||
#ifdef CURL_DISABLE_PARSEDATE
|
||||
"parsedate",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"proxy: "
|
||||
#ifdef CURL_DISABLE_PROXY
|
||||
"proxy",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"shuffle-dns: "
|
||||
#ifdef CURL_DISABLE_SHUFFLE_DNS
|
||||
"shuffle-dns",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"typecheck: "
|
||||
#ifdef CURL_DISABLE_TYPECHECK
|
||||
"typecheck",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"verbose-strings: "
|
||||
#ifdef CURL_DISABLE_VERBOSE_STRINGS
|
||||
"verbose-strings",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"wakeup: "
|
||||
#ifndef ENABLE_WAKEUP
|
||||
"wakeup",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"headers-api: "
|
||||
#ifdef CURL_DISABLE_HEADERS_API
|
||||
"headers-api",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"xattr: "
|
||||
#ifndef USE_XATTR
|
||||
"xattr",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"form-api: "
|
||||
#ifdef CURL_DISABLE_FORM_API
|
||||
"form-api",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"large-time: "
|
||||
#if (SIZEOF_TIME_T < 5)
|
||||
"large-time",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"large-size: "
|
||||
#if (SIZEOF_SIZE_T < 5)
|
||||
"large-size",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"sha512-256: "
|
||||
#ifndef CURL_HAVE_SHA512_256
|
||||
"sha512-256",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
#ifdef _WIN32
|
||||
#if defined(CURL_WINDOWS_UWP) || \
|
||||
defined(CURL_DISABLE_CA_SEARCH) || defined(CURL_CA_SEARCH_SAFE)
|
||||
"win32-ca-searchpath",
|
||||
#endif
|
||||
#ifndef CURL_CA_SEARCH_SAFE
|
||||
"win32-ca-search-safe",
|
||||
,
|
||||
|
||||
"win32-ca-searchpath: "
|
||||
#if !defined(_WIN32) || \
|
||||
(defined(CURL_WINDOWS_UWP) || \
|
||||
defined(CURL_DISABLE_CA_SEARCH) || defined(CURL_CA_SEARCH_SAFE))
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
"win32-ca-search-safe: "
|
||||
#if !defined(_WIN32) || !defined(CURL_CA_SEARCH_SAFE)
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
|
||||
"--libcurl: "
|
||||
#ifdef CURL_DISABLE_LIBCURL_OPTION
|
||||
"--libcurl",
|
||||
"OFF"
|
||||
#else
|
||||
"ON"
|
||||
#endif
|
||||
,
|
||||
NULL
|
||||
};
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user