commit: a5c8f6d574beb2fc4ffba07dc78291f3f675d577 Author: Marco Scardovi <marco <AT> scardovi <DOT> com> AuthorDate: Sat May 1 09:16:25 2021 +0000 Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org> CommitDate: Wed Jun 2 12:59:05 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a5c8f6d5
www-apps/radicale: enabling test Added required packages for enabling test on pytest Package-Manager: Portage-3.0.18, Repoman-3.0.3 Signed-off-by: Marco Scardovi <marco <AT> scardovi.com> Closes: https://github.com/gentoo/gentoo/pull/20625 Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org> ...le-3.0.6-r1.ebuild => radicale-3.0.6-r2.ebuild} | 42 ++++++++++++++-------- 1 file changed, 27 insertions(+), 15 deletions(-) diff --git a/www-apps/radicale/radicale-3.0.6-r1.ebuild b/www-apps/radicale/radicale-3.0.6-r2.ebuild similarity index 60% rename from www-apps/radicale/radicale-3.0.6-r1.ebuild rename to www-apps/radicale/radicale-3.0.6-r2.ebuild index 3c2169639c6..bd2ad27a558 100644 --- a/www-apps/radicale/radicale-3.0.6-r1.ebuild +++ b/www-apps/radicale/radicale-3.0.6-r2.ebuild @@ -4,7 +4,7 @@ EAPI=7 DISTUTILS_USE_SETUPTOOLS=rdepend -PYTHON_COMPAT=( python3_{7..9} ) +PYTHON_COMPAT=( python3_{8..9} ) inherit distutils-r1 systemd @@ -23,38 +23,49 @@ RDEPEND=" acct-group/radicale dev-python/defusedxml dev-python/passlib[bcrypt,${PYTHON_USEDEP}] - >=dev-python/vobject-0.9.6[${PYTHON_USEDEP}] - >=dev-python/python-dateutil-2.8.1[${PYTHON_USEDEP}] + dev-python/python-dateutil[${PYTHON_USEDEP}] + dev-python/vobject[${PYTHON_USEDEP}] + dev-python/waitress[${PYTHON_USEDEP}] sys-apps/util-linux " +BDEPEND="test? ( ${RDEPEND} )" + S="${WORKDIR}/${MY_P}" -RDIR=/var/lib/${PN} +RDIR=/var/lib/"${PN}" + +DOCS=( DOCUMENTATION.md NEWS.md ) + +src_prepare() { + sed -i '/^addopts =/d' setup.cfg || die + distutils-r1_src_prepare +} python_install_all() { rm README* || die - # init file newinitd "${FILESDIR}"/radicale-r3.init.d radicale systemd_dounit "${FILESDIR}/${PN}.service" # directories - keepdir ${RDIR} - fowners ${PN}:${PN} ${RDIR} - fperms 0750 ${RDIR} + keepdir "${RDIR}" + fperms 0750 "${RDIR}" + fowners "${PN}:${PN}" "${RDIR}" # config file - insinto /etc/${PN} + insinto /etc/"${PN}" doins config # fcgi and wsgi files - exeinto /usr/share/${PN} + exeinto /usr/share/"${PN}" doexe radicale.wsgi distutils-r1_python_install_all } +distutils_enable_tests pytest + pkg_postinst() { local _erdir="${EROOT}${RDIR}" @@ -62,11 +73,12 @@ pkg_postinst() { einfo "You will also find there an example FastCGI script." if [[ $(stat --format="%U:%G:%a" "${_erdir}") != "${PN}:${PN}:750" ]] then - ewarn "Unsafe file permissions detected on ${_erdir}. This probably comes" - ewarn "from an earlier version of this ebuild." + ewarn "" + ewarn "Unsafe file permissions detected on ${_erdir}." + ewarn "This probably comes from an earlier version of this ebuild." ewarn "To fix run:" - ewarn " \`chown -R ${PN}:${PN} ${_erdir}\`" - ewarn " \`chmod 0750 ${_erdir}\`" - ewarn " \`chmod -R o= ${_erdir}\`" + ewarn "# \`chown -R ${PN}:${PN} ${_erdir}\`" + ewarn "# \`chmod 0750 ${_erdir}\`" + ewarn "# \`chmod -R o= ${_erdir}\`" fi }
