From 3fefb191680e55294bc4d1f45f541b15c8df2ae0 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Thu, 13 Apr 2017 14:46:08 -0700 Subject: Update to GeoIP 1.6.10. That's the most recent version of the GeoIP legacy API. GeoIP 1.6.1, and later, are available from GitHub, but not from MaxMind's Web site. Change-Id: I67b1b5b47761beac2fc303e18e39d9accac86e3b Reviewed-on: https://code.wireshark.org/review/21081 Reviewed-by: Guy Harris --- macosx-setup.sh | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) (limited to 'macosx-setup.sh') diff --git a/macosx-setup.sh b/macosx-setup.sh index 5b3234e4c7..e3302fd3ef 100755 --- a/macosx-setup.sh +++ b/macosx-setup.sh @@ -138,12 +138,7 @@ PORTAUDIO_VERSION=pa_stable_v19_20111121 SNAPPY_VERSION=1.1.3 LZ4_VERSION=r131 SBC_VERSION=1.3 -# -# XXX - they appear to have an unversioned gzipped tarball for the -# current version; should we just download that, with some other -# way of specifying whether to download the GeoIP API? -# -GEOIP_VERSION=1.4.8 +GEOIP_VERSION=1.6.10 CARES_VERSION=1.12.0 @@ -1467,7 +1462,20 @@ uninstall_portaudio() { install_geoip() { if [ "$GEOIP_VERSION" -a ! -f geoip-$GEOIP_VERSION-done ] ; then echo "Downloading, building, and installing GeoIP API:" - [ -f GeoIP-$GEOIP_VERSION.tar.gz ] || curl -L -O http://geolite.maxmind.com/download/geoip/api/c/GeoIP-$GEOIP_VERSION.tar.gz || exit 1 + GEOIP_MAJOR_VERSION="`expr $GEOIP_VERSION : '\([0-9][0-9]*\).*'`" + GEOIP_MINOR_VERSION="`expr $GEOIP_VERSION : '[0-9][0-9]*\.\([0-9][0-9]*\).*'`" + GEOIP_DOTDOT_VERSION="`expr $GEOIP_VERSION : '[0-9][0-9]*\.[0-9][0-9]*\.\([0-9][0-9]*\).*'`" + if [[ $GEOIP_MAJOR_VERSION -gt 1 || + $GEOIP_MINOR_VERSION -gt 6 || + ($GEOIP_MINOR_VERSION -eq 6 && $GEOIP_DOTDOT_VERSION -ge 1) ]] + then + # + # Starting with GeoIP 1.6.1, the tarballs are on GitHub. + # + [ -f GeoIP-$GEOIP_VERSION.tar.gz ] || curl -L -O https://github.com/maxmind/geoip-api-c/releases/download/v$GEOIP_VERSION/GeoIP-$GEOIP_VERSION.tar.gz || exit 1 + else + [ -f GeoIP-$GEOIP_VERSION.tar.gz ] || curl -L -O http://geolite.maxmind.com/download/geoip/api/c/GeoIP-$GEOIP_VERSION.tar.gz || exit 1 + fi gzcat GeoIP-$GEOIP_VERSION.tar.gz | tar xf - || exit 1 cd GeoIP-$GEOIP_VERSION CFLAGS="$CFLAGS $VERSION_MIN_FLAGS $SDKFLAGS" CXXFLAGS="$CXXFLAGS $VERSION_MIN_FLAGS $SDKFLAGS" LDFLAGS="$LDFLAGS $VERSION_MIN_FLAGS $SDKFLAGS" ./configure || exit 1 -- cgit v1.2.1