57f6d9d
From 2a4754a3a7cf60ecc36d83cbe50b8c337cb87632 Mon Sep 17 00:00:00 2001
57f6d9d
From: Kamil Dudka <kdudka@redhat.com>
57f6d9d
Date: Fri, 12 Apr 2013 12:04:05 +0200
57f6d9d
Subject: [PATCH] prevent multilib conflicts on the curl-config script
57f6d9d
57f6d9d
---
8c661bb
 curl-config.in     | 23 +++++------------------
8c661bb
 docs/curl-config.1 |  4 +++-
8c661bb
 libcurl.pc.in      |  1 +
8c661bb
 3 files changed, 9 insertions(+), 19 deletions(-)
972da71
014599c
diff --git a/curl-config.in b/curl-config.in
eaba136
index 150004d..95d0759 100644
014599c
--- a/curl-config.in
014599c
+++ b/curl-config.in
a4ed273
@@ -78,7 +78,7 @@ while test $# -gt 0; do
57f6d9d
         ;;
Ivana Varekova a88dcef
 
Ivana Varekova a88dcef
     --cc)
57f6d9d
-        echo "@CC@"
57f6d9d
+        echo "gcc"
57f6d9d
         ;;
Ivana Varekova a88dcef
 
Ivana Varekova a88dcef
     --prefix)
a4ed273
@@ -157,32 +157,19 @@ while test $# -gt 0; do
57f6d9d
         ;;
Ivana Varekova a88dcef
 
Ivana Varekova a88dcef
     --libs)
57f6d9d
-        if test "X@libdir@" != "X/usr/lib" -a "X@libdir@" != "X/usr/lib64"; then
57f6d9d
-           CURLLIBDIR="-L@libdir@ "
57f6d9d
-        else
57f6d9d
-           CURLLIBDIR=""
57f6d9d
-        fi
e7a12a6
-        if test "X@ENABLE_SHARED@" = "Xno"; then
57f6d9d
-          echo ${CURLLIBDIR}-lcurl @LIBCURL_LIBS@
57f6d9d
-        else
57f6d9d
-          echo ${CURLLIBDIR}-lcurl
57f6d9d
-        fi
88ed685
+        echo -lcurl
57f6d9d
         ;;
93c5556
     --ssl-backends)
93c5556
         echo "@SSL_BACKENDS@"
93c5556
         ;;
Ivana Varekova a88dcef
 
eaba136
     --static-libs)
c12a28f
-        if test "X@ENABLE_STATIC@" != "Xno" ; then
1322e86
-          echo "@libdir@/libcurl.@libext@" @LDFLAGS@ @LIBCURL_LIBS@
c12a28f
-        else
c12a28f
-          echo "curl was built with static libraries disabled" >&2
c12a28f
-          exit 1
c12a28f
-        fi
8c661bb
+        echo "curl was built with static libraries disabled" >&2
8c661bb
+        exit 1
57f6d9d
         ;;
eaba136
 
6d0277e
     --configure)
57f6d9d
-        echo @CONFIGURE_OPTIONS@
57f6d9d
+        pkg-config libcurl --variable=configure_options | sed 's/^"//;s/"$//'
57f6d9d
         ;;
c3d8d1c
 
c3d8d1c
     *)
eaba136
diff --git a/docs/curl-config.1 b/docs/curl-config.1
57f6d9d
index 14a9d2b..ffcc004 100644
eaba136
--- a/docs/curl-config.1
eaba136
+++ b/docs/curl-config.1
a4ed273
@@ -72,7 +72,9 @@ no, one or several names. If more than one name, they will appear
93c5556
 comma-separated. (Added in 7.58.0)
eaba136
 .IP "--static-libs"
eaba136
 Shows the complete set of libs and other linker options you will need in order
eaba136
-to link your application with libcurl statically. (Added in 7.17.1)
eaba136
+to link your application with libcurl statically. Note that Fedora/RHEL libcurl
eaba136
+packages do not provide any static libraries, thus cannot be linked statically.
eaba136
+(Added in 7.17.1)
eaba136
 .IP "--version"
eaba136
 Outputs version information about the installed libcurl.
eaba136
 .IP "--vernum"
eaba136
diff --git a/libcurl.pc.in b/libcurl.pc.in
eaba136
index 2ba9c39..f8f8b00 100644
c3d8d1c
--- a/libcurl.pc.in
c3d8d1c
+++ b/libcurl.pc.in
a4ed273
@@ -31,6 +31,7 @@ libdir=@libdir@
c3d8d1c
 includedir=@includedir@
c3d8d1c
 supported_protocols="@SUPPORT_PROTOCOLS@"
c3d8d1c
 supported_features="@SUPPORT_FEATURES@"
c3d8d1c
+configure_options=@CONFIGURE_OPTIONS@
c3d8d1c
 
c3d8d1c
 Name: libcurl
c829072
 URL: https://curl.se/
127274b
-- 
c829072
2.26.2
127274b