diff --git a/.github/workflows/portage-stable-packages-list b/.github/workflows/portage-stable-packages-list index d498d02f818..81595f5d963 100644 --- a/.github/workflows/portage-stable-packages-list +++ b/.github/workflows/portage-stable-packages-list @@ -270,6 +270,8 @@ dev-libs/oniguruma dev-libs/opensc dev-libs/popt dev-libs/protobuf +dev-libs/tree-sitter +dev-libs/tree-sitter-bash dev-libs/userspace-rcu dev-libs/xmlsec dev-libs/yajl @@ -282,6 +284,7 @@ dev-python/autocommand dev-python/backports-tarfile dev-python/cachecontrol dev-python/certifi +dev-python/chardet dev-python/charset-normalizer dev-python/colorama dev-python/crcmod @@ -335,6 +338,7 @@ dev-python/six dev-python/snakeoil dev-python/tenacity dev-python/tomli +dev-python/tree-sitter dev-python/trove-classifiers dev-python/truststore dev-python/typing-extensions @@ -354,6 +358,7 @@ dev-util/pahole dev-util/patchelf dev-util/patchutils dev-util/perf +dev-util/pkgcheck dev-util/pkgconf dev-util/re2c @@ -452,6 +457,7 @@ eclass/tmpfiles.eclass eclass/toolchain-autoconf.eclass eclass/toolchain-funcs.eclass eclass/toolchain.eclass +eclass/tree-sitter-grammar.eclass eclass/udev.eclass eclass/unpacker.eclass eclass/user-info.eclass @@ -583,6 +589,7 @@ sys-apps/net-tools sys-apps/nvme-cli sys-apps/pciutils sys-apps/pcsc-lite +sys-apps/pkgcore sys-apps/portage sys-apps/pv sys-apps/sandbox diff --git a/sdk_container/src/third_party/coreos-overlay/coreos-devel/sdk-depends/sdk-depends-0.0.1-r49.ebuild b/sdk_container/src/third_party/coreos-overlay/coreos-devel/sdk-depends/sdk-depends-0.0.1-r50.ebuild similarity index 100% rename from sdk_container/src/third_party/coreos-overlay/coreos-devel/sdk-depends/sdk-depends-0.0.1-r49.ebuild rename to sdk_container/src/third_party/coreos-overlay/coreos-devel/sdk-depends/sdk-depends-0.0.1-r50.ebuild diff --git a/sdk_container/src/third_party/coreos-overlay/coreos-devel/sdk-depends/sdk-depends-0.0.1.ebuild b/sdk_container/src/third_party/coreos-overlay/coreos-devel/sdk-depends/sdk-depends-0.0.1.ebuild index 8056e13f26e..e36aeb5b0e8 100644 --- a/sdk_container/src/third_party/coreos-overlay/coreos-devel/sdk-depends/sdk-depends-0.0.1.ebuild +++ b/sdk_container/src/third_party/coreos-overlay/coreos-devel/sdk-depends/sdk-depends-0.0.1.ebuild @@ -47,7 +47,8 @@ DEPEND=" sys-fs/btrfs-progs sys-fs/cryptsetup dev-perl/Parse-Yapp - " + dev-util/pkgcheck +" # Must match the build-time dependencies listed in selinux-policy-2.eclass DEPEND="${DEPEND} diff --git a/sdk_container/src/third_party/coreos-overlay/coreos/config/env/dev-util/pkgcheck b/sdk_container/src/third_party/coreos-overlay/coreos/config/env/dev-util/pkgcheck new file mode 100644 index 00000000000..549392a7a88 --- /dev/null +++ b/sdk_container/src/third_party/coreos-overlay/coreos/config/env/dev-util/pkgcheck @@ -0,0 +1,9 @@ +cros_post_src_install_create_default_config() { + insinto /etc/pkgcheck + # these must be indented with tabs, bash only strips leading + # tabs with "<<-", leading spaces won't do. + newins - pkgcheck.conf <<-EOF + [DEFAULT] + keywords = -NonexistentDeps,-NonsolvableDepsInDev,-NonsolvableDepsInExp,-NonsolvableDepsInStable + EOF +} diff --git a/sdk_container/src/third_party/coreos-overlay/coreos/user-patches/sys-apps/pkgcore/0001-build-profiles-patch.patch b/sdk_container/src/third_party/coreos-overlay/coreos/user-patches/sys-apps/pkgcore/0001-build-profiles-patch.patch new file mode 100644 index 00000000000..5d25d2dcbfa --- /dev/null +++ b/sdk_container/src/third_party/coreos-overlay/coreos/user-patches/sys-apps/pkgcore/0001-build-profiles-patch.patch @@ -0,0 +1,28 @@ +From dd76e415b2a707d31a125201c5d21aadb07282a7 Mon Sep 17 00:00:00 2001 +From: James Le Cuirot +Date: Tue, 11 Jun 2024 15:39:25 +0100 +Subject: [PATCH] ebuild.profiles: Fix case where a parent path omits the repo + identifier + +According "SPECIFIC FILE DESCRIPTIONS" in `man portage`, it is valid to +have a parent path like `:path/to/profile` where the repo identifier is +missing. This refers to a path in the current repo. + +Signed-off-by: James Le Cuirot +--- + src/pkgcore/ebuild/profiles.py | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/src/pkgcore/ebuild/profiles.py b/src/pkgcore/ebuild/profiles.py +index 384e41e22..fea1eacc7 100644 +--- a/src/pkgcore/ebuild/profiles.py ++++ b/src/pkgcore/ebuild/profiles.py +@@ -254,6 +254,8 @@ def parent_paths(self, data): + f"unknown repo {repo_id!r}" + ) + continue ++ else: ++ location = repo_config.location + l.append( + ( + abspath(pjoin(location, "profiles", profile_path)), diff --git a/sdk_container/src/third_party/coreos-overlay/coreos/user-patches/sys-apps/pkgcore/README.md b/sdk_container/src/third_party/coreos-overlay/coreos/user-patches/sys-apps/pkgcore/README.md new file mode 100644 index 00000000000..c61330e6b22 --- /dev/null +++ b/sdk_container/src/third_party/coreos-overlay/coreos/user-patches/sys-apps/pkgcore/README.md @@ -0,0 +1,2 @@ +The `0001-build-profiles-patch.patch` patch can be dropped when we +update sys-apps/pkgcore to version greater than `0.12.27`. diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/Manifest b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/Manifest new file mode 100644 index 00000000000..a9d7f4e84ba --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/Manifest @@ -0,0 +1,4 @@ +DIST tree-sitter-bash-0.19.0.tar.gz 187286 BLAKE2B 8812a593366a65a9cae3eaac5bb81c71e95f4abe8558a01b908333e471f05714b1c768b71e66d3890d1e63202819290813e499a5e8ba49e72bb466b9b0f245f8 SHA512 62bc8bc25c999f9c79632bd6b236edd21ef15b14365dd1a956237b11a32f5e60a2f420ec67b60d46203699b7841d4bc10978fc0307d0c4013b376c6c024d89ae +DIST tree-sitter-bash-0.20.4-2.tar.gz 444183 BLAKE2B 31016de876ed84ab991ebc1e531dd750c416a86db5f91097db54e7362de673ea89bbf8863a9df487f75386f19a7e8ddde48a2e727af918d1beea8acad3ce67c6 SHA512 074f659ea475c7a442957a3df234f967ae9a6ace885ecfad6548a1d0f2af7535e5460d81bcd160a04bda1b902af0a9f741fc0c7b22309cd1d11ab2bc33ff0a22 +DIST tree-sitter-bash-0.20.5.tar.gz 525750 BLAKE2B 2508ede3ac6b0a7bac3f46af35ea018916b5cf6b0acf593e546146277c1a619dba52eac6064e3e0431e0f5e41bc80b441e0ac8886287ccce5bdabe3924a036e8 SHA512 bc1c4ec816183b4a4990decd45f3c46a424e29d4c417b762f3f761b6396faa984c6eb05237cb4921070e0b478485146889176a862b0935b4b345a704675bef22 +DIST tree-sitter-bash-0.21.0.tar.gz 557096 BLAKE2B bfbdb4db0f75c292567043a47d32e26c6ec119ed70fa9b77675eb57e686c072315fc114befecc430730c8eec20238544d13836402f2264a1b6657e0387d4987c SHA512 9585ea80f85bc7010444a91142bc943486ade68982c7ca367a6cbe65619af2bdaa1acd8b6ee698cdf74b84d62a7f44acc4676ddb4b6007035eb9eea4768f122d diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/metadata.xml b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/metadata.xml new file mode 100644 index 00000000000..235b9835b8f --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/metadata.xml @@ -0,0 +1,15 @@ + + + + + matthew@gentoo.org + Matthew Smith + + + pkgcore@gentoo.org + Pkgcore + + + tree-sitter/tree-sitter-bash + + diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.19.0.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.19.0.ebuild new file mode 100644 index 00000000000..bf87fe76c9f --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.19.0.ebuild @@ -0,0 +1,13 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit tree-sitter-grammar + +DESCRIPTION="Bash grammar for Tree-sitter" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter-bash" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.20.4-r1.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.20.4-r1.ebuild new file mode 100644 index 00000000000..8d2e42a385d --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.20.4-r1.ebuild @@ -0,0 +1,17 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit tree-sitter-grammar + +DESCRIPTION="Bash grammar for Tree-sitter" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter-bash" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" + +# Override eclass SRC_URI as 0.20.4 was bumped incorrectly. +SRC_URI="https://github.com/tree-sitter/${PN}/archive/v${PV}.tar.gz + -> ${P}-2.tar.gz" diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.20.5.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.20.5.ebuild new file mode 100644 index 00000000000..fa2574fde71 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.20.5.ebuild @@ -0,0 +1,13 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit tree-sitter-grammar + +DESCRIPTION="Bash grammar for Tree-sitter" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter-bash" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.21.0-r1.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.21.0-r1.ebuild new file mode 100644 index 00000000000..c9c0cd8e9ce --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter-bash/tree-sitter-bash-0.21.0-r1.ebuild @@ -0,0 +1,15 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +TS_BINDINGS=( python ) + +inherit tree-sitter-grammar + +DESCRIPTION="Bash grammar for Tree-sitter" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter-bash" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/Manifest b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/Manifest new file mode 100644 index 00000000000..6fd6117e062 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/Manifest @@ -0,0 +1,5 @@ +DIST tree-sitter-0.22.2.tar.gz 3040339 BLAKE2B c18a79b4fdf553c50b4dd4c67c92d02fd341c5266c4658eb226d9ea455f23d2d22fe4ed4ca48811da2c8a59c403d8eff53dd9257468df7a9cfa640652c485c95 SHA512 a42d744f6e1db7c7c842804f3435b87ccb5d0df2363a18eee38353f12f18c8cf0c6211bf0225fd5f2c0431ca8531aa4ddd73d87d42b80fa35c3c701cae2d7856 +DIST tree-sitter-0.22.4.tar.gz 3034955 BLAKE2B 797feb6e2171b0e00b10c67c8b6dcda6cc2ec420ef797991a642524982629496e4b7bcae92a2658ba3adffea75332bcda09ecbced01e73e13ba6f4c39d15e9ea SHA512 7f160e88cdffb47f4ee3f884385ec759fcf88883307221ddadd8bf561d1dfb3659b0c7f4b216286066cf912183cc8234788492d62d1f1ad14fcb39bd3287cf36 +DIST tree-sitter-0.22.5.tar.gz 3035094 BLAKE2B f54b16e2421ad68fd34b5bada767010be4224652f5a138f7afcdbc15ebaae98dfe3cc8ac77e5e8e5ab12cef516464d29e38a23fc895fa966d5a03a9569fa5ffc SHA512 cff3902e8f6e0211b6d4fafecf9f0d73a2bf73efed68df0d6e8798aac3e685cbcc882fb698ebc10115e72bcf46b59aabd0b14dd402a08d3b42cfceffea5aab2c +DIST tree-sitter-0.22.6.tar.gz 3036954 BLAKE2B f109a738214882e63a721e8db384fa42a624af78d42ceb9ab7a45135b36cf3bbbd2554f470ca5038404365f5b9dbf9979c4d26309e123a9d9533feb1f0a3f724 SHA512 bf0b87bb9ce16b049824e53933986ac451a7b7f432df39ee9d4546627d740ae689af9e838a53cc50e29d66d6d85d51dab7490d66a429a14bcc9d0b8e2935a63a +DIST tree-sitter-0.23.0.tar.gz 2977346 BLAKE2B e10846d5bd0a6aa1ecac362e2ab2ccf0f0bdb17c5fde796d8d65f8bc84a6e054d86c18a42e66e8effef865f95013c38ff6bd6ab5498a680ae172d7d57020604e SHA512 ab821be564ac7223cc4f9659c08922a78016af9dd3bd69166706fb6a889ac175ba2712a337a1303aceb8f44beaf58640a183e77dddc2c57e35da23079d0cd7b9 diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/files/tree-sitter-0.22.2-no-static.patch b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/files/tree-sitter-0.22.2-no-static.patch new file mode 100644 index 00000000000..47934bbcd35 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/files/tree-sitter-0.22.2-no-static.patch @@ -0,0 +1,20 @@ +--- a/Makefile ++++ b/Makefile +@@ -45,7 +45,7 @@ ifneq ($(filter $(shell uname),FreeBSD NetBSD DragonFly),) + PCLIBDIR := $(PREFIX)/libdata/pkgconfig + endif + +-all: libtree-sitter.a libtree-sitter.$(SOEXT) tree-sitter.pc ++all: libtree-sitter.$(SOEXT) tree-sitter.pc + + libtree-sitter.a: $(OBJ) + $(AR) $(ARFLAGS) $@ $^ +@@ -69,7 +69,6 @@ clean: + install: all + install -d '$(DESTDIR)$(INCLUDEDIR)'/tree_sitter '$(DESTDIR)$(PCLIBDIR)' '$(DESTDIR)$(LIBDIR)' + install -m644 lib/include/tree_sitter/api.h '$(DESTDIR)$(INCLUDEDIR)'/tree_sitter/api.h + install -m644 tree-sitter.pc '$(DESTDIR)$(PCLIBDIR)'/tree-sitter.pc +- install -m644 libtree-sitter.a '$(DESTDIR)$(LIBDIR)'/libtree-sitter.a + install -m755 libtree-sitter.$(SOEXT) '$(DESTDIR)$(LIBDIR)'/libtree-sitter.$(SOEXTVER) + ln -sf libtree-sitter.$(SOEXTVER) '$(DESTDIR)$(LIBDIR)'/libtree-sitter.$(SOEXTVER_MAJOR) + ln -sf libtree-sitter.$(SOEXTVER_MAJOR) '$(DESTDIR)$(LIBDIR)'/libtree-sitter.$(SOEXT) diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/metadata.xml b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/metadata.xml new file mode 100644 index 00000000000..17bc8472b8c --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/metadata.xml @@ -0,0 +1,26 @@ + + + + + abdelqaderali@protonmail.com + Ali Abdel-Qader + + + mva@gentoo.org + Vadim Misbakh-Soloviov + + + matthew@gentoo.org + Matthew Smith + + + pkgcore@gentoo.org + Pkgcore + + + tree-sitter/tree-sitter + + + Tree-sitter is a parser generator tool and an incremental parsing library. It can build a concrete syntax tree for a source file and efficiently update the syntax tree as the source file is edited. + + diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.2.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.2.ebuild new file mode 100644 index 00000000000..66553bca39a --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.2.ebuild @@ -0,0 +1,51 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# Bump tree-sitter-cli at the same time. + +EAPI=8 + +inherit optfeature toolchain-funcs + +DESCRIPTION="Tree-sitter is a parser generator tool and an incremental parsing library" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter" + +if [[ ${PV} == *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/${PN}/${PN}" +else + SRC_URI="https://github.com/${PN}/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" +fi + +LICENSE="MIT" +SLOT="0" +RESTRICT="test" # tests are for CLI and not the lib + +PATCHES=( + "${FILESDIR}/${PN}-0.22.2-no-static.patch" +) + +src_prepare() { + default + tc-export CC +} + +src_compile() { + emake \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + STRIP="" \ + CFLAGS="${CFLAGS}" +} + +src_install() { + emake DESTDIR="${D}" \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + install +} + +pkg_postinst() { + optfeature "building and testing grammars" dev-util/tree-sitter-cli +} diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.4-r1.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.4-r1.ebuild new file mode 100644 index 00000000000..d9718e3f31d --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.4-r1.ebuild @@ -0,0 +1,49 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit optfeature toolchain-funcs + +DESCRIPTION="Tree-sitter is a parser generator tool and an incremental parsing library" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter" + +if [[ ${PV} == *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/${PN}/${PN}" +else + SRC_URI="https://github.com/${PN}/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" +fi + +LICENSE="MIT" +# soname is .0, but abi was broken unexpectedly +# Bug #930039 +SLOT="0/1" +RESTRICT="test" # tests are for CLI and not the lib + +PATCHES=( + "${FILESDIR}/${PN}-0.22.2-no-static.patch" +) + +src_prepare() { + default + tc-export CC +} + +src_compile() { + emake \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + STRIP="" # bug 930020 +} + +src_install() { + emake DESTDIR="${D}" \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + install +} + +pkg_postinst() { + optfeature "building and testing grammars" dev-util/tree-sitter-cli +} diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.5.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.5.ebuild new file mode 100644 index 00000000000..15f132d978a --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.5.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit optfeature toolchain-funcs + +DESCRIPTION="Tree-sitter is a parser generator tool and an incremental parsing library" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter" + +if [[ ${PV} == *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/${PN}/${PN}" +else + SRC_URI="https://github.com/${PN}/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" +fi + +LICENSE="MIT" +# ABI is not stable. Revisit after tree-sitter-1.0. +# https://bugs.gentoo.org/930039 +# https://github.com/tree-sitter/tree-sitter/pull/3302 +SLOT="0/${PV}" +RESTRICT="test" # tests are for CLI and not the lib + +PATCHES=( + "${FILESDIR}/${PN}-0.22.2-no-static.patch" +) + +src_prepare() { + default + tc-export CC +} + +src_compile() { + emake \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + STRIP="" # bug 930020 +} + +src_install() { + emake DESTDIR="${D}" \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + install +} + +pkg_postinst() { + optfeature "building and testing grammars" dev-util/tree-sitter-cli +} diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.6.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.6.ebuild new file mode 100644 index 00000000000..c3ae4d33678 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.22.6.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit optfeature toolchain-funcs + +DESCRIPTION="Tree-sitter is a parser generator tool and an incremental parsing library" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter" + +if [[ ${PV} == *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/${PN}/${PN}" +else + SRC_URI="https://github.com/${PN}/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" +fi + +LICENSE="MIT" +# ABI is not stable. Revisit after tree-sitter-1.0. +# https://bugs.gentoo.org/930039 +# https://github.com/tree-sitter/tree-sitter/pull/3302 +SLOT="0/${PV}" +RESTRICT="test" # tests are for CLI and not the lib + +PATCHES=( + "${FILESDIR}/${PN}-0.22.2-no-static.patch" +) + +src_prepare() { + default + tc-export CC +} + +src_compile() { + emake \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + STRIP="" # bug 930020 +} + +src_install() { + emake DESTDIR="${D}" \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + install +} + +pkg_postinst() { + optfeature "building and testing grammars" dev-util/tree-sitter-cli +} diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.23.0.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.23.0.ebuild new file mode 100644 index 00000000000..e8a13d2615f --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-0.23.0.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit optfeature toolchain-funcs + +DESCRIPTION="Tree-sitter is a parser generator tool and an incremental parsing library" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter" + +if [[ ${PV} == *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/${PN}/${PN}" +else + SRC_URI="https://github.com/${PN}/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" +fi + +LICENSE="MIT" +# ABI is not stable. Revisit after tree-sitter-1.0. +# https://bugs.gentoo.org/930039 +# https://github.com/tree-sitter/tree-sitter/pull/3302 +SLOT="0/${PV}" +RESTRICT="test" # tests are for CLI and not the lib + +PATCHES=( + "${FILESDIR}/${PN}-0.22.2-no-static.patch" +) + +src_prepare() { + default + tc-export CC +} + +src_compile() { + emake \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + STRIP="" # bug 930020 +} + +src_install() { + emake DESTDIR="${D}" \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + install +} + +pkg_postinst() { + optfeature "building and testing grammars" dev-util/tree-sitter-cli +} diff --git a/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-9999.ebuild b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-9999.ebuild new file mode 100644 index 00000000000..178a494dffc --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-libs/tree-sitter/tree-sitter-9999.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit optfeature toolchain-funcs + +DESCRIPTION="Tree-sitter is a parser generator tool and an incremental parsing library" +HOMEPAGE="https://github.com/tree-sitter/tree-sitter" + +if [[ ${PV} == *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/${PN}/${PN}" +else + SRC_URI="https://github.com/${PN}/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" +fi + +LICENSE="MIT" +# ABI is not stable. Revisit after tree-sitter-1.0. +# https://bugs.gentoo.org/930039 +# https://github.com/tree-sitter/tree-sitter/pull/3302 +SLOT="0/${PV}" +RESTRICT="test" # tests are for CLI and not the lib + +PATCHES=( + "${FILESDIR}/${PN}-0.22.2-no-static.patch" +) + +src_prepare() { + default + tc-export CC +} + +src_compile() { + emake \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + STRIP="" # bug 930020 +} + +src_install() { + emake DESTDIR="${D}" \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + install +} + +pkg_postinst() { + optfeature "building and testing grammars" dev-util/tree-sitter-cli +} diff --git a/sdk_container/src/third_party/portage-stable/dev-python/chardet/Manifest b/sdk_container/src/third_party/portage-stable/dev-python/chardet/Manifest new file mode 100644 index 00000000000..41980181b32 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/chardet/Manifest @@ -0,0 +1 @@ +DIST chardet-5.2.0.gh.tar.gz 2067352 BLAKE2B e9b960bad6ad7e9933f0fcd6e445bdefdd795f6150bf96e59714bfb9bd0cf63adeba80b608a1890f07be81565c160977fa96140984720407d93b0919eeb71a8b SHA512 3c6614882b251e53322eb75fdd01c3d7664c5f611bbfc1480fa10d57f02906b4be42a8b7ff4d3bdc00465340a2ca46b31f1f0d25f64d4f69df0ac0876e71e87f diff --git a/sdk_container/src/third_party/portage-stable/dev-python/chardet/chardet-5.2.0.ebuild b/sdk_container/src/third_party/portage-stable/dev-python/chardet/chardet-5.2.0.ebuild new file mode 100644 index 00000000000..32f4b0a8a7f --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/chardet/chardet-5.2.0.ebuild @@ -0,0 +1,31 @@ +# 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_{10..13} pypy3 ) + +inherit distutils-r1 + +DESCRIPTION="Universal encoding detector" +HOMEPAGE=" + https://github.com/chardet/chardet/ + https://pypi.org/project/chardet/ +" +SRC_URI=" + https://github.com/chardet/chardet/archive/${PV}.tar.gz + -> ${P}.gh.tar.gz +" + +LICENSE="LGPL-2.1" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~x64-macos ~x64-solaris" + +distutils_enable_tests pytest + +EPYTEST_DESELECT=( + # super flaky test + # https://github.com/chardet/chardet/issues/256 + test.py::test_detect_all_and_detect_one_should_agree +) diff --git a/sdk_container/src/third_party/portage-stable/dev-python/chardet/metadata.xml b/sdk_container/src/third_party/portage-stable/dev-python/chardet/metadata.xml new file mode 100644 index 00000000000..daa4b52ebf5 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/chardet/metadata.xml @@ -0,0 +1,13 @@ + + + + + python@gentoo.org + Python + + + + chardet + chardet/chardet + + diff --git a/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/Manifest b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/Manifest new file mode 100644 index 00000000000..2cbbb592013 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/Manifest @@ -0,0 +1,9 @@ +DIST tree-sitter-0.21.3.gh.tar.gz 38504 BLAKE2B dd8ed0047763d92babbdb3fd34a6fe6b7a9299b99067600f473bf16b9754a98ada141d96f9b6b26abcb2ff178dd4ec34da547c9cdb7b3449f7b98a44ad10476e SHA512 61f3d4cb15a4106eb350be2adc6ad39de31bd5b2656f35acf2cdf828ababac37b6197d5565ee74b0b2c3a161619163bb98c38108ca3db616fee633e6e2a835a7 +DIST tree-sitter-0.22.3.gh.tar.gz 164914 BLAKE2B 7ab97203fed17fc8d18c40d5a24ff60cea4757353a4124c832cc52bff93ed8af913dbbab682225eac309762a26e90c216d2e1058dcaeb860ebd467b4c9655939 SHA512 8ac729b90f942eef07de97c4ebd070c1040f338c1f57a2203b6aa4f3f8db863fdb5183c9b27d5be2ec270d7eefba7665800d6cc4e9265cbd4b4715af4c4d3921 +DIST tree-sitter-0.23.0.gh.tar.gz 167761 BLAKE2B 694e90f608f51fe4f9add476cd5ebcd0ce04a7b027efc4948ce49a6cc0f05ebf4f15e0fe3f365f89f3e04cfec542cb3f1db1e5b05ff7ca23d3134561ea3dcf36 SHA512 67a6f3359c6283c58afcdbe5b6a521cdfcf2585a5361fb69a55eff82941726a143528a402e6d609286d8846c77e20d0a38551525d761e35abb21045ad9c5a2f8 +DIST tree-sitter-embedded-template-6d791b897ecda59baa0689a85a9906348a2a6414.tar.gz 12420 BLAKE2B 9b9c6dd135cef4490e145657c5eeeb1fd470faee3846007638d8247daf07227029c6e7e323a0ed30c5cf6d35602be6bfb62dc1c22076fd4a0e76b161d55cca38 SHA512 7744852711cb1659607298fa373ce3ef79de3212ff55c0fb4e9aebcb715548934065ee3b5b12e9d08169a6207879e154a94c9de8bff892c32729c35d49964736 +DIST tree-sitter-html-b5d9758e22b4d3d25704b72526670759a9e4d195.tar.gz 26609 BLAKE2B 223fe82ea18bf61b2b7ec664ad68ec1f324c9e0a1c78578db6063b9037c62be2bb762a9e47d0af81f7f244889f1f72683da3751c1d1c609c4a27fdcd0dc008b8 SHA512 15fd961c18d55a20487f48ef6a6f1822f9033baba8995f2e00cf8db1750036d69e19607f578fe90676aab30a173874969c69b91605b6073eb298f32f5f24f81d +DIST tree-sitter-javascript-de1e682289a417354df5b4437a3e4f92e0722a0f.tar.gz 396570 BLAKE2B d80cecb070bd1c82737ee1d38fff293ac4c96fde02563ecc910d30c920b902bd5c25a7ac50585f8cb7a26203d98f4a9e6feeebd4ac0d54bede9486ff642e03be SHA512 4a509a886ebeae0d960360113aff89fb56090f1fe4bb5a7866952736a04838a8b6421cc7d19473acc48b135bca4615325c59c0f0f7f3734f23a78fff9cc2050e +DIST tree-sitter-json-3b129203f4b72d532f58e72c5310c0a7db3b8e6d.tar.gz 15580 BLAKE2B d31b38f959fed785e8f26782e7de3da94502cd3c65de2caf4ad0621287d80e95dcc317b4f224461fa70b59f7a8ca933a235bdffbbcc1d9ca8d7cc0b31b3b2862 SHA512 90dd3e757d384d1b95cec892c5b465a0413ba61df35669fd7afc47037596c8d6b72b4f0fd9a39512ebda0d5d078ce7a408455ae11e535591e1515740cdcf9f6f +DIST tree-sitter-python-03e88c170cb23142559a406b6e7621c4af3128f5.tar.gz 272632 BLAKE2B 72f2e7f48456bad7b495605171c1c5ed3aa2790e832a4bc152ef522ee2ce210a922f7d38ad1154c58a8c621f81739071ab3404135dbb79a12ba28ca7c97ff3c7 SHA512 7ed72e6ad464935423aaca1a829c51eefd4a4b5651eeda4b7f1ed2a67ec4088f17267796872a1e1cf5666fc8a920c2b1763a9cb4cd82924ee7214e01d7fe8ab8 +DIST tree-sitter-rust-3a56481f8d13b6874a28752502a58520b9139dc7.tar.gz 419237 BLAKE2B 681b9656c872bcd15abbf11923d07df61b80b36b2972461a29f249dc53915e6d18a6dfdc65d71c863f7b38a27c8b3a47376f590d86afa44caa71f103e710fed5 SHA512 a8ce10080b984aa469d952ff8e862165676e10dc30c3d1762f7141d9fe83734aec3cb92c48552cb8f24575b538dd53fe0a80f1337f5d0d4c8767dd6bf564143e diff --git a/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/files/tree-sitter-0.21.0-unbundle.patch b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/files/tree-sitter-0.21.0-unbundle.patch new file mode 100644 index 00000000000..69b50897d3a --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/files/tree-sitter-0.21.0-unbundle.patch @@ -0,0 +1,17 @@ +--- a/setup.py ++++ b/setup.py +@@ -14,13 +14,9 @@ setup( + Extension( + name="tree_sitter._binding", + sources=[ +- "tree_sitter/core/lib/src/lib.c", + "tree_sitter/binding.c" + ], +- include_dirs=[ +- "tree_sitter/core/lib/include", +- "tree_sitter/core/lib/src" +- ], ++ libraries=["tree-sitter"], + define_macros=[ + ("PY_SSIZE_T_CLEAN", None), + ], diff --git a/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/files/tree-sitter-0.22.2-unbundle.patch b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/files/tree-sitter-0.22.2-unbundle.patch new file mode 100644 index 00000000000..d919b1abf00 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/files/tree-sitter-0.22.2-unbundle.patch @@ -0,0 +1,23 @@ +diff --git a/setup.py b/setup.py +index 77ea76a..ab22ad3 100644 +--- a/setup.py ++++ b/setup.py +@@ -12,7 +12,6 @@ setup( + Extension( + name="tree_sitter._binding", + sources=[ +- "tree_sitter/core/lib/src/lib.c", + "tree_sitter/binding/language.c", + "tree_sitter/binding/lookahead_iterator.c", + "tree_sitter/binding/lookahead_names_iterator.c", +@@ -26,9 +25,8 @@ setup( + ], + include_dirs=[ + "tree_sitter/binding", +- "tree_sitter/core/lib/include", +- "tree_sitter/core/lib/src", + ], ++ libraries=["tree-sitter"], + define_macros=[ + ("PY_SSIZE_T_CLEAN", None), + ("TREE_SITTER_HIDE_SYMBOLS", None), diff --git a/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/metadata.xml b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/metadata.xml new file mode 100644 index 00000000000..c5c088fef8e --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/metadata.xml @@ -0,0 +1,16 @@ + + + + + python@gentoo.org + Python + + + pkgcore@gentoo.org + Pkgcore + + + tree-sitter + tree-sitter/py-tree-sitter + + diff --git a/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/tree-sitter-0.21.3.ebuild b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/tree-sitter-0.21.3.ebuild new file mode 100644 index 00000000000..b703b3349a5 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/tree-sitter-0.21.3.ebuild @@ -0,0 +1,75 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_EXT=1 +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{10..12} ) + +inherit distutils-r1 + +# Use the versions from the submodules under "tests/fixtures/" +declare -A TEST_FIXTURES=( + ["embedded-template"]="6d791b897ecda59baa0689a85a9906348a2a6414" + ["html"]="b5d9758e22b4d3d25704b72526670759a9e4d195" + ["javascript"]="de1e682289a417354df5b4437a3e4f92e0722a0f" + ["json"]="3b129203f4b72d532f58e72c5310c0a7db3b8e6d" + ["python"]="03e88c170cb23142559a406b6e7621c4af3128f5" + ["rust"]="3a56481f8d13b6874a28752502a58520b9139dc7" +) + +DESCRIPTION="Python bindings to the Tree-sitter parsing library" +HOMEPAGE=" + https://github.com/tree-sitter/py-tree-sitter/ + https://pypi.org/project/tree-sitter/ +" +SRC_URI=" + https://github.com/tree-sitter/py-tree-sitter/archive/v${PV}.tar.gz + -> ${P}.gh.tar.gz +" +SRC_URI+=" test? (" +for fixture in "${!TEST_FIXTURES[@]}" ; do + SRC_URI+=" + https://github.com/tree-sitter/tree-sitter-${fixture}/archive/${TEST_FIXTURES[${fixture}]}.tar.gz + -> tree-sitter-${fixture}-${TEST_FIXTURES[${fixture}]}.tar.gz + " +done +SRC_URI+=" )" +S=${WORKDIR}/py-${P} + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" + +# setuptools is needed for distutils import +DEPEND=">=dev-libs/tree-sitter-0.22.1:=" +RDEPEND="${DEPEND} + $(python_gen_cond_dep ' + dev-python/setuptools[${PYTHON_USEDEP}] + ' 3.12) +" + +distutils_enable_tests pytest + +PATCHES=( + "${FILESDIR}"/tree-sitter-0.21.0-unbundle.patch +) + +src_unpack() { + default + rmdir "${S}/tree_sitter/core" || die + + if use test; then + mkdir -p "${S}/tests/fixtures" || die + local fixture + for fixture in "${!TEST_FIXTURES[@]}" ; do + mv -T "tree-sitter-${fixture}-${TEST_FIXTURES[${fixture}]}" "${S}/tests/fixtures/tree-sitter-${fixture}" || die + done + fi +} + +src_test() { + rm -r tree_sitter || die + distutils-r1_src_test +} diff --git a/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/tree-sitter-0.22.3-r2.ebuild b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/tree-sitter-0.22.3-r2.ebuild new file mode 100644 index 00000000000..b1aa4f8a573 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/tree-sitter-0.22.3-r2.ebuild @@ -0,0 +1,58 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_EXT=1 +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{10..13} ) + +inherit distutils-r1 + +DESCRIPTION="Python bindings to the Tree-sitter parsing library" +HOMEPAGE=" + https://github.com/tree-sitter/py-tree-sitter/ + https://pypi.org/project/tree-sitter/ +" +SRC_URI=" + https://github.com/tree-sitter/py-tree-sitter/archive/v${PV}.tar.gz + -> ${P}.gh.tar.gz +" +S=${WORKDIR}/py-${P} + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86" + +# setuptools is needed for distutils import +DEPEND=">=dev-libs/tree-sitter-0.22.1:=" +RDEPEND="${DEPEND} + $(python_gen_cond_dep ' + dev-python/setuptools[${PYTHON_USEDEP}] + ' 3.12) +" +BDEPEND=" + test? ( + >=dev-libs/tree-sitter-html-0.20.3[python,${PYTHON_USEDEP}] + >=dev-libs/tree-sitter-javascript-0.21.0[python,${PYTHON_USEDEP}] + >=dev-libs/tree-sitter-json-0.20.3[python,${PYTHON_USEDEP}] + >=dev-libs/tree-sitter-python-0.21.0[python,${PYTHON_USEDEP}] + >=dev-libs/tree-sitter-rust-0.21.2[python,${PYTHON_USEDEP}] + ) +" + +distutils_enable_tests pytest + +PATCHES=( + "${FILESDIR}"/${PN}-0.22.2-unbundle.patch +) + +src_unpack() { + default + rmdir "${S}/tree_sitter/core" || die +} + +src_test() { + rm -r tree_sitter || die + distutils-r1_src_test +} diff --git a/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/tree-sitter-0.23.0.ebuild b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/tree-sitter-0.23.0.ebuild new file mode 100644 index 00000000000..e92fdc14a47 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-python/tree-sitter/tree-sitter-0.23.0.ebuild @@ -0,0 +1,64 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_EXT=1 +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{10..13} ) + +inherit distutils-r1 + +DESCRIPTION="Python bindings to the Tree-sitter parsing library" +HOMEPAGE=" + https://github.com/tree-sitter/py-tree-sitter/ + https://pypi.org/project/tree-sitter/ +" +SRC_URI=" + https://github.com/tree-sitter/py-tree-sitter/archive/v${PV}.tar.gz + -> ${P}.gh.tar.gz +" +S=${WORKDIR}/py-${P} + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" + +# setuptools is needed for distutils import +DEPEND=">=dev-libs/tree-sitter-0.23.0:=" +RDEPEND="${DEPEND} + $(python_gen_cond_dep ' + dev-python/setuptools[${PYTHON_USEDEP}] + ' 3.12) +" +BDEPEND=" + test? ( + >=dev-libs/tree-sitter-html-0.20.4[python,${PYTHON_USEDEP}] + >=dev-libs/tree-sitter-javascript-0.21.0[python,${PYTHON_USEDEP}] + >=dev-libs/tree-sitter-json-0.20.3[python,${PYTHON_USEDEP}] + >=dev-libs/tree-sitter-python-0.23.0[python,${PYTHON_USEDEP}] + >=dev-libs/tree-sitter-rust-0.21.2[python,${PYTHON_USEDEP}] + ) +" + +distutils_enable_tests pytest + +PATCHES=( + "${FILESDIR}"/${PN}-0.22.2-unbundle.patch +) + +src_unpack() { + default + rmdir "${S}/tree_sitter/core" || die +} + +src_prepare() { + default + + sed -i tree_sitter/binding/query.c -e 's/_PyErr_FormatFromCause/PyErr_Format/' || die +} + +src_test() { + rm -r tree_sitter || die + distutils-r1_src_test +} diff --git a/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/Manifest b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/Manifest new file mode 100644 index 00000000000..bb1c849d1c2 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/Manifest @@ -0,0 +1,2 @@ +DIST pkgcheck-0.10.29.tar.gz 377521 BLAKE2B 91a1a25e6ef173582fc9082b92baa66489fd43c7addfbdd8516b5ea93febbb92b7155de88283ae4a1bb09047a44336ab5c336c5d0808c915eab99e8aa4461576 SHA512 339e332db24ffd716b658a40c66f2a90c6905071827da84ce0d633d882d75cf41bb853725ca30fe2abc8d7535f546925aedc8853fa7f1737854cee251a0ec3ab +DIST pkgcheck-0.10.30.tar.gz 378098 BLAKE2B f80224d707f7656ca45f58932936e1ce780d670be596312532b88940fbe1cfb1c7e14a877a955fc4f21fb003a2ee5c6095c2c6919475cdc95db9be0736050b50 SHA512 078ba2275e39e645eca22a265c9f06c6dd7d1cb310979ab5e48bb86a374b42edc50c0ca8d0bd671a3b51341b7fae80ff2c9adf2dc2eeabd93a545c84373902b4 diff --git a/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/files/50pkgcheck-gentoo.el b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/files/50pkgcheck-gentoo.el new file mode 100644 index 00000000000..003b67dfa9a --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/files/50pkgcheck-gentoo.el @@ -0,0 +1,3 @@ +(add-to-list 'load-path "@SITELISP@") +(autoload 'flycheck-pkgcheck-setup "flycheck-pkgcheck" + "Flycheck pkgcheck setup." t) diff --git a/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/metadata.xml b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/metadata.xml new file mode 100644 index 00000000000..46192ec8425 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/metadata.xml @@ -0,0 +1,14 @@ + + + + + pkgcore@gentoo.org + Pkgcore + + + + proj/pkgcore/pkgcheck + pkgcore/pkgcheck + pkgcheck + + diff --git a/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/pkgcheck-0.10.29-r1.ebuild b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/pkgcheck-0.10.29-r1.ebuild new file mode 100644 index 00000000000..18fafd3a06e --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/pkgcheck-0.10.29-r1.ebuild @@ -0,0 +1,94 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=standalone +PYTHON_COMPAT=( python3_{10..12} ) +inherit elisp-common distutils-r1 optfeature + +if [[ ${PV} == *9999 ]] ; then + EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/pkgcore/pkgcheck.git + https://github.com/pkgcore/pkgcheck.git" + inherit git-r3 +else + KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" + inherit pypi +fi + +DESCRIPTION="pkgcore-based QA utility for ebuild repos" +HOMEPAGE="https://github.com/pkgcore/pkgcheck" + +LICENSE="BSD MIT" +SLOT="0" +IUSE="emacs" + +if [[ ${PV} == *9999 ]]; then + RDEPEND=" + ~dev-python/snakeoil-9999[${PYTHON_USEDEP}] + ~sys-apps/pkgcore-9999[${PYTHON_USEDEP}]" +else + RDEPEND=" + >=dev-python/snakeoil-0.10.7[${PYTHON_USEDEP}] + >=sys-apps/pkgcore-0.12.25[${PYTHON_USEDEP}]" +fi +RDEPEND+=" + >=dev-libs/tree-sitter-bash-0.21.0[python,${PYTHON_USEDEP}] + dev-python/chardet[${PYTHON_USEDEP}] + dev-python/lazy-object-proxy[${PYTHON_USEDEP}] + dev-python/lxml[${PYTHON_USEDEP}] + dev-python/pathspec[${PYTHON_USEDEP}] + >=dev-python/tree-sitter-0.21.0[${PYTHON_USEDEP}] + =app-editors/emacs-24.1:* + app-emacs/ebuild-mode + app-emacs/flycheck + ) +" +BDEPEND="${RDEPEND} + >=dev-python/flit-core-3.8[${PYTHON_USEDEP}] + test? ( + dev-python/pytest[${PYTHON_USEDEP}] + dev-python/requests[${PYTHON_USEDEP}] + dev-vcs/git + ) +" + +SITEFILE="50${PN}-gentoo.el" + +distutils_enable_tests pytest + +export USE_SYSTEM_TREE_SITTER_BASH=1 + +src_compile() { + distutils-r1_src_compile + + if use emacs ; then + pushd "${S}"/contrib/emacs >/dev/null || die + elisp-compile *.el + popd >/dev/null || die + fi +} + +python_install_all() { + local DOCS=( NEWS.rst ) + [[ ${PV} == *9999 ]] || doman build/sphinx/man/* + distutils-r1_python_install_all + + if use emacs ; then + elisp-install ${PN} "${S}"/contrib/emacs/*.el{,c} + elisp-site-file-install "${FILESDIR}/${SITEFILE}" + fi +} + +pkg_postinst() { + use emacs && elisp-site-regen + + optfeature "Network check support" dev-python/requests + optfeature "Perl module version check support" dev-perl/Gentoo-PerlMod-Version +} + +pkg_postrm() { + use emacs && elisp-site-regen +} diff --git a/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/pkgcheck-0.10.30-r1.ebuild b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/pkgcheck-0.10.30-r1.ebuild new file mode 100644 index 00000000000..012ec9c2756 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/pkgcheck-0.10.30-r1.ebuild @@ -0,0 +1,94 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=standalone +PYTHON_COMPAT=( python3_{10..13} ) +inherit elisp-common distutils-r1 optfeature + +if [[ ${PV} == *9999 ]] ; then + EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/pkgcore/pkgcheck.git + https://github.com/pkgcore/pkgcheck.git" + inherit git-r3 +else + KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86" + inherit pypi +fi + +DESCRIPTION="pkgcore-based QA utility for ebuild repos" +HOMEPAGE="https://github.com/pkgcore/pkgcheck" + +LICENSE="BSD MIT" +SLOT="0" +IUSE="emacs" + +if [[ ${PV} == *9999 ]]; then + RDEPEND=" + ~dev-python/snakeoil-9999[${PYTHON_USEDEP}] + ~sys-apps/pkgcore-9999[${PYTHON_USEDEP}]" +else + RDEPEND=" + >=dev-python/snakeoil-0.10.8[${PYTHON_USEDEP}] + >=sys-apps/pkgcore-0.12.25[${PYTHON_USEDEP}]" +fi +RDEPEND+=" + >=dev-libs/tree-sitter-bash-0.21.0[python,${PYTHON_USEDEP}] + dev-python/chardet[${PYTHON_USEDEP}] + dev-python/lazy-object-proxy[${PYTHON_USEDEP}] + dev-python/lxml[${PYTHON_USEDEP}] + dev-python/pathspec[${PYTHON_USEDEP}] + >=dev-python/tree-sitter-0.22.0[${PYTHON_USEDEP}] + =app-editors/emacs-24.1:* + app-emacs/ebuild-mode + app-emacs/flycheck + ) +" +BDEPEND="${RDEPEND} + >=dev-python/flit-core-3.8[${PYTHON_USEDEP}] + test? ( + dev-python/pytest[${PYTHON_USEDEP}] + dev-python/requests[${PYTHON_USEDEP}] + dev-vcs/git + ) +" + +SITEFILE="50${PN}-gentoo.el" + +distutils_enable_tests pytest + +export USE_SYSTEM_TREE_SITTER_BASH=1 + +src_compile() { + distutils-r1_src_compile + + if use emacs ; then + pushd "${S}"/contrib/emacs >/dev/null || die + elisp-compile *.el + popd >/dev/null || die + fi +} + +python_install_all() { + local DOCS=( NEWS.rst ) + [[ ${PV} == *9999 ]] || doman build/sphinx/man/* + distutils-r1_python_install_all + + if use emacs ; then + elisp-install ${PN} "${S}"/contrib/emacs/*.el{,c} + elisp-site-file-install "${FILESDIR}/${SITEFILE}" + fi +} + +pkg_postinst() { + use emacs && elisp-site-regen + + optfeature "Network check support" dev-python/requests + optfeature "Perl module version check support" dev-perl/Gentoo-PerlMod-Version +} + +pkg_postrm() { + use emacs && elisp-site-regen +} diff --git a/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/pkgcheck-9999.ebuild b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/pkgcheck-9999.ebuild new file mode 100644 index 00000000000..82e8c427e40 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/dev-util/pkgcheck/pkgcheck-9999.ebuild @@ -0,0 +1,93 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=standalone +PYTHON_COMPAT=( python3_{10..13} ) +inherit elisp-common distutils-r1 optfeature + +if [[ ${PV} == *9999 ]] ; then + EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/pkgcore/pkgcheck.git + https://github.com/pkgcore/pkgcheck.git" + inherit git-r3 +else + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" + inherit pypi +fi + +DESCRIPTION="pkgcore-based QA utility for ebuild repos" +HOMEPAGE="https://github.com/pkgcore/pkgcheck" + +LICENSE="BSD MIT" +SLOT="0" +IUSE="emacs" + +if [[ ${PV} == *9999 ]]; then + RDEPEND=" + ~dev-python/snakeoil-9999[${PYTHON_USEDEP}] + ~sys-apps/pkgcore-9999[${PYTHON_USEDEP}]" +else + RDEPEND=" + >=dev-python/snakeoil-0.10.8[${PYTHON_USEDEP}] + >=sys-apps/pkgcore-0.12.25[${PYTHON_USEDEP}]" +fi +RDEPEND+=" + >=dev-libs/tree-sitter-bash-0.21.0[python,${PYTHON_USEDEP}] + dev-python/chardet[${PYTHON_USEDEP}] + dev-python/lazy-object-proxy[${PYTHON_USEDEP}] + dev-python/lxml[${PYTHON_USEDEP}] + dev-python/pathspec[${PYTHON_USEDEP}] + >=dev-python/tree-sitter-0.23.0[${PYTHON_USEDEP}] + emacs? ( + >=app-editors/emacs-24.1:* + app-emacs/ebuild-mode + app-emacs/flycheck + ) +" +BDEPEND="${RDEPEND} + >=dev-python/flit-core-3.8[${PYTHON_USEDEP}] + test? ( + dev-python/pytest[${PYTHON_USEDEP}] + dev-python/requests[${PYTHON_USEDEP}] + dev-vcs/git + ) +" + +SITEFILE="50${PN}-gentoo.el" + +distutils_enable_tests pytest + +export USE_SYSTEM_TREE_SITTER_BASH=1 + +src_compile() { + distutils-r1_src_compile + + if use emacs ; then + pushd "${S}"/contrib/emacs >/dev/null || die + elisp-compile *.el + popd >/dev/null || die + fi +} + +python_install_all() { + local DOCS=( NEWS.rst ) + [[ ${PV} == *9999 ]] || doman build/sphinx/man/* + distutils-r1_python_install_all + + if use emacs ; then + elisp-install ${PN} "${S}"/contrib/emacs/*.el{,c} + elisp-site-file-install "${FILESDIR}/${SITEFILE}" + fi +} + +pkg_postinst() { + use emacs && elisp-site-regen + + optfeature "Network check support" dev-python/requests + optfeature "Perl module version check support" dev-perl/Gentoo-PerlMod-Version +} + +pkg_postrm() { + use emacs && elisp-site-regen +} diff --git a/sdk_container/src/third_party/portage-stable/eclass/tree-sitter-grammar.eclass b/sdk_container/src/third_party/portage-stable/eclass/tree-sitter-grammar.eclass new file mode 100644 index 00000000000..10f29b8a083 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/eclass/tree-sitter-grammar.eclass @@ -0,0 +1,224 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# @ECLASS: tree-sitter-grammar.eclass +# @MAINTAINER: +# Matthew Smith +# Arthur Zamarin +# @AUTHOR: +# Matthew Smith +# @SUPPORTED_EAPIS: 8 +# @BLURB: Common functions and variables for Tree Sitter grammars + +case ${EAPI} in + 8) ;; + *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;; +esac + +if [[ -z ${_TREE_SITTER_GRAMMAR_ECLASS} ]]; then +_TREE_SITTER_GRAMMAR_ECLASS=1 + +inherit edo multilib toolchain-funcs + +SRC_URI="https://github.com/tree-sitter/${PN}/archive/${TS_PV:-v${PV}}.tar.gz + -> ${P}.tar.gz" +S="${WORKDIR}"/${PN}-${TS_PV:-${PV}} + +BDEPEND+=" test? ( dev-util/tree-sitter-cli )" +IUSE+=" test" +RESTRICT+=" !test? ( test )" + +# @ECLASS_VARIABLE: TS_PV +# @PRE_INHERIT +# @DEFAULT_UNSET +# @DESCRIPTION: +# Used to override upstream tag name if tagged differently, e.g. most releases +# are v${PV} but some are tagged as rust-${PV}. + +# @ECLASS_VARIABLE: TS_BINDINGS +# @PRE_INHERIT +# @DEFAULT_UNSET +# @DESCRIPTION: +# Array of bindings language to build. Currently only "python" is supported. + +for _BINDING in "${TS_BINDINGS[@]}"; do + case ${_BINDING} in + python) + DISTUTILS_EXT=1 + DISTUTILS_OPTIONAL=1 + DISTUTILS_USE_PEP517=setuptools + PYTHON_COMPAT=( python3_{10..13} ) + inherit distutils-r1 + + IUSE+=" python" + REQUIRED_USE+=" python? ( ${PYTHON_REQUIRED_USE} )" + + DEPEND+=" python? ( + ${PYTHON_DEPS} + )" + RDEPEND+=" python? ( + ${PYTHON_DEPS} + >=dev-python/tree-sitter-0.21.0[${PYTHON_USEDEP}] + )" + BDEPEND+=" python? ( + ${PYTHON_DEPS} + ${DISTUTILS_DEPS} + dev-python/wheel[${PYTHON_USEDEP}] + )" + ;; + *) + die "Unknown binding: ${_BINDING}" + ;; + esac +done +unset _BINDING + +# @FUNCTION: _get_tsg_abi_ver +# @INTERNAL +# @DESCRIPTION: +# This internal function determines the ABI version of a grammar library based +# on a constant in the source file. +_get_tsg_abi_ver() { + # This sed script finds ABI definition string in parser source file, + # substitutes all the string until the ABI number, and prints remains + # (the ABI number itself) + sed -n 's/#define LANGUAGE_VERSION //p' "${S}"/src/parser.c || + die "Unable to extract ABI version for this grammar" +} + +tree-sitter-grammar_src_prepare() { + debug-print-function ${FUNCNAME} "${@}" + + default + + local binding + for binding in "${TS_BINDINGS[@]}"; do + case ${binding} in + python) + use python && distutils-r1_src_prepare + ;; + esac + done +} + +tree-sitter-grammar_src_configure() { + debug-print-function ${FUNCNAME} "${@}" + + local binding + for binding in "${TS_BINDINGS[@]}"; do + case ${binding} in + python) + use python && distutils-r1_src_configure + ;; + esac + done +} + +# @FUNCTION: _tree-sitter-grammar_legacy_compile +# @INTERNAL +# @DESCRIPTION: +# Compiles the Tree Sitter parser as a shared library, the legacy way. +_tree-sitter-grammar_legacy_compile() { + cd "${S}/src" || die + + # Grammars always contain parser.c, and sometimes a scanner.c, + # or scanner.cc. + + tc-export CC CXX + # We want to use the bundled parser.h, not anything lurking on the system, hence -I + # See https://github.com/tree-sitter/tree-sitter-bash/issues/199#issuecomment-1694416505 + local -x CFLAGS="${CFLAGS} -fPIC -I. -Itree_sitter" + local -x CXXFLAGS="${CXXFLAGS} -fPIC -I. -Itree_sitter" + + local objects=( parser.o ) + if [[ -f "${S}"/src/scanner.c || -f "${S}"/src/scanner.cc ]]; then + objects+=( scanner.o ) + fi + emake "${objects[@]}" + + local link="$(tc-getCC) ${CFLAGS}" + if [[ -f "${S}/src/scanner.cc" ]]; then + link="$(tc-getCXX) ${CXXFLAGS}" + fi + + local soname=lib${PN}$(get_libname $(_get_tsg_abi_ver)) + + local soname_args="-Wl,--soname=${soname}" + if [[ ${CHOST} == *darwin* ]] ; then + soname_args="-Wl,-install_name,${EPREFIX}/usr/$(get_libdir)/${soname}" + fi + + edo ${link} ${LDFLAGS} \ + -shared \ + *.o \ + "${soname_args}" \ + -o "${WORKDIR}"/${soname} +} + +tree-sitter-grammar_src_compile() { + debug-print-function ${FUNCNAME} "${@}" + + # legacy grammars don't have a pyproject.toml + if [[ -f "${S}/pyproject.toml" ]]; then + sed -e "/SONAME_MINOR :=/s/:=.*$/:= $(_get_tsg_abi_ver)/" -i "${S}/Makefile" || die + emake \ + CC="$(tc-getCC)" \ + AR="$(tc-getAR)" \ + STRIP="" \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" + else + _tree-sitter-grammar_legacy_compile + fi + + local binding + for binding in "${TS_BINDINGS[@]}"; do + case ${binding} in + python) + use python && distutils-r1_src_compile + ;; + esac + done +} + +# @FUNCTION: tree-sitter-grammar_src_test +# @DESCRIPTION: +# Runs the Tree Sitter parser's test suite. +# See: https://tree-sitter.github.io/tree-sitter/creating-parsers#command-test +tree-sitter-grammar_src_test() { + debug-print-function ${FUNCNAME} "${@}" + + tree-sitter test || die "Test suite failed" +} + +tree-sitter-grammar_src_install() { + debug-print-function ${FUNCNAME} "${@}" + + # legacy grammars don't have a pyproject.toml + if [[ -f "${S}/pyproject.toml" ]]; then + emake \ + PREFIX="${EPREFIX}/usr" \ + LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ + DESTDIR="${D}/" \ + install + find "${D}" -name '*.a' -delete || die "failed to remove static libraries" + else + local soname=lib${PN}$(get_libname $(_get_tsg_abi_ver)) + + dolib.so "${WORKDIR}/${soname}" + dosym "${soname}" /usr/$(get_libdir)/lib${PN}$(get_libname) + fi + + local binding + for binding in "${TS_BINDINGS[@]}"; do + case ${binding} in + python) + use python && distutils-r1_src_install + ;; + esac + done +} + +fi + +EXPORT_FUNCTIONS src_prepare src_configure src_compile src_test src_install diff --git a/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/Manifest b/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/Manifest new file mode 100644 index 00000000000..f00e95f74c6 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/Manifest @@ -0,0 +1 @@ +DIST pkgcore-0.12.27.tar.gz 636436 BLAKE2B a03b795eb685b552659b6110a9a19e6915320f3bcc87a4c5343a9ae16b82ebea46b538d8606ff10fa1f1c46f85117aeec240247e98aaccc00b0c67996bd2421a SHA512 99e8e125fbb086a98f6c2f494624e63d47d2f594f952eb5e540eba355161eecaeb55ffc3f2df951cdfcd9cb5b1720411c58e2ab4f3299a63eeafa44eed6f7912 diff --git a/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/metadata.xml b/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/metadata.xml new file mode 100644 index 00000000000..b9caf9ee0c8 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/metadata.xml @@ -0,0 +1,13 @@ + + + + + pkgcore@gentoo.org + Pkgcore + + + + pkgcore/pkgcore + pkgcore + + diff --git a/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/pkgcore-0.12.27.ebuild b/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/pkgcore-0.12.27.ebuild new file mode 100644 index 00000000000..4311b3b61a4 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/pkgcore-0.12.27.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=standalone +PYTHON_COMPAT=( python3_{10..13} ) +inherit distutils-r1 + +if [[ ${PV} == *9999 ]] ; then + EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/pkgcore/pkgcore.git + https://github.com/pkgcore/pkgcore.git" + inherit git-r3 +else + KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x64-macos" + inherit pypi +fi + +DESCRIPTION="a framework for package management" +HOMEPAGE="https://github.com/pkgcore/pkgcore" + +LICENSE="BSD MIT" +SLOT="0" + +if [[ ${PV} == *9999 ]]; then + COMMON_DEPEND="~dev-python/snakeoil-9999[${PYTHON_USEDEP}]" +else + COMMON_DEPEND=">=dev-python/snakeoil-0.10.7[${PYTHON_USEDEP}]" +fi + +RDEPEND=" + ${COMMON_DEPEND} + >=app-shells/bash-5.1[readline] + dev-python/lxml[${PYTHON_USEDEP}] +" +BDEPEND=" + ${COMMON_DEPEND} + >=dev-python/flit-core-3.8[${PYTHON_USEDEP}] + test? ( + dev-vcs/git + ) +" + +distutils_enable_tests pytest + +python_install_all() { + local DOCS=( NEWS.rst ) + [[ ${PV} == *9999 ]] || doman build/sphinx/man/* + distutils-r1_python_install_all +} diff --git a/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/pkgcore-9999.ebuild b/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/pkgcore-9999.ebuild new file mode 100644 index 00000000000..1dc106e9393 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/sys-apps/pkgcore/pkgcore-9999.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=standalone +PYTHON_COMPAT=( python3_{10..13} ) +inherit distutils-r1 + +if [[ ${PV} == *9999 ]] ; then + EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/pkgcore/pkgcore.git + https://github.com/pkgcore/pkgcore.git" + inherit git-r3 +else + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" + inherit pypi +fi + +DESCRIPTION="a framework for package management" +HOMEPAGE="https://github.com/pkgcore/pkgcore" + +LICENSE="BSD MIT" +SLOT="0" + +if [[ ${PV} == *9999 ]]; then + COMMON_DEPEND="~dev-python/snakeoil-9999[${PYTHON_USEDEP}]" +else + COMMON_DEPEND=">=dev-python/snakeoil-0.10.7[${PYTHON_USEDEP}]" +fi + +RDEPEND=" + ${COMMON_DEPEND} + >=app-shells/bash-5.1[readline] + dev-python/lxml[${PYTHON_USEDEP}] +" +BDEPEND=" + ${COMMON_DEPEND} + >=dev-python/flit-core-3.8[${PYTHON_USEDEP}] + test? ( + dev-vcs/git + ) +" + +distutils_enable_tests pytest + +python_install_all() { + local DOCS=( NEWS.rst ) + [[ ${PV} == *9999 ]] || doman build/sphinx/man/* + distutils-r1_python_install_all +}