diff options
author | Maciej Barć <xgqt@gentoo.org> | 2024-04-14 00:06:07 +0200 |
---|---|---|
committer | Maciej Barć <xgqt@gentoo.org> | 2024-04-14 00:55:48 +0200 |
commit | de2d3b0c5f990d885aa2247aacd776393b203586 (patch) | |
tree | a015d386c5cae8f12d479bf0dd88dc12e0cca774 /app-emacs | |
parent | app-emacs/pymacs: port to py3.12 (diff) | |
download | gentoo-de2d3b0c5f990d885aa2247aacd776393b203586.tar.gz gentoo-de2d3b0c5f990d885aa2247aacd776393b203586.tar.bz2 gentoo-de2d3b0c5f990d885aa2247aacd776393b203586.zip |
app-emacs/elpy: enable py3.12 compat
Closes: https://bugs.gentoo.org/929303
Closes: https://bugs.gentoo.org/885897
Signed-off-by: Maciej Barć <xgqt@gentoo.org>
Diffstat (limited to 'app-emacs')
-rw-r--r-- | app-emacs/elpy/elpy-1.35.0_p20220627-r1.ebuild (renamed from app-emacs/elpy/elpy-1.35.0_p20220627.ebuild) | 47 |
1 files changed, 32 insertions, 15 deletions
diff --git a/app-emacs/elpy/elpy-1.35.0_p20220627.ebuild b/app-emacs/elpy/elpy-1.35.0_p20220627-r1.ebuild index eab92e1f5156..dbb7bd8ac1ba 100644 --- a/app-emacs/elpy/elpy-1.35.0_p20220627.ebuild +++ b/app-emacs/elpy/elpy-1.35.0_p20220627-r1.ebuild @@ -1,25 +1,33 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 -[[ ${PV} == *_p20220627 ]] && COMMIT=de31d30003c515c25ff7bfd3a361c70c298f78bb - DISTUTILS_SINGLE_IMPL=ON DISTUTILS_USE_PEP517=setuptools -PYTHON_COMPAT=( python3_{9..11} ) +PYTHON_COMPAT=( python3_{10..12} ) inherit distutils-r1 elisp DESCRIPTION="Emacs Python Development Environment" HOMEPAGE="https://github.com/jorgenschaefer/elpy/" -SRC_URI="https://github.com/jorgenschaefer/${PN}/archive/${COMMIT}.tar.gz - -> ${P}.tar.gz" -S="${WORKDIR}"/${PN}-${COMMIT} + +if [[ "${PV}" == *9999* ]] ; then + inherit git-r3 + + EGIT_REPO_URI="https://github.com/jorgenschaefer/${PN}.git" +else + [[ "${PV}" == *_p20220627 ]] && COMMIT=de31d30003c515c25ff7bfd3a361c70c298f78bb + + SRC_URI="https://github.com/jorgenschaefer/${PN}/archive/${COMMIT}.tar.gz + -> ${P}.tar.gz" + S="${WORKDIR}/${PN}-${COMMIT}" + + KEYWORDS="~amd64 ~x86" +fi LICENSE="GPL-3+" SLOT="0" -KEYWORDS="~amd64 ~x86" IUSE="test" RESTRICT="!test? ( test )" @@ -29,7 +37,9 @@ RDEPEND=" app-emacs/pyvenv app-emacs/s app-emacs/yasnippet - $(python_gen_cond_dep 'dev-python/flake8[${PYTHON_USEDEP}]') + $(python_gen_cond_dep ' + dev-python/flake8[${PYTHON_USEDEP}] + ') " BDEPEND=" ${RDEPEND} @@ -42,9 +52,13 @@ BDEPEND=" ) " +ELISP_REMOVE=" + elpy/tests/test_black.py + elpy/tests/test_yapf.py +" PATCHES=( - "${FILESDIR}"/${PN}-elpy.el-yas-snippet-dirs.patch - "${FILESDIR}"/${PN}-elpy-rpc.el-elpy-rpc-pythonpath.patch + "${FILESDIR}/${PN}-elpy.el-yas-snippet-dirs.patch" + "${FILESDIR}/${PN}-elpy-rpc.el-elpy-rpc-pythonpath.patch" ) DOCS=( CONTRIBUTING.rst README.rst ) @@ -60,10 +74,13 @@ pkg_setup() { src_prepare() { distutils-r1_src_prepare - rm elpy/tests/test_black.py || die - sed -i "s|@SITEETC@|${EPREFIX}${SITEETC}/${PN}|" ${PN}.el || die - sed -i "s|@PYTHONLIB@|${EPREFIX}/usr/lib/${EPYTHON}|" ${PN}-rpc.el || die + sed -i "${PN}.el" -e "s|@SITEETC@|${EPREFIX}${SITEETC}/${PN}|" || die + sed -i "${PN}-rpc.el" -e "s|@PYTHONLIB@|${EPREFIX}/usr/lib/${EPYTHON}|" || die + + rm ${ELISP_REMOVE} || die + sed -i elpy/tests/support.py \ + -e "s|test_should_get_oneline_docstring_for_modules|disabled_&|" || die } src_compile() { @@ -79,6 +96,6 @@ src_install() { distutils-r1_src_install elisp_src_install - insinto ${SITEETC}/${PN} + insinto "${SITEETC}/${PN}" doins -r snippets } |