From acb0a6b71277f91a7fb4f3f7283185860fcd347e Mon Sep 17 00:00:00 2001 From: ian Date: Fri, 17 Nov 2006 19:20:34 +0000 Subject: [PATCH] Import JeoIP, Java access to GeoIP, ok kurt@ --- geo/jeoip/Makefile | 43 +++++++++++++++++++++++++++++++++++++++++++ geo/jeoip/distinfo | 4 ++++ geo/jeoip/pkg/DESCR | 13 +++++++++++++ geo/jeoip/pkg/PLIST | 5 +++++ 4 files changed, 65 insertions(+) create mode 100644 geo/jeoip/Makefile create mode 100644 geo/jeoip/distinfo create mode 100644 geo/jeoip/pkg/DESCR create mode 100644 geo/jeoip/pkg/PLIST diff --git a/geo/jeoip/Makefile b/geo/jeoip/Makefile new file mode 100644 index 00000000000..868a41216a8 --- /dev/null +++ b/geo/jeoip/Makefile @@ -0,0 +1,43 @@ +# $OpenBSD: Makefile,v 1.1.1.1 2006/11/17 19:20:34 ian Exp $ +COMMENT= "Java interface to GeoIP database" +DISTNAME= jeoip-0.5 +CATEGORIES= geo net +PKG_ARCH= * + +HOMEPAGE= http://www.darwinsys.com/freeware/jeoip.jsp + +MAINTAINER= Ian Darwin + +# BSD +PERMIT_PACKAGE_CDROM= Yes +PERMIT_PACKAGE_FTP= Yes +PERMIT_DISTFILES_CDROM=Yes +PERMIT_DISTFILES_FTP= Yes + +MASTER_SITES= http://www.darwinsys.com/freeware/ + +MODULES= java +MODJAVA_VER= 1.5+ +MODJAVA_JRERUN= Yes +BUILD_DEPENDS= :apache-ant->=1.6.1:devel/apache-ant:\ + :junit->=3.8.1:java/junit +RUN_DEPENDS= :GeoIP-*:net/GeoIP\ + :javaPathHelper-*:java/javaPathHelper +MAKE_ENV= JAVA_HOME=${JAVA_HOME} \ + CLASSPATH=${LOCALBASE}/share/java/classes/junit-3.8.1/junit.jar + +NO_REGRESS= Yes + +WRKDIST= ${WRKDIR}/jeoip + +INSTALLDIR= jeoip + +do-build: + @cd ${WRKBUILD} && ${SETENV} ${MAKE_ENV} ant jar docs + +do-install: + ${INSTALL_DATA_DIR} ${PREFIX}/share/java/${INSTALLDIR} + ${INSTALL_DATA} ${WRKDIST}/jeoip.jar ${PREFIX}/share/java/${INSTALLDIR} + ${INSTALL_SCRIPT} ${WRKDIST}/unix/jeoip ${PREFIX}/bin + +.include diff --git a/geo/jeoip/distinfo b/geo/jeoip/distinfo new file mode 100644 index 00000000000..4f3756ed2f6 --- /dev/null +++ b/geo/jeoip/distinfo @@ -0,0 +1,4 @@ +MD5 (jeoip-0.5.tar.gz) = a730da884d259aaddc75e2b87cfdf2ca +RMD160 (jeoip-0.5.tar.gz) = 8639ad21cbc1c5c36233683e0f8510c6ee425b59 +SHA1 (jeoip-0.5.tar.gz) = 13d1fd1b430aff3e5e793a7fbc6d757f9e079f61 +SIZE (jeoip-0.5.tar.gz) = 8855 diff --git a/geo/jeoip/pkg/DESCR b/geo/jeoip/pkg/DESCR new file mode 100644 index 00000000000..f6876f6f7d6 --- /dev/null +++ b/geo/jeoip/pkg/DESCR @@ -0,0 +1,13 @@ +JeoIP is a Java implementation of net/GeoIP, which looks up an IPV4 +address in a local file and returns the country that it is in. +The database is maintained, and the GeoIP code provided, by MaxMind, +who sells on subscription more detailed datatabases that identify the +sender down to particular regions within a country. +See http://www.maxmind.com/ + +JeoIP does not use any code from GeoIP but does use its data file. +JeoIP was written to make the database accessible from within +Java Servlet/JSP web sites without having either to run an +external program or to link with "native code". +There are functions that return the country name as well as +its two- and three-letter ISO-3166 country code. diff --git a/geo/jeoip/pkg/PLIST b/geo/jeoip/pkg/PLIST new file mode 100644 index 00000000000..d6ee8d639bb --- /dev/null +++ b/geo/jeoip/pkg/PLIST @@ -0,0 +1,5 @@ +@comment $OpenBSD: PLIST,v 1.1.1.1 2006/11/17 19:20:34 ian Exp $ +bin/jeoip +share/java/ +share/java/jeoip/ +share/java/jeoip/jeoip.jar