jsbeautifier: python3.12 fix

This commit is contained in:
Anton Bolshakov 2024-02-05 14:14:58 +08:00
parent 59d98f6b82
commit 507efcfadb
No known key found for this signature in database
GPG key ID: 32BDCED870788F04
8 changed files with 85 additions and 34 deletions

View file

@ -0,0 +1,2 @@
DIST editorconfig-core-py-0.12.3.gh.tar.gz 19261 BLAKE2B 58cac122cfee19527bc45def7e923da50982de0e2cd443cf67dd824c050fb12352b85a5679815a701bc5b8d88a089a0a98280c364730086d01b80f119ad996a4 SHA512 005d0698c410c8865d177a1e891b5c51b15255f36303b116fddbbbc08e309d1d60ca3003d27e6fd8455e53c5956db0c29e298f22f4b10950e1f7c56c7c6e0ab3
DIST editorconfig-core-test-abb579e00f2deeede91cb485e53512efab9c6474.gh.tar.gz 7900 BLAKE2B 9ebdb5e522948bc9e86ea84435ccaa11585a8a12f4cd6fe54c64d78917281c913568351767d8077623b1196d84206d1c2d0126a0510f70df484c1b55d829028b SHA512 ae5424b4926d6cb127cb3da473400ced4f7ccf224f7baa8bc5bde0317cc045bb7b99738a56efe5fd0e5a0fbe39b997b9fb1739d24713e7f83b58e987c5e56a32

View file

@ -0,0 +1,47 @@
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{9..12} )
inherit cmake distutils-r1
TESTVER="abb579e00f2deeede91cb485e53512efab9c6474"
DESCRIPTION="Clone of EditorConfig core written in Python"
HOMEPAGE="https://editorconfig.org/"
SRC_URI="https://github.com/${PN%-core-py}/${PN}/archive/v${PV}.tar.gz -> ${P}.gh.tar.gz
test? (
https://github.com/${PN%-core-py}/${PN%-core-py}-core-test/archive/${TESTVER}.tar.gz -> ${PN%-core-py}-core-test-${TESTVER}.gh.tar.gz
)"
LICENSE="PYTHON BSD-4"
SLOT="0"
KEYWORDS="amd64 arm64 x86"
IUSE="cli test"
RESTRICT="!test? ( test )"
RDEPEND="
cli? ( !app-text/editorconfig-core-c[cli] )"
src_prepare() {
if use test; then
mv "${WORKDIR}"/${PN%-core-py}-core-test-${TESTVER}/* "${S}"/tests || die
fi
if ! use cli; then
sed -i -e '/editorconfig\.__main__/d' setup.py || die
fi
cmake_src_prepare
distutils-r1_src_prepare
}
python_test() {
local mycmakeargs=(
-DPYTHON_EXECUTABLE="${PYTHON}"
)
cmake_src_configure
cmake_src_compile
cmake_src_test
}

View file

@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>chutzpah@gentoo.org</email>
<name>Patrick McLean</name>
</maintainer>
<maintainer type="project">
<email>python@gentoo.org</email>
<name>Python</name>
</maintainer>
<use>
<flag name="cli">Install command line interface as well as python library</flag>
</use>
<longdescription lang="en">
EditorConfig Python Core provides the same functionality as the
EditorConfig C Core. EditorConfig Python core can be used as a
command line program or as an importable library.
</longdescription>
<upstream>
<remote-id type="github">editorconfig/editorconfig-core-test</remote-id>
<remote-id type="pypi">EditorConfig</remote-id>
</upstream>
</pkgmetadata>

View file

@ -1,3 +1,2 @@
DIST jsbeautifier-1.14.11.tar.gz 75586 BLAKE2B ce0518b6eb159443323dbb6394063a5ab2d91326ecca7503e4b17626082fba09f1f4713eb101e9f8a3e19a29a2b273840f011b80b0dad4a7dee8ed296338a803 SHA512 d84847ad71af40a08ca47af449eeaaaf1d4b8ad3981f9573b4322e42b0060caba0fbd2632d6686306fcdac64a7e03ad6eaf9ad4461489984aabff3b33331a310
DIST jsbeautifier-1.14.6.tar.gz 74554 BLAKE2B fd9761d352add4541d828f3a59f1e857968c8522230c32528fbd8f471e862246d3082649c8f9ee258adf291e0805793e06be3a9b3626ef169b366a3f87b6fd40 SHA512 503bcb5e805dc385a0463127590a00339ec8f6fc4ba6b6c1fc7eb3ff91310fa4bfd8a92112eec7d8c503452de2df2dc105642313ece396120befb84c142161fb
DIST jsbeautifier-1.14.7.tar.gz 74564 BLAKE2B cbf08275b3d0e3b5342548c6277d4284448915685a4b2705673789eee1d1e6ed86f66dc2c682c000d3722194947384c8fc7f4fdb15c96d2bff489fc5a2601452 SHA512 bd3c201050db470373fad62bb1f3e78fe42b728d410d9079f3ca12a3f2e8a7aa48f9ca34e8c5449a0abd1ac67e3feece55a51ef52f6328539c5406a40e4bf4df

View file

@ -1,21 +1,19 @@
# Copyright 1999-2023 Gentoo Authors
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
EAPI=8
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{10..11} )
PYTHON_COMPAT=( python3_{10..12} )
inherit distutils-r1
inherit distutils-r1 pypi
DESCRIPTION="Beautify, unpack or deobfuscate JavaScript"
HOMEPAGE="https://pypi.python.org/pypi/jsbeautifier"
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="amd64 ~arm64 x86"
IUSE=""
RDEPEND=">=dev-python/six-1.13.0[${PYTHON_USEDEP}]
>=dev-python/editorconfig-core-py-0.12.2[${PYTHON_USEDEP}]"

View file

@ -1,21 +0,0 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python3_{10..11} )
inherit distutils-r1
DESCRIPTION="Beautify, unpack or deobfuscate JavaScript"
HOMEPAGE="https://pypi.python.org/pypi/jsbeautifier"
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="amd64 ~arm64 x86"
IUSE=""
RDEPEND=">=dev-python/six-1.13.0[${PYTHON_USEDEP}]
>=dev-python/editorconfig-core-py-0.12.2[${PYTHON_USEDEP}]"
DEPEND="${RDEPEND}"

View file

@ -1,20 +1,19 @@
# Copyright 1999-2022 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
EAPI=8
PYTHON_COMPAT=( python3_{10..11} )
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{10..12} )
inherit distutils-r1
inherit distutils-r1 pypi
DESCRIPTION="Beautify, unpack or deobfuscate JavaScript"
HOMEPAGE="https://pypi.python.org/pypi/jsbeautifier"
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="amd64 ~arm64 x86"
IUSE=""
RDEPEND=">=dev-python/six-1.13.0[${PYTHON_USEDEP}]
>=dev-python/editorconfig-core-py-0.12.2[${PYTHON_USEDEP}]"

View file

@ -5,4 +5,7 @@
<email>unknown@pentoo.ch</email>
<name>Author Unknown</name>
</maintainer>
<upstream>
<remote-id type="pypi">jsbeautifier</remote-id>
</upstream>
</pkgmetadata>