1 # Buildsheet autogenerated by ravenadm tool -- Do not edit.
5 KEYWORDS= net geography
7 SDESC[std]= Legacy API library for geolocation queries
8 HOMEPAGE= https://dev.maxmind.com/geoip/legacy/
12 SITES[main]= GITHUB/maxmind:geoip-api-c:v1.6.12
13 DISTFILE[1]= generated:main
21 OPTIONS_AVAILABLE= none
22 OPTIONS_STANDARD= none
26 USES= autoreconf libtool
30 INSTALL_TARGET= install-strip
32 SUB_FILES= messages-tools.ucl
36 ${MKDIR} ${STAGEDIR}${PREFIX}/share/GeoIP
37 ${INSTALL_SCRIPT} ${WRKDIR}/geoipupdate.sh ${STAGEDIR}${PREFIX}/bin
39 [FILE:659:descriptions/desc.primary]
40 GeoIP is a C library that enables the user to find the country that any
41 IP address or hostname originates from. It uses a file based database
42 that is accurate as of March 2002. This database simply contains IP blocks
43 as keys, and countries as values. This database should be more complete and
44 accurate than using reverse DNS lookups.
46 This module can be used to automatically select the geographically closest
47 mirror, to analyze your web server logs to determine the countries of your
48 visitors, for credit card fraud detection, and for software export controls.
50 This port includes a helper script, geoipupdate.sh, to help you keep the
54 [FILE:42:descriptions/desc.tools]
55 This package contains GeoIP lookup tools.
59 99b119f8e21e94f1dfd6d49fbeed29a70df1544896e76cd456f25e397b07d476 160826 maxmind-geoip-api-c-1.6.12.tar.gz
62 [FILE:57:manifests/plist.primary]
64 libGeoIP.so.%%SOMAJOR%%
65 libGeoIP.so.%%SOVERSION%%
68 [FILE:84:manifests/plist.dev]
75 lib/pkgconfig/geoip.pc
78 [FILE:65:manifests/plist.tools]
86 [FILE:47:manifests/plist.man]
92 [FILE:593:patches/patch-man__Makefile.am]
93 --- man/Makefile.am.orig 2015-04-30 04:26:22 UTC
96 -man_MANS = geoiplookup6.1 geoiplookup.1
97 +NOINST_man_MANS = geoiplookup6.1 geoiplookup.1
99 EXTRA_DIST = geoiplookup6.1.in geoiplookup.1.in
101 @@ -20,7 +20,7 @@ CLEANFILES = geoiplookup6.1 geoiplookup.
102 LOOKUP_MAN = $(mandir)/man1/geoiplookup.1
103 LOOKUP6_MAN = $(mandir)/man1/geoiplookup6.1
106 +install-data-hook: $(NOINST_man_MANS)
107 cat geoiplookup.1 | sed s,DATADIR,$(pkgdatadir), > $(DESTDIR)$(LOOKUP_MAN)
108 cat geoiplookup6.1 | sed s,DATADIR,$(pkgdatadir), > $(DESTDIR)$(LOOKUP6_MAN)
112 [FILE:1701:files/geoipupdate.sh.in]
115 # You can set the following environment variables:
117 # GEOIP_DB_SERVER: The default download server is geolite.maxmind.com
118 # GEOIP_FETCH_CITY: If set (to anything), download the GeoLite City DB
119 # GEOIP_FETCH_ASN: If set, download the GeoIP ASN DB
121 GEOIP_DB_SERVER=${GEOIP_DB_SERVER:=geolite.maxmind.com}
122 GEOIP_FETCH_CITY=${GEOIP_FETCH_CITY:=}
123 GEOIP_FETCH_ASN=${GEOIP_FETCH_ASN:=}
126 echo Fetching GeoIP.dat and GeoIPv6.dat...
130 # $2 output file name
134 TEMPDIR="$(mktemp -d '%%DATADIR%%/GeoIPupdate.XXXXXX')"
135 trap 'rc=$? ; set +e ; rm -rf "'"$TEMPDIR"'" ; exit $rc' 0
136 if fetch -o "$TEMPDIR/$out.gz" "$url"; then
137 gunzip "$TEMPDIR/$out.gz"
138 chmod 444 "$TEMPDIR/$out"
139 if ! mv -f "$TEMPDIR/$out" "%%DATADIR%%"/"$2"; then
140 echo "Unable to replace %%DATADIR%%/$2"
144 echo "$2 download failed"
152 _fetch "http://${GEOIP_DB_SERVER}/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz" GeoIP.dat
153 _fetch "http://${GEOIP_DB_SERVER}/download/geoip/database/GeoIPv6.dat.gz" GeoIPv6.dat
155 if [ -n "$GEOIP_FETCH_CITY" ]; then
156 _fetch "http://${GEOIP_DB_SERVER}/download/geoip/database/GeoLiteCity.dat.gz" GeoLiteCity.dat
157 _fetch "http://${GEOIP_DB_SERVER}/download/geoip/database/GeoLiteCityv6-beta/GeoLiteCityv6.dat.gz" GeoLiteCityv6.dat
159 if [ -n "$GEOIP_FETCH_ASN" ]; then
160 _fetch "http://${GEOIP_DB_SERVER}/download/geoip/database/asnum/GeoIPASNum.dat.gz" GeoIPASNum.dat
161 _fetch "http://${GEOIP_DB_SERVER}/download/geoip/database/asnum/GeoIPASNumv6.dat.gz" GeoIPASNumv6.dat
165 [FILE:175:files/messages-tools.ucl.in]
169 GeoIP does not ship with the actual data files. You must download
170 them yourself! Please run:
171 # %%PREFIX%%/bin/geoipupdate.sh