]> granicus.if.org Git - curl/commitdiff
added 'curl-config --vernum' for hardcore hex version output
authorDaniel Stenberg <daniel@haxx.se>
Mon, 28 May 2001 14:58:07 +0000 (14:58 +0000)
committerDaniel Stenberg <daniel@haxx.se>
Mon, 28 May 2001 14:58:07 +0000 (14:58 +0000)
configure.in
curl-config.in
docs/curl-config.1

index 13bc7e3f9a5a9c2b2185eee70ed0a6e2e20d94cf..1dfc4c5e41e70f700d14872477155d6a6c29c7ed 100644 (file)
@@ -7,6 +7,11 @@ AM_CONFIG_HEADER(config.h src/config.h)
 VERSION=`sed -ne 's/^#define LIBCURL_VERSION "\(.*\)"/\1/p' ${srcdir}/include/curl/curl.h`
 AM_INIT_AUTOMAKE(curl,$VERSION)
 
+dnl
+dnl we extract the numerical version for curl-config only
+VERSIONNUM=`sed -ne 's/^#define LIBCURL_VERSION_NUM 0x\(.*\)/\1/p' ${srcdir}/include/curl/curl.h`
+AC_SUBST(VERSIONNUM)
+
 dnl
 dnl Detect the canonical host and target build environment
 dnl
index d2d984212d0077f381ae59ec7c830bf5fe0e1b03..7de459318e7e715bc2bf920d4cd7a5eb89244c05 100644 (file)
@@ -62,6 +62,11 @@ while test $# -gt 0; do
        exit 0
        ;;
 
+    --vernum)
+       echo @VERSIONNUM@
+       exit 0
+       ;;
+
     --help)
        usage 0
        ;;
index c375379611d08ab6688d4ecb7392135b15a2fdb2..4993aedb775e12479aaf64d1e488ceea3f23e0b1 100644 (file)
@@ -2,7 +2,7 @@
 .\" nroff -man curl-config.1
 .\" Written by Daniel Stenberg
 .\"
-.TH curl-config 1 "18 March 2001" "Curl 7.7.2" "curl-config manual"
+.TH curl-config 1 "28 May 2001" "Curl 7.8" "curl-config manual"
 .SH NAME
 curl-config \- Get information about a libcurl installation
 .SH SYNOPSIS
@@ -30,6 +30,11 @@ in $prefix/lib and its header files are installed in $prefix/include and so
 on. The prefix is set with "configure --prefix".
 .IP "--version"
 Outputs version information about the installed libcurl.
+.IP "--vernum"
+Outputs version information about the installed libcurl, in numerical mode.
+This outputs the version number, in hexadecimal, with 8 bits for each part;
+major, minor, patch. So that libcurl 7.7.4 would appear as 070704 and libcurl
+12.13.14 would appear as 0c0d0e...
 .SH "EXAMPLES"
 What is the path to the curl header files?