1 |
commit: a781960b31e293725e20ed04279a6684883c9e9c |
2 |
Author: Ralph Seichter <ralph <AT> seichter <DOT> de> |
3 |
AuthorDate: Sat Jul 28 13:04:43 2018 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Jul 30 20:22:59 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a781960b |
7 |
|
8 |
www-servers/nginx-unit: Fixed modules directory, Python dependencies |
9 |
|
10 |
Also added pkg_setup() to conditionally support Python and fixed |
11 |
contents of REQUIRED_USE. |
12 |
|
13 |
Closes: https://github.com/gentoo/gentoo/pull/9278 |
14 |
|
15 |
www-servers/nginx-unit/nginx-unit-1.3-r1.ebuild | 19 ++++++++++++++----- |
16 |
1 file changed, 14 insertions(+), 5 deletions(-) |
17 |
|
18 |
diff --git a/www-servers/nginx-unit/nginx-unit-1.3-r1.ebuild b/www-servers/nginx-unit/nginx-unit-1.3-r1.ebuild |
19 |
index 9a9a22e39cd..304602c948a 100644 |
20 |
--- a/www-servers/nginx-unit/nginx-unit-1.3-r1.ebuild |
21 |
+++ b/www-servers/nginx-unit/nginx-unit-1.3-r1.ebuild |
22 |
@@ -3,8 +3,11 @@ |
23 |
|
24 |
EAPI=7 |
25 |
|
26 |
-MY_P="unit-${PV}" |
27 |
+PYTHON_COMPAT=(python2_7 python3_{3,4,5,6}) |
28 |
+ |
29 |
+inherit python-single-r1 |
30 |
|
31 |
+MY_P="unit-${PV}" |
32 |
DESCRIPTION="A dynamic web and application server" |
33 |
HOMEPAGE="https://unit.nginx.org" |
34 |
SRC_URI="https://unit.nginx.org/download/${MY_P}.tar.gz -> ${P}.tar.gz" |
35 |
@@ -12,23 +15,29 @@ SRC_URI="https://unit.nginx.org/download/${MY_P}.tar.gz -> ${P}.tar.gz" |
36 |
LICENSE="Apache-2.0" |
37 |
SLOT="0" |
38 |
KEYWORDS="~amd64" |
39 |
-IUSE="perl python ruby" |
40 |
-REQUIRED_USE="|| ( ${IUSE} )" |
41 |
+MY_IUSE="perl python ruby" |
42 |
+IUSE="${MY_IUSE}" |
43 |
+REQUIRED_USE="|| ( ${MY_IUSE} ) python? ( ${PYTHON_REQUIRED_USE} )" |
44 |
|
45 |
DEPEND="perl? ( dev-lang/perl:= ) |
46 |
- python? ( dev-lang/python:= ) |
47 |
+ python? ( ${PYTHON_DEPS} ) |
48 |
ruby? ( dev-lang/ruby:= )" |
49 |
RDEPEND="${DEPEND}" |
50 |
S="${WORKDIR}/${MY_P}" |
51 |
|
52 |
+pkg_setup() { |
53 |
+ use python && python-single-r1_pkg_setup |
54 |
+} |
55 |
+ |
56 |
src_configure() { |
57 |
./configure \ |
58 |
--prefix=/usr \ |
59 |
+ --modules=$(get_libdir)/${PN} \ |
60 |
--log=/var/log/${PN} \ |
61 |
--state=/var/lib/${PN} \ |
62 |
--pid=/run/${PN}.pid \ |
63 |
--control=unix:/run/${PN}.sock || die "Core configuration failed" |
64 |
- for flag in ${IUSE} ; do |
65 |
+ for flag in ${MY_IUSE} ; do |
66 |
if use ${flag} ; then |
67 |
./configure ${flag} || die "Module configuration failed: ${flag}" |
68 |
fi |