Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 1 | From d3ee8c8df5808b63e86f40831f2ba62cbb33d291 Mon Sep 17 00:00:00 2001 |
| 2 | From: Changqing Li <changqing.li@windriver.com> |
| 3 | Date: Wed, 8 Aug 2018 09:18:27 +0800 |
| 4 | Subject: [PATCH] postgresql: Use pkg-config for libxml2 detection. |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 5 | |
| 6 | Upstream-Status: Inappropriate [configuration] |
| 7 | |
| 8 | xml2-config does not work. Use pkgconfig to set CPPFLAGS and LIBS. |
| 9 | |
| 10 | Signed-off-by: Philip Balister <philip@balister.org> |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 11 | |
Brad Bishop | 2f97392 | 2019-11-11 07:58:48 -0500 | [diff] [blame] | 12 | update to version 10.4 |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 13 | Signed-off-by: Changqing Li <changqing.li@windriver.com> |
Brad Bishop | 2f97392 | 2019-11-11 07:58:48 -0500 | [diff] [blame] | 14 | |
| 15 | Update for version 12.0 |
| 16 | Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 17 | --- |
Brad Bishop | 2f97392 | 2019-11-11 07:58:48 -0500 | [diff] [blame] | 18 | configure.in | 16 ++-------------- |
| 19 | 1 file changed, 2 insertions(+), 14 deletions(-) |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 20 | |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 21 | diff --git a/configure.in b/configure.in |
Brad Bishop | 2f97392 | 2019-11-11 07:58:48 -0500 | [diff] [blame] | 22 | index 6942f81..7fd3e78 100644 |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 23 | --- a/configure.in |
| 24 | +++ b/configure.in |
Brad Bishop | 2f97392 | 2019-11-11 07:58:48 -0500 | [diff] [blame] | 25 | @@ -923,20 +923,8 @@ PGAC_ARG_BOOL(with, libxml, no, [build with XML support], |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 26 | [AC_DEFINE([USE_LIBXML], 1, [Define to 1 to build with XML support. (--with-libxml)])]) |
| 27 | |
| 28 | if test "$with_libxml" = yes ; then |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 29 | - PGAC_PATH_PROGS(XML2_CONFIG, xml2-config) |
Brad Bishop | 2f97392 | 2019-11-11 07:58:48 -0500 | [diff] [blame] | 30 | - AC_ARG_VAR(XML2_CONFIG, [path to xml2-config utility])dnl |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 31 | - if test -n "$XML2_CONFIG"; then |
| 32 | - for pgac_option in `$XML2_CONFIG --cflags`; do |
| 33 | - case $pgac_option in |
| 34 | - -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";; |
| 35 | - esac |
| 36 | - done |
| 37 | - for pgac_option in `$XML2_CONFIG --libs`; do |
| 38 | - case $pgac_option in |
| 39 | - -L*) LDFLAGS="$LDFLAGS $pgac_option";; |
| 40 | - esac |
| 41 | - done |
| 42 | - fi |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 43 | + CPPFLAGS="$CPPFLAGS `pkg-config --short-errors --print-errors --cflags "libxml-2.0" 2>&1`" |
| 44 | + LIBS="`pkg-config --short-errors --print-errors --libs "libxml-2.0" 2>&1` $LIBS" |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 45 | fi |
| 46 | |
| 47 | AC_SUBST(with_libxml) |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 48 | -- |
| 49 | 2.7.4 |
| 50 | |