aboutsummaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorHartmut Goebel <h.goebel@crazy-compilers.com>2019-11-17 17:11:28 +0100
committerHartmut Goebel <h.goebel@crazy-compilers.com>2019-12-06 19:38:56 +0100
commit53c9b39850a98585614ed9622f98213155306191 (patch)
tree6017c374c9ee21769a2bf2ab48f94c3e63a19afb /gnu
parenta7469d1602a90298f66565bf22d43130955457b5 (diff)
downloadpatches-53c9b39850a98585614ed9622f98213155306191.tar
patches-53c9b39850a98585614ed9622f98213155306191.tar.gz
gnu: Add libmaxminddb.
* gnu/packages/geo.scm (libmaxminddb): New variable.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/geo.scm31
1 files changed, 31 insertions, 0 deletions
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)))