diff options
Diffstat (limited to 'isc-config.sh.in')
-rw-r--r-- | isc-config.sh.in | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/isc-config.sh.in b/isc-config.sh.in index 26b7d64..10df275 100644 --- a/isc-config.sh.in +++ b/isc-config.sh.in @@ -1,6 +1,6 @@ #!/bin/sh # -# Copyright (C) 2004, 2007, 2012 Internet Systems Consortium, Inc. ("ISC") +# Copyright (C) 2004, 2007, 2012, 2013 Internet Systems Consortium, Inc. ("ISC") # Copyright (C) 2000, 2001, 2003 Internet Software Consortium. # # Permission to use, copy, modify, and/or distribute this software for any @@ -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 |