summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGES6
-rw-r--r--RELEASE-NOTES4
-rw-r--r--configure.ac72
-rw-r--r--curl-config.in68
-rw-r--r--libcurl.pc.in2
5 files changed, 88 insertions, 64 deletions
diff --git a/CHANGES b/CHANGES
index 219c2057b..06e2c8b69 100644
--- a/CHANGES
+++ b/CHANGES
@@ -6,6 +6,12 @@
Changelog
+Daniel Stenberg (2 Sep 2008)
+- Keith Mok added supported_protocols and supported_features to the pkg-config
+ file for libcurl, and while doing that fix he unified with curl-config.in
+ how the supported protocols and features are extracted and used, so both those
+ tools should now always be synced.
+
Version 7.19.0 (1 September 2008)
Daniel Fandrich (29 Aug 2008)
diff --git a/RELEASE-NOTES b/RELEASE-NOTES
index d10871ce8..9da3290e6 100644
--- a/RELEASE-NOTES
+++ b/RELEASE-NOTES
@@ -9,7 +9,7 @@ Curl and libcurl 7.19.1
This release includes the following changes:
- o
+ o pkg-config can now show supported_protocols and supported_features
This release includes the following bugfixes:
@@ -26,6 +26,6 @@ Other curl-related news:
This release would not have looked like this without help, code, reports and
advice from friends like these:
-
+ Keith Mok, Yang Tse
Thanks! (and sorry if I forgot to mention someone)
diff --git a/configure.ac b/configure.ac
index 18ab1f61c..17f7c1c47 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2546,6 +2546,78 @@ LIBS=$ALL_LIBS dnl LIBS is a magic variable that's used for every link
AM_CONDITIONAL(CROSSCOMPILING, test x$cross_compiling = xyes)
+dnl
+dnl For keeping supported features and protocols also in pkg-config file
+dnl since it is more cross-compile frient than curl-config
+dnl
+
+if test "x$USE_SSLEAY" = "x1"; then
+ SUPPORT_FEATURES="$SUPPORT_FEATURES SSL"
+elif test -n "$SSL_ENABLED"; then
+ SUPPORT_FEATURES="$SUPPORT_FEATURES SSL"
+fi
+if test "@KRB4_ENABLED@" = "x1"; then
+ SUPPORT_FEATURES="$SUPPORT_FEATURES KRB4"
+fi
+if test "x$IPV6_ENABLED" = "x1"; then
+ SUPPORT_FEATURES="$SUPPORT_FEATURES IPv6"
+fi
+if test "x$HAVE_LIBZ" = "x1"; then
+ SUPPORT_FEATURES="$SUPPORT_FEATURES libz"
+fi
+if test "x$HAVE_ARES" = "x1"; then
+ SUPPORT_FEATURES="$SUPPORT_FEATURES AsynchDNS"
+fi
+if test "x$IDN_ENABLED" = "x1"; then
+ SUPPORT_FEATURES="$SUPPORT_FEATURES IDN"
+fi
+if test "x$USE_WINDOWS_SSPI" = "x1"; then
+ SUPPORT_FEATURES="$SUPPORT_FEATURES SSPI"
+fi
+if test "x$USE_SSLEAY" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1"; then
+ SUPPORT_FEATURES="$SUPPORT_FEATURES NTLM"
+fi
+
+AC_SUBST(SUPPORT_FEATURES)
+
+dnl For supported protocols in pkg-config file
+if test "x$CURL_DISABLE_HTTP" != "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS HTTP"
+ if test "x$SSL_ENABLED" = "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS HTTPS"
+ fi
+fi
+if test "x$CURL_DISABLE_FTP" != "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS FTP"
+ if test "x$SSL_ENABLED" = "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS FTPS"
+ fi
+fi
+if test "x$CURL_DISABLE_FILE" != "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS FILE"
+fi
+if test "x$CURL_DISABLE_TELNET" != "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS TELNET"
+fi
+if test "x$CURL_DISABLE_LDAP" != "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS LDAP"
+fi
+if test "x$CURL_DISABLE_LDAPS" != "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS LDAPS"
+fi
+if test "x$CURL_DISABLE_DICT" != "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS DICT"
+fi
+if test "x$CURL_DISABLE_TFTP" != "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS TFTP"
+fi
+if test "x$USE_LIBSSH2" = "x1"; then
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SCP"
+ SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SFTP"
+fi
+
+AC_SUBST(SUPPORT_PROTOCOLS)
+
AC_CONFIG_FILES([Makefile \
docs/Makefile \
docs/examples/Makefile \
diff --git a/curl-config.in b/curl-config.in
index 107fa2c59..375318037 100644
--- a/curl-config.in
+++ b/curl-config.in
@@ -80,71 +80,15 @@ while test $# -gt 0; do
;;
--feature|--features)
- if test "@USE_SSLEAY@" = "1"; then
- echo "SSL"
- NTLM=1 # OpenSSL implies NTLM
- elif test -n "@SSL_ENABLED@"; then
- echo "SSL"
- fi
- if test "@KRB4_ENABLED@" = "1"; then
- echo "KRB4"
- fi
- if test "@IPV6_ENABLED@" = "1"; then
- echo "IPv6"
- fi
- if test "@HAVE_LIBZ@" = "1"; then
- echo "libz"
- fi
- if test "@HAVE_ARES@" = "1"; then
- echo "AsynchDNS"
- fi
- if test "@IDN_ENABLED@" = "1"; then
- echo "IDN"
- fi
- if test "@USE_WINDOWS_SSPI@" = "1"; then
- echo "SSPI"
- NTLM=1
- fi
- if test "$NTLM" = "1"; then
- echo "NTLM"
- fi
+ for feature in @SUPPORT_FEATURES@; do
+ echo $feature;
+ done
;;
--protocols)
- if test "@CURL_DISABLE_HTTP@" != "1"; then
- echo "HTTP"
- if test "@SSL_ENABLED@" = "1"; then
- echo "HTTPS"
- fi
- fi
- if test "@CURL_DISABLE_FTP@" != "1"; then
- echo "FTP"
- if test "@SSL_ENABLED@" = "1"; then
- echo "FTPS"
- fi
- fi
- if test "@CURL_DISABLE_FILE@" != "1"; then
- echo "FILE"
- fi
- if test "@CURL_DISABLE_TELNET@" != "1"; then
- echo "TELNET"
- fi
- if test "@CURL_DISABLE_LDAP@" != "1"; then
- echo "LDAP"
- fi
- if test "@CURL_DISABLE_LDAPS@" != "1"; then
- echo "LDAPS"
- fi
- if test "@CURL_DISABLE_DICT@" != "1"; then
- echo "DICT"
- fi
- if test "@CURL_DISABLE_TFTP@" != "1"; then
- echo "TFTP"
- fi
- if test "@USE_LIBSSH2@" = "1"; then
- echo "SCP"
- echo "SFTP"
- fi
+ for protocol in @SUPPORT_PROTOCOLS@; do
+ echo $protocol;
+ done
;;
--version)
echo libcurl @VERSION@
diff --git a/libcurl.pc.in b/libcurl.pc.in
index 7e5ffabd2..eaf853781 100644
--- a/libcurl.pc.in
+++ b/libcurl.pc.in
@@ -28,6 +28,8 @@ prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@
+supported_protocols="@SUPPORT_PROTOCOLS@"
+supported_features="@SUPPORT_FEATURES@"
Name: libcurl
URL: http://curl.haxx.se/