From c8065499adc3bfdd97d3c51e44465865f9417efb Mon Sep 17 00:00:00 2001 From: Stefan Knoblich Date: Sat, 19 Feb 2011 23:35:41 +0100 Subject: [PATCH] [FreeTDM] Add --with-pkgconfigdir option to FreeTDM. Default behaviour is unchanged. Packagers should use this option to install freetdm.pc into the system's main pkg-config directory (e.g. /usr/lib/pkgconfig). Signed-off-by: Stefan Knoblich Tested-by: Stefan Knoblich --- libs/freetdm/Makefile.am | 2 +- libs/freetdm/configure.ac | 12 ++++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/libs/freetdm/Makefile.am b/libs/freetdm/Makefile.am index b3353f32de..63e04b6d0b 100644 --- a/libs/freetdm/Makefile.am +++ b/libs/freetdm/Makefile.am @@ -62,7 +62,7 @@ LINK = $(LIBTOOL) --mode=link --tag=CC $(CC) $(FTDM_CFLAGS) $(LDFLAGS) -o $ # EXTRA_DIST = freetdm.pc.in -pkgconfigdir = $(libdir)/pkgconfig +pkgconfigdir = @pkgconfigdir@ pkgconfig_DATA = freetdm.pc diff --git a/libs/freetdm/configure.ac b/libs/freetdm/configure.ac index 1f4fc9c6ac..29661c1cdf 100644 --- a/libs/freetdm/configure.ac +++ b/libs/freetdm/configure.ac @@ -65,6 +65,18 @@ AC_ARG_WITH([modinstdir], ) AC_SUBST([modinstdir]) +# freetdm.pc pkgconfig file +AC_ARG_WITH([pkgconfigdir], + [AS_HELP_STRING([--with-pkgconfigdir=DIR], [Installation directory for pkgconfig file (default: ${libdir}/pkgconfig)])], + [case "${withval}" in + yes|no) AC_MSG_ERROR([Invalid value ${withval} for option --with-pkgconfigdir]) ;; + *) pkgconfigdir="${withval}" ;; + esac + ], + [pkgconfigdir="${libdir}/pkgconfig"] +) +AC_SUBST([pkgconfigdir]) + AC_ARG_ENABLE([enable_64], [AS_HELP_STRING([--enable-64], [Enable 64bit compilation])], [enable_64="${enableval}"],