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