Gentoo Archives: gentoo-commits

From: Thomas Deutschmann <whissi@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: www-apache/mod_maxminddb/, www-apache/mod_maxminddb/files/
Date: Fri, 26 Jun 2020 23:00:45
Message-Id: 1593212382.1df35586c28545e4f03a2f7153f8e81201711c8f.whissi@gentoo
1 commit: 1df35586c28545e4f03a2f7153f8e81201711c8f
2 Author: Tomáš Mózes <hydrapolic <AT> gmail <DOT> com>
3 AuthorDate: Thu Apr 30 21:32:18 2020 +0000
4 Commit: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
5 CommitDate: Fri Jun 26 22:59:42 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1df35586
7
8 www-apache/mod_maxminddb: add package
9
10 Apache module that allows to interact with maxminddb (geoip2).
11
12 Closes: https://bugs.gentoo.org/578062
13 Signed-off-by: Tomáš Mózes <hydrapolic <AT> gmail.com>
14 Closes: https://github.com/gentoo/gentoo/pull/15584
15 Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>
16
17 www-apache/mod_maxminddb/Manifest | 1 +
18 .../mod_maxminddb/files/70_mod_maxminddb.conf | 3 ++
19 www-apache/mod_maxminddb/metadata.xml | 15 ++++++++
20 .../mod_maxminddb/mod_maxminddb-1.2.0.ebuild | 40 ++++++++++++++++++++++
21 4 files changed, 59 insertions(+)
22
23 diff --git a/www-apache/mod_maxminddb/Manifest b/www-apache/mod_maxminddb/Manifest
24 new file mode 100644
25 index 00000000000..1fe9bf451f6
26 --- /dev/null
27 +++ b/www-apache/mod_maxminddb/Manifest
28 @@ -0,0 +1 @@
29 +DIST mod_maxminddb-1.2.0.tar.gz 101465 BLAKE2B a0f9673560851726e7e85b3c6a5ef3e9004854e79a72bb14446bd68eec59ed8befb3bc27d7e7f031c69708ab54984c9f7537e5d55616be9f7ef1b92e2de61ccd SHA512 739c3c9b136fd3ce784e0a81c82a26a188e7d07435c1381ba359b2e159a721d072cb04310f2ce2a38953a8918fec686025bac6c140048a1afc035c0b8e449483
30
31 diff --git a/www-apache/mod_maxminddb/files/70_mod_maxminddb.conf b/www-apache/mod_maxminddb/files/70_mod_maxminddb.conf
32 new file mode 100644
33 index 00000000000..80d1ba92f10
34 --- /dev/null
35 +++ b/www-apache/mod_maxminddb/files/70_mod_maxminddb.conf
36 @@ -0,0 +1,3 @@
37 +<IfDefine MAXMINDDB>
38 + LoadModule maxminddb_module modules/mod_maxminddb.so
39 +</IfDefine>
40
41 diff --git a/www-apache/mod_maxminddb/metadata.xml b/www-apache/mod_maxminddb/metadata.xml
42 new file mode 100644
43 index 00000000000..a8e20b70aaf
44 --- /dev/null
45 +++ b/www-apache/mod_maxminddb/metadata.xml
46 @@ -0,0 +1,15 @@
47 +<?xml version="1.0" encoding="UTF-8"?>
48 +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
49 +<pkgmetadata>
50 + <maintainer type="person">
51 + <email>hydrapolic@×××××.com</email>
52 + <name>Tomáš Mózes</name>
53 + </maintainer>
54 + <maintainer type="project">
55 + <email>proxy-maint@g.o</email>
56 + <name>Proxy Maintainers</name>
57 + </maintainer>
58 + <upstream>
59 + <remote-id type="github">maxmind/mod_maxminddb</remote-id>
60 + </upstream>
61 +</pkgmetadata>
62
63 diff --git a/www-apache/mod_maxminddb/mod_maxminddb-1.2.0.ebuild b/www-apache/mod_maxminddb/mod_maxminddb-1.2.0.ebuild
64 new file mode 100644
65 index 00000000000..c0d42244f01
66 --- /dev/null
67 +++ b/www-apache/mod_maxminddb/mod_maxminddb-1.2.0.ebuild
68 @@ -0,0 +1,40 @@
69 +# Copyright 1999-2020 Gentoo Authors
70 +# Distributed under the terms of the GNU General Public License v2
71 +
72 +EAPI="6"
73 +
74 +inherit apache-module autotools
75 +
76 +DESCRIPTION="MaxMind DB Apache Module"
77 +HOMEPAGE="https://maxmind.github.io/mod_maxminddb/"
78 +SRC_URI="https://github.com/maxmind/mod_maxminddb/releases/download/${PV}/${P}.tar.gz"
79 +
80 +LICENSE="Apache-2.0"
81 +SLOT="0"
82 +KEYWORDS="~amd64 ~x86"
83 +
84 +DEPEND="dev-libs/libmaxminddb:="
85 +RDEPEND="${DEPEND}"
86 +
87 +need_apache2_4
88 +
89 +src_prepare() {
90 + default
91 + eautoreconf
92 +}
93 +
94 +src_compile() {
95 + # skipping this results in:
96 + # Cannot load modules/mod_maxminddb.so into server:
97 + # /usr/lib64/apache2/modules/mod_maxminddb.so: undefined symbol: MMDB_aget_value
98 + # because mod_maxminddb.so is not linked with libmaxminddb
99 + emake
100 +}
101 +
102 +src_install() {
103 + APACHE2_MOD_CONF="70_${PN}"
104 + APACHE2_MOD_DEFINE="MAXMINDDB"
105 + APACHE_MODULESDIR="/usr/$(get_libdir)/apache2/modules"
106 +
107 + apache-module_src_install
108 +}