2006-05-02 10:02:50 +00:00
|
|
|
|
|
|
|
This is a fugly hack to make apr-1-config libdir-agnostic, by using
|
|
|
|
pkg-config to determine the libdir setting. pkg-config will
|
|
|
|
magically determine the appropriate libdir setting.
|
|
|
|
|
|
|
|
This allows apr-devel.i386 and apr-devel.x86_64 to be
|
|
|
|
installed in parallel.
|
|
|
|
|
|
|
|
--- apr-1.2.7/Makefile.in.pkgconf
|
|
|
|
+++ apr-1.2.7/Makefile.in
|
|
|
|
@@ -60,7 +60,7 @@
|
|
|
|
|
|
|
|
# Create apr-config script suitable for the install tree
|
|
|
|
apr-config.out: $(APR_CONFIG)
|
|
|
|
- sed 's,^\(location=\).*$$,\1installed,' < $(APR_CONFIG) > $@
|
|
|
|
+ sed 's,^\(location=\).*$$,\1installed,;s,^\(APR_.*_DIR\)=.*,\1="$${libdir}/build",' < $(APR_CONFIG) > $@
|
|
|
|
|
|
|
|
# Create apr_rules.mk suitable for the install tree
|
|
|
|
build/apr_rules.out: build/apr_rules.mk
|
2006-05-23 10:16:00 +00:00
|
|
|
--- apr-1.2.7/apr.pc.in.pkgconf
|
|
|
|
+++ apr-1.2.7/apr.pc.in
|
|
|
|
@@ -3,9 +3,10 @@
|
|
|
|
libdir=@libdir@
|
|
|
|
APR_MAJOR_VERSION=@APR_MAJOR_VERSION@
|
|
|
|
includedir=@includedir@
|
|
|
|
+CPPFLAGS=@EXTRA_CPPFLAGS@
|
|
|
|
|
|
|
|
Name: APR
|
|
|
|
Description: The Apache Portable Runtime library
|
|
|
|
Version: @APR_DOTTED_VERSION@
|
|
|
|
Libs: -L${libdir} -l@APR_LIBNAME@ @EXTRA_LIBS@
|
|
|
|
-Cflags: @EXTRA_CPPFLAGS@ @EXTRA_CFLAGS@ -I${includedir}
|
|
|
|
+Cflags: ${CPPFLAGS} @EXTRA_CFLAGS@ -I${includedir}
|
2006-05-02 10:02:50 +00:00
|
|
|
--- apr-1.2.7/apr-config.in.pkgconf
|
|
|
|
+++ apr-1.2.7/apr-config.in
|
2008-08-23 01:20:36 +00:00
|
|
|
@@ -24,16 +24,17 @@
|
2006-05-02 10:02:50 +00:00
|
|
|
prefix="@prefix@"
|
|
|
|
exec_prefix="@exec_prefix@"
|
|
|
|
bindir="@bindir@"
|
|
|
|
-libdir="@libdir@"
|
2008-08-23 01:20:36 +00:00
|
|
|
datarootdir="@datadir@"
|
2006-05-02 10:02:50 +00:00
|
|
|
datadir="@datadir@"
|
|
|
|
-installbuilddir="@installbuilddir@"
|
|
|
|
includedir="@includedir@"
|
|
|
|
|
|
|
|
+libdir=`pkg-config --variable=libdir apr-@APR_MAJOR_VERSION@`
|
2006-05-02 10:58:29 +00:00
|
|
|
+installbuilddir="${libdir}/apr-@APR_MAJOR_VERSION@/build"
|
2006-05-02 10:02:50 +00:00
|
|
|
+
|
|
|
|
CC="@CC@"
|
|
|
|
CPP="@CPP@"
|
|
|
|
SHELL="@SHELL@"
|
2006-05-23 10:16:00 +00:00
|
|
|
-CPPFLAGS="@EXTRA_CPPFLAGS@"
|
|
|
|
+CPPFLAGS=`pkg-config --variable=CPPFLAGS apr-@APR_MAJOR_VERSION@`
|
|
|
|
CFLAGS="@EXTRA_CFLAGS@"
|
|
|
|
LDFLAGS="@EXTRA_LDFLAGS@"
|
|
|
|
LIBS="@EXTRA_LIBS@"
|