]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
3360. [bug] isc-config.sh did not honour includedir and libdir
authorMark Andrews <marka@isc.org>
Tue, 30 Apr 2013 06:32:03 +0000 (16:32 +1000)
committerMark Andrews <marka@isc.org>
Tue, 30 Apr 2013 06:35:14 +0000 (16:35 +1000)
                        when set via configure. [RT #33345]

CHANGES
isc-config.sh.in

diff --git a/CHANGES b/CHANGES
index 8b2c5be86d5726f23489dbba5f2f8c175f653f31..bdc2f5ca287617bc218b0304300aa1965190730d 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,8 @@
        --- 9.6-ESV-R9rc2 released ---
 
+3360.  [bug]           isc-config.sh did not honour includedir and libdir
+                       when set via configure. [RT #33345]
+
 3559.  [func]          Check that both forms of Sender Policy Framework
                        records exist or do not exist. [RT #33355]
 
index 26b7d64dd176fcc77f9efa94faf706c897a8b789..ba076f10e4572b1e519917115e185e214e4ccbe9 100644 (file)
@@ -20,6 +20,8 @@
 prefix=@prefix@
 exec_prefix=@exec_prefix@
 exec_prefix_set=
+includedir=@includedir@
+libdir=@libdir@
 
 usage()
 {
@@ -57,6 +59,7 @@ while test $# -gt 0; do
                prefix=$optarg
                if test "x$exec_prefix_set" = x ; then
                        exec_prefix=$prefix
+                       exec_prefix_set=true
                fi
                ;;
        --prefix)
@@ -64,6 +67,7 @@ while test $# -gt 0; do
                ;;
        --exec-prefix=*)
                exec_prefix=$optarg
+               exec_prefix_set=true
                ;;
        --exec-prefix)
                echo_exec_prefix=true
@@ -115,14 +119,22 @@ if test x"$echo_exec_prefix" = x"true" ; then
        echo $exec_prefix
 fi
 if test x"$echo_cflags" = x"true"; then
-       includes="-I${exec_prefix}/include"
+       if test x"${exec_prefix_set}" = x"true"; then
+               includes="-I${exec_prefix}/include"
+       else
+               includes="-I${includedir}"
+       fi
        if test x"$libisc" = x"true"; then
                includes="$includes @ALWAYS_DEFINES@ @STD_CINCLUDES@ @STD_CDEFINES@ @CCOPT@"
        fi
        echo $includes
 fi
 if test x"$echo_libs" = x"true"; then
-       libs=-L${exec_prefix}/lib
+       if test x"${exec_prefix_set}" = x"true"; then
+               includes="-L${exec_prefix}/lib"
+       else
+               libs="-L${libdir}"
+       fi
        if test x"$liblwres" = x"true" ; then
                libs="$libs -llwres"
        fi