From c9e442aeccd87748d9e87bf357bd8337e699a9b0 Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Mon, 8 Jul 2013 15:17:37 +0200 Subject: configure: Call a function from libgeoip in check_libgeoip() In order to cause the linker to get called and thus the check for the presence of the library (not just the headers) to be performed, call GeoIP_new(). Also pass the proper linker flag to $CC. Signed-off-by: Tobias Klauser --- configure | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index 6f5b54b..2c9142d 100755 --- a/configure +++ b/configure @@ -184,10 +184,12 @@ void main(void) GEOIP_ASNUM_EDITION, GEOIP_ASNUM_EDITION_V6, }; + + geoip = GeoIP_new(0); } EOF - $CC -o $TMPDIR/geoiptest $TMPDIR/geoiptest.c >> $TMPDIR/config.log 2>&1 + $CC -o $TMPDIR/geoiptest $TMPDIR/geoiptest.c -lGeoIP >> $TMPDIR/config.log 2>&1 if [ ! -x $TMPDIR/geoiptest ] ; then echo "[NO]" MISSING_DEFS=1 -- cgit v1.2.3-54-g00ecf