aboutsummaryrefslogtreecommitdiffstats
path: root/acinclude.m4
diff options
context:
space:
mode:
authorTatsuya Kinoshita <tats@debian.org>2021-02-15 10:27:30 +0000
committerTatsuya Kinoshita <tats@debian.org>2021-02-15 10:27:30 +0000
commite29447dbcd90619b44fda7dbd9b8845b32569774 (patch)
tree2f51371732f6fbbfd79f2ef125876ce96fc119dd /acinclude.m4
parentUpdate ChangeLog (diff)
downloadw3m-e29447dbcd90619b44fda7dbd9b8845b32569774.tar.gz
w3m-e29447dbcd90619b44fda7dbd9b8845b32569774.zip
Accept configure --with-cafile without filename
Diffstat (limited to 'acinclude.m4')
-rw-r--r--acinclude.m429
1 files changed, 16 insertions, 13 deletions
diff --git a/acinclude.m4 b/acinclude.m4
index c94b1e1..33e37ea 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -513,20 +513,23 @@ fi
AC_SUBST(DEF_CAFILE)
w3m_cafile=""
if test x"$enable_sslverify" = xyes; then
- AC_MSG_CHECKING(for CA bundle location)
+ AC_MSG_CHECKING(for CA file location)
AC_ARG_WITH(cafile,
- [ --with-cafile=CAFILE CA file to verify SSL certificate],
- [w3m_cafile="$with_cafile"],[
- for f in /etc/ssl/certs/ca-certificates.crt \
- /etc/pki/tls/certs/ca-bundle.crt \
- /etc/ssl/ca-bundle.pem \
- /usr/ssl/certs/ca-bundle.crt \
- /usr/local/share/certs/ca-root-nss.crt \
- /etc/ssl/cert.pem \
- /etc/certs/ca-certificates.crt; do
- if test -f "$f" -a -r "$f"; then w3m_cafile="$f"; break; fi
- done
- ])
+ [ --with-cafile[[=CAFILE]] CA file to verify SSL certificate
+ default: autodetected],,[with_cafile=yes])
+ if test x"$with_cafile" = xyes; then
+ for f in /etc/ssl/certs/ca-certificates.crt \
+ /etc/pki/tls/certs/ca-bundle.crt \
+ /etc/ssl/ca-bundle.pem \
+ /usr/ssl/certs/ca-bundle.crt \
+ /usr/local/share/certs/ca-root-nss.crt \
+ /etc/ssl/cert.pem \
+ /etc/certs/ca-certificates.crt; do
+ if test -f "$f" -a -r "$f"; then w3m_cafile="$f"; break; fi
+ done
+ elif test x"$with_cafile" != xno; then
+ w3m_cafile="$with_cafile"
+ fi
AC_MSG_RESULT($w3m_cafile)
fi
AC_DEFINE_UNQUOTED(DEF_CAFILE, "$w3m_cafile")