[meta-oe,v2,1/3] collectd: enable/disable libpq explicitly

Submitted by jackie huang on April 8, 2014, 9:07 a.m. | Patch ID: 70255


Message ID 50282b60ac02b6ac13d5d6ffdcdb22c7422a9555.1396947706.git.jackie.huang@windriver.com
State Accepted, archived
Headers show

Commit Message

jackie huang April 8, 2014, 9:07 a.m.
From: Wenzong Fan <wenzong.fan@windriver.com>

If '--with-libpq' is not included in configure options, the configure
script will assume 'with-libpq=yes' and try to figure below variables
out with 'pg_config':

    with_libpq_includedir, with_libpq_libdir

This causes configure QA errors on some hosts that have 'pg_config'
installed (which from postgresql-devel):

* ERROR: This autoconf log indicates errors, it looked at host include
  and/or library paths while determining system capabilities.

Anyways the target package should not depend on any host headers/libs,
we should enable/disable the libpq support explicitly according to if
the postgresql feature was enabled.

Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
 .../recipes-extended/collectd/collectd_5.2.2.bb    |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/meta-oe/recipes-extended/collectd/collectd_5.2.2.bb b/meta-oe/recipes-extended/collectd/collectd_5.2.2.bb
index 25be1c4..4eed2b6 100644
--- a/meta-oe/recipes-extended/collectd/collectd_5.2.2.bb
+++ b/meta-oe/recipes-extended/collectd/collectd_5.2.2.bb
@@ -23,7 +23,8 @@  PACKAGECONFIG ??= ""
 PACKAGECONFIG[snmp] = "--enable-snmp,--disable-snmp --with-libnetsnmp=no,net-snmp"
 PACKAGECONFIG[libmemcached] = "--with-libmemcached,--without-libmemcached,libmemcached"
 PACKAGECONFIG[iptables] = "--enable-iptables,--disable-iptables,iptables"
-PACKAGECONFIG[postgresql] = "--enable-postgresql,--disable-postgresql,postgresql"
+PACKAGECONFIG[postgresql] = "--enable-postgresql --with-libpq=yes, \
+        --disable-postgresql --with-libpq=no,postgresql"
 PACKAGECONFIG[dbi] = "--enable-dbi,--disable-dbi,libdbi"
 PACKAGECONFIG[modbus] = "--enable-modbus,--disable-modbus,libmodbus"
 PACKAGECONFIG[libowcapi] = "--with-libowcapi,--without-libowcapi,owfs"