unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#38247] [PATCH 0/3] Add libmaxminddb, python-maxminddb, python-geoip2.
@ 2019-11-17 18:45 Hartmut Goebel
  2019-11-17 18:47 ` [bug#38247] [PATCH 1/3] gnu: Add libmaxminddb Hartmut Goebel
       [not found] ` <handler.38247.B.157401636618744.ack@debbugs.gnu.org>
  0 siblings, 2 replies; 5+ messages in thread
From: Hartmut Goebel @ 2019-11-17 18:45 UTC (permalink / raw)
  To: 38247

I decided to puall the python packages into (gnu python geo), too, since
this already included (gnu python) and (gnu python xyz).

Hartmut Goebel (3):
  gnu: Add libmaxminddb.
  gnu: Add python-maxminddb.
  gnu: Add python-geoip2.

 gnu/packages/geo.scm | 78 ++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 78 insertions(+)

-- 
2.21.0

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [bug#38247] [PATCH 1/3] gnu: Add libmaxminddb.
  2019-11-17 18:45 [bug#38247] [PATCH 0/3] Add libmaxminddb, python-maxminddb, python-geoip2 Hartmut Goebel
@ 2019-11-17 18:47 ` Hartmut Goebel
  2019-11-17 18:47   ` [bug#38247] [PATCH 2/3] gnu: Add python-maxminddb Hartmut Goebel
  2019-11-17 18:47   ` [bug#38247] [PATCH 3/3] gnu: Add python-geoip2 Hartmut Goebel
       [not found] ` <handler.38247.B.157401636618744.ack@debbugs.gnu.org>
  1 sibling, 2 replies; 5+ messages in thread
From: Hartmut Goebel @ 2019-11-17 18:47 UTC (permalink / raw)
  To: 38247

* gnu/packages/geo.scm (libmaxminddb): New variable.
---
 gnu/packages/geo.scm | 31 +++++++++++++++++++++++++++++++
 1 file changed, 31 insertions(+)

diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm
index 477e9a460a..7be1ae5777 100644
--- a/gnu/packages/geo.scm
+++ b/gnu/packages/geo.scm
@@ -10,6 +10,7 @@
 ;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net>
 ;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2019 Wiktor Żelazny <wzelazny@vurv.cz>
+;;; Copyright © 2019 Hartmut Goebel <h.goebel@crazy-compilers.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1213,3 +1214,33 @@ supports loading GPX tracks, background imagery and OSM data from local
 sources as well as from online sources and allows to edit the OSM data (nodes,
 ways, and relations) and their metadata tags.")
     (license license:gpl2+)))
+
+(define-public libmaxminddb
+  (package
+    (name "libmaxminddb")
+    (version "1.4.2")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://github.com/maxmind/libmaxminddb"
+                           "/releases/download/" version "/"
+                           "/libmaxminddb-" version ".tar.gz"))
+       (sha256
+        (base32 "0mnimbaxnnarlw7g1rh8lpxsyf7xnmzwcczcc3lxw8xyf6ljln6x"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'set-cc-to-gcc
+           (lambda _
+             (setenv "CC" "gcc"))))))
+    (native-inputs
+     `(("perl" ,perl)))
+    (home-page "https://maxmind.github.io/libmaxminddb/")
+    (synopsis "C library for the MaxMind DB file format")
+    (description "The libmaxminddb library provides a C library for reading
+MaxMind DB files, including the GeoIP2 databases from MaxMind.  The MaxMind DB
+format is a custom, but open, binary format designed to facilitate fast
+lookups of IP addresses while allowing flexibility in the type of data
+associated with an address.")
+    (license license:asl2.0)))
-- 
2.21.0

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [bug#38247] [PATCH 2/3] gnu: Add python-maxminddb.
  2019-11-17 18:47 ` [bug#38247] [PATCH 1/3] gnu: Add libmaxminddb Hartmut Goebel
@ 2019-11-17 18:47   ` Hartmut Goebel
  2019-11-17 18:47   ` [bug#38247] [PATCH 3/3] gnu: Add python-geoip2 Hartmut Goebel
  1 sibling, 0 replies; 5+ messages in thread
From: Hartmut Goebel @ 2019-11-17 18:47 UTC (permalink / raw)
  To: 38247

* gnu/packages/geo.scm (python-maxminddb): New variable.
---
 gnu/packages/geo.scm | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm
index 7be1ae5777..26d270e4eb 100644
--- a/gnu/packages/geo.scm
+++ b/gnu/packages/geo.scm
@@ -1244,3 +1244,26 @@ format is a custom, but open, binary format designed to facilitate fast
 lookups of IP addresses while allowing flexibility in the type of data
 associated with an address.")
     (license license:asl2.0)))
+
+(define-public python-maxminddb
+  (package
+    (name "python-maxminddb")
+    (version "1.5.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "maxminddb" version))
+       (sha256
+        (base32
+         "0y9giw81k4wdmpryr4k42w50z292mf364a6vs1vxf83ksc9ig6j4"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:tests? #f)) ;; Tests require a copy of the maxmind database
+    (inputs
+     `(("libmaxminddb" ,libmaxminddb)))
+    (home-page "http://www.maxmind.com/")
+    (synopsis "Reader for the MaxMind DB format")
+    (description "MaxMind DB is a binary file format that stores data indexed
+by IP address subnets (IPv4 or IPv6).  This is a Python module for reading
+MaxMind DB files.")
+    (license license:asl2.0)))
-- 
2.21.0

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [bug#38247] [PATCH 3/3] gnu: Add python-geoip2.
  2019-11-17 18:47 ` [bug#38247] [PATCH 1/3] gnu: Add libmaxminddb Hartmut Goebel
  2019-11-17 18:47   ` [bug#38247] [PATCH 2/3] gnu: Add python-maxminddb Hartmut Goebel
@ 2019-11-17 18:47   ` Hartmut Goebel
  1 sibling, 0 replies; 5+ messages in thread
From: Hartmut Goebel @ 2019-11-17 18:47 UTC (permalink / raw)
  To: 38247

* gnu/packages/geo.scm (python-geoip2): New variable.
---
 gnu/packages/geo.scm | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm
index 26d270e4eb..f87225db95 100644
--- a/gnu/packages/geo.scm
+++ b/gnu/packages/geo.scm
@@ -65,6 +65,7 @@
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages protobuf)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages python-web)
   #:use-module (gnu packages python-xyz)
   #:use-module (gnu packages qt)
   #:use-module (gnu packages sqlite)
@@ -1267,3 +1268,26 @@ associated with an address.")
 by IP address subnets (IPv4 or IPv6).  This is a Python module for reading
 MaxMind DB files.")
     (license license:asl2.0)))
+
+(define-public python-geoip2
+  (package
+    (name "python-geoip2")
+    (version "2.9.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "geoip2" version))
+       (sha256
+        (base32
+         "1w7cay5q6zawjzivqbwz5cqx1qbdjw6kbriccb7l46p7b39fkzzp"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:tests? #f)) ;; Tests require a copy of the maxmind database
+    (inputs
+     `(("python-maxminddb" ,python-maxminddb)
+       ("python-requests" ,python-requests)))
+    (home-page "http://www.maxmind.com/")
+    (synopsis "MaxMind GeoIP2 API")
+    (description "Provides an API for the GeoIP2 web services and databases.
+The API also works with MaxMind’s free GeoLite2 databases.")
+    (license license:asl2.0)))
-- 
2.21.0

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* bug#38247: Acknowledgement ([PATCH 0/3] Add libmaxminddb, python-maxminddb, python-geoip2.)
       [not found] ` <handler.38247.B.157401636618744.ack@debbugs.gnu.org>
@ 2019-12-06 18:40   ` Hartmut Goebel
  0 siblings, 0 replies; 5+ messages in thread
From: Hartmut Goebel @ 2019-12-06 18:40 UTC (permalink / raw)
  To: 38247-close

Merged as 0a71e34e49c811c1d84565001226c84e70f325ef


-- 
Regards
Hartmut Goebel

| Hartmut Goebel          | h.goebel@crazy-compilers.com               |
| www.crazy-compilers.com | compilers which you thought are impossible |

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-12-06 18:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-17 18:45 [bug#38247] [PATCH 0/3] Add libmaxminddb, python-maxminddb, python-geoip2 Hartmut Goebel
2019-11-17 18:47 ` [bug#38247] [PATCH 1/3] gnu: Add libmaxminddb Hartmut Goebel
2019-11-17 18:47   ` [bug#38247] [PATCH 2/3] gnu: Add python-maxminddb Hartmut Goebel
2019-11-17 18:47   ` [bug#38247] [PATCH 3/3] gnu: Add python-geoip2 Hartmut Goebel
     [not found] ` <handler.38247.B.157401636618744.ack@debbugs.gnu.org>
2019-12-06 18:40   ` bug#38247: Acknowledgement ([PATCH 0/3] Add libmaxminddb, python-maxminddb, python-geoip2.) Hartmut Goebel

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).