diff --git a/README.md b/README.md index 500cb1e59..bd18f659c 100644 --- a/README.md +++ b/README.md @@ -606,12 +606,12 @@ A daily compile test is run at Github with Python 3.9 to catch general faults. E ## Licenses This repository itself is released under GPL-3 (like most Gentoo repositories), all work on the depending components under the licenses they came from. Perhaps you came here because I filed an issue at your component about a bad or missing license. It is easy to [assign a license](https://docs.github.com/en/communities/setting-up-your-project-for-healthy-contributions/adding-a-license-to-a-repository). During cleanups and license investigations I have been asked often which license to choose. I am not a lawyer, but I can offer the following table, counted over this repository, perhaps this helps your decision. If a package has more than one license listed, all of them are counted. -There are 2375 Ebuilds in total, 2357 of them have in total 2401 (43 different) licenses assigned. +There are 2377 Ebuilds in total, 2359 of them have in total 2404 (43 different) licenses assigned. |License| Ebuilds using it| |-------|-----| -|MIT|1357| -|Apache-2.0|545| +|MIT|1358| +|Apache-2.0|547| |GPL-3|149| |BSD|125| |GPL-2|29| diff --git a/dev-python/uv/Manifest b/dev-python/uv/Manifest index d0be6938f..43468c5ff 100644 --- a/dev-python/uv/Manifest +++ b/dev-python/uv/Manifest @@ -1,14 +1,17 @@ AUX tokio-tar-0.3.1-ppc.patch 794 BLAKE2B 2c1188d96310710fabe8d248be01ab5e4d30aa02fe2b4f812a79a6c9440052178227534485122643bf4ed7f32ce3bfea289d78398c53229dd825eef44de6e164 SHA512 869d98ddd3eef7f8d9a7643ec5f93c73fed7bd4f1fb73b54a9e640293e831d24ca59bdd63377b07656ae706b5bf9833dd731b0537b43e8476d8cae0f3b8ab439 AUX uv-0.1.43-test.patch 582 BLAKE2B 247c4d5e31ac12d5da4063d0b696a993f5bf4175886209930313ff507ba9bfaf638581c2f290dfa5adc85a3bb360705977ebdcb0adb6a6196f4fbda1a0cb630e SHA512 88fddad804d9f4b042c207802ed6d7dbdaa6ee974635219b49e37d0e4a56644ca81d23afad08dde6f7bf90f2d202947d615d53eda6bb499c8b06b4661e858988 +DIST pubgrub-06ec5a5f59ffaeb6cf5079c6cb184467da06c9db.gh.tar.gz 99881 BLAKE2B 5fcc2d1a06eb44351773081de4f616c93301eb2fe71b0c6f7b95779ec4bd9bb6cccc702a87a6399b0674711302a19de3a96fa31044660430fd74ff549000ad25 SHA512 3f0b18aecbc73fee91fc7de9f10d240ddc06c836fa2f116c1f007dd7818d099e6aea1852ca0b8d1a26ac19aac896535dba1a6298851a65515b553810c6245784 DIST pubgrub-0e684a874c9fb8f74738cd8875524c80e3d4820b.gh.tar.gz 86899 BLAKE2B 51b8753a092deda12a35b501f34c16e800f2ed2c4c47b64622c752bcf8a52dd1fb9dc1ee69cd107b5b6ee48003c8ef804e20f7eed975a6e63615b94648e37890 SHA512 15e404590fb3b21b01fac318df9cbf81f598dc0506d6d5738ff566a5eb1075e6d7a096a8ad1567e27982662aac0ce2a889a0039ce5736ff140fa617ae8b3cb08 DIST pubgrub-388685a8711092971930986644cfed152d1a1f6c.gh.tar.gz 87945 BLAKE2B 7c10db2eff97656a379e8beff9f77bf09b4ab2fdd0d5c171e36babc6f3bff08d05774c55a51a23d79144c4110a942764cefa8a1baf7c36174809d2e648f2d12d SHA512 15539076de8fe9a459f70efcf07ccb7f61ced2be9832c4eb7123e7baa2bb85f3263fd4cb5d8b277c28a70ba316d5128d74d59d6f1de96b6e55ef04321a42c4dc DIST pubgrub-95e1390399cdddee986b658be19587eb1fdb2d79.gh.tar.gz 88127 BLAKE2B 661b639a7028b7dfe4967b4e2f187c3d403e1796bb09ae4606854414547cf81a5907d7dc9c1f8c3f6fe6986b1c8c22a89fee9e93d2ca79d5241350916991cf05 SHA512 8fdcd1ca1badbd140eb386ff37dd91b26d2b81273544b25a376462b900e9b84e59523ff75a68abe4a03834d72ee0d44246f16aea5c7e9091ad5375a86d3aee70 DIST pubgrub-9cd9049a64c7352de2ff3b525b9ae36421b0cc18.gh.tar.gz 95485 BLAKE2B 08db87c7bce1d6553e23fda3a4ab8d259d09ef50500846fbadae3c24841d7df0af40b052448d71f52196bb2da4ce0428ad9ad6c43dbede2910f39e602c168f6b SHA512 1ea397be9ecc236c275706c8bdd9c6f9baa9852fce30cdc7009bfeff43ecc745391c3aa75784f1a39bcc8d77b9687f028a494610af632ab6e8a9efbc88ad1653 DIST pubgrub-c26e485213e39582c6f2e4d45c0328422670e7a7.gh.tar.gz 86123 BLAKE2B 743bb61460903d276f467b23bb001313598b50cb54fd1a56bcadbc732dd606bafd48a2d9960add3424bd03222450b455f9f1bc8716a80933e5ed0cfb76dcc50a SHA512 9f9c8b58dd2ddeb3ed89abcd790641bd9b7b2cf4fc66dcc4d964a1b69d879adcdaf2775545631ca20f06a8ab5d6bc1df6b2eb272207d2642584c269b358f4d76 DIST reqwest-middleware-5e3eaf254b5bd481c75d2710eed055f95b756913.gh.tar.gz 40049 BLAKE2B d284947a108e2d3233a4fa7c9eb5e1a959bc5b569e754861daef076672672b0500cb737b85871d1fc0587bdbf6d5020e03e7c906cb5de34ff2f81c05b66918d1 SHA512 540a71e59a8b57e5e0bd7fad18fed265552bdae4518690a9823c94dcf23ee1d436f91b9cecf21129917b25e78b91d8d7290760edaea68053666e28af7223476e +DIST reqwest-middleware-ad8b9d332d1773fde8b4cd008486de5973e0a3f8.gh.tar.gz 41975 BLAKE2B db42a68b8f0d592edc297462c19a34caa068464b9a5f307e8e1c1fdacde95cd08c5af0f73fa55ed62217dee63940a1d02a4322c5edb2c2c8a568a7e04efd80e6 SHA512 2dad83835c87cdd79e2a08c19b5024b3fdf30d1d8cd14e480e434612e856ecc20a5404881ff81d5793d3e9d5808ee3d59ce920312a86a100535009da43d7d46b DIST reqwest-middleware-d95ec5a99fcc9a4339e1850d40378bbfe55ab121.gh.tar.gz 40815 BLAKE2B eb7edc4e4599635714b30e5a49b1ddf04e76a696618713320fbb06b240e5f77dafcba78e8532a7de3ada682773a65c88405a5bec2261a7da4310a7cc95b2554e SHA512 bc29f8e634cbfde9d89db3e7ac16a83b6545c15ecec1d0eb4eb2ea2c1647fb521712a9ebe98480cd0dff727fed0ecbceaaf3b23e0d85d97a0498f2e576cc9d7d DIST rs-async-zip-011b24604fa7bc223daaad7712c0694bac8f0a87.gh.tar.gz 51706 BLAKE2B 354eb52c95ea355521e1e6a7c841102424c47c156fdb0efb62e3cac666ecf289806aeefab8a0273a7c3283429ac81502283bdb5424d5f925621e5c2b1430fd4d SHA512 6650eef354e84daf41a8572b98b29f2873b7f071dd1d6983292c70b2f580fdc50cd26762d2228a70c2b200eae2f40476e6604702aa62cc97558301195bf19eb8 DIST rs-async-zip-1dcb40cfe1bf5325a6fd4bfcf9894db40241f585.gh.tar.gz 96766 BLAKE2B f9efab73c65394e33e090a6292875ebf35e6669b15c356f102eb109784a4503606ae39106cd0ebe3d7d479cb0b30806d7baaaebf22d826836a24f7ed49100934 SHA512 3b845b05d97c5ab5cea286a7c11846838b40bb1fac98a51782600849a53231be8fa205094c6bdd00f6e193c807b10b28f947698696382be99cae0a8d681dabdc +DIST rs-async-zip-285e48742b74ab109887d62e1ae79e7c15fd4878.gh.tar.gz 37003 BLAKE2B c4aed18d82641ced2771ad8b8e800c45b1ded279e8ba1874ec9766907d042ae13b460beac739ced6e31c03a647e4238af96fb41e8c0dff4c5d4dd7f59c0ebbff SHA512 d6dd699f43ca6e23a4c8abb8673b37d3983081a8c78545492ea3c1d0b35e3a491277c341df6dd64fb7efaec3b23eb479dede99e9b41016b5504d1a6dc9fbc617 DIST rs-async-zip-c909fda63fcafe4af496a07bfda28a5aae97e58d.gh.tar.gz 51763 BLAKE2B 59d053bc6692014d884a9247dea1b57a8789469ba2abbcc92ec21bb0022cbd74874afc463082156ab697aa6c80635019857a5d7e2dc150274e8b04d720518c36 SHA512 3a309566f4925b02496fcf19bc2865968edf6fb65082ca4079d2cee79e6b0353a1910c079f2afe656da0d0f6ddde5102052a221ea35a7dabc6d690a11218b20a DIST tl-6e25b2ee2513d75385101a8ff9f591ef51f314ec.gh.tar.gz 37106 BLAKE2B c30d1c33f6f52e2bc83823eb6319f8a3e462b7c7408fb6a08f995747857ef234f81db4135a04f9d183095fe473a4087f8f0cb89d8f87ef4400285d2ce034ec22 SHA512 4abbc4240ed129c92da8d616e27a6df0f24cdc85a0803acfdae588ca91f9e5b8d482e3ac88b2e657ff68917b1b43cef1e7ef3c887f624659b231fa5a13fcae68 DIST uv-0.1.35-crates.tar.xz 65640928 BLAKE2B 97135ce844dc7af3c424a9b8ea7419b4c392e44a87ab960e59401f0075308001287fc42acd9bc21b300fba3d73fa65e292b55e612b92db05cad183577866a7d8 SHA512 7d862992d2ea92acaa24758cb5425b3053941e1312db1f27ee318049ac68fcd64dc614ba7fa21521cdb9ad11545cc5e8dcc2a2781f0164297229f35768e0776e @@ -21,9 +24,12 @@ DIST uv-0.4.28-crates.tar.xz 45745492 BLAKE2B a685fdf6a15cffec0101d82baf24564d23 DIST uv-0.4.28.gh.tar.gz 2802279 BLAKE2B ea2f3a75d721f7f8941966e19dd2b613eac649c4ae0b0c4f1e0a0e6993e9d3b60adb19dec122f7a743d1f44d9ba51abac43837b26bf592c7554cb1acda381ee9 SHA512 98d608d917d5ff257ac96ac98462eb7a77d592131568cb93b4e7b233e8edfdc585795c2fdbc611f5353b768a234ab291393ae620d047ce060617cd200c194c1f DIST uv-0.5.4-crates.tar.xz 46254224 BLAKE2B 6019e9832dcc1415e10019e2d14953d2e764c0e89608ba23d480fd94daf58c65fd5ff1ffa61d87b2515e556eb0fde1d7dda02610a0cfd7b23055ec608e1a754e SHA512 fb6d85cb873a361f70dbd6b9cc50aae008795ac0996d92ef6fff7946c678ce0242cc60fb948e8a46be494f8045deb608f5b893888098885122f6a891aba382c2 DIST uv-0.5.4.gh.tar.gz 2915932 BLAKE2B 9de93655d8a752276c76ea749cec02e7187ac63dbec67a90c090636ceacb9e34dbba1ab950de00c8cd9ca3158f7fc38d4c4b5dfe6f9758256adfa2ea101cc7fd SHA512 fbaf6c1c9ef4bbc36c9a89c5ab0549732b2ddecf6d5a333814fbb5ed2724355e77b22183fbe9b922a81eb65d968d99c5fe410673985ac35161c199662838722d -EBUILD uv-0.1.35.ebuild 2081 BLAKE2B 4963b8a889e4ea56cf2da3b5b43630e8daec220f7fd168b27b7f6aaba058a13abbc6a43b2ead54a7da50ec8f8fa0b20eca1d17c68ba92c525dafddbf76e08661 SHA512 56e08f64189e7535fcc4345a463d11613e8625a61a3fe97fce1c4680addd99b48610172ab59d68d066f18a209937d55327ba9e7d022293ff50d064185547e806 -EBUILD uv-0.1.43.ebuild 2442 BLAKE2B 078944dc43e57a9443cb4d90274e78fe2d6e74564635feed8964f34c94eee4f4db446d2210fdf964eef289dcf01e77eacb774459ccab03670eedf46f3be2e0c2 SHA512 8e75e4921fc202d0f8908581a1e039d68b5bdc67b8da8995e68f87897e47531bf3b19e4e94c177d5edcb8f768f757b81bc9bf77075c680948c116b4f5aae64f2 -EBUILD uv-0.4.15.ebuild 3394 BLAKE2B 3eaecf3a9f7474c2dee56b6f760bd723fec71fa961800ec5fc54d658e6fde50065abe19753d602c228d822661a64b46e6a0006630cde77fb85f217e80b3ad97b SHA512 05f5346af0c39dac67faa954448faaf9e3f0137117a6ce9d526e6aa19caf8b50c4e0b1250497776133f92e1d3912190057ae02cc202d51d201279bef98800bee -EBUILD uv-0.4.28.ebuild 3571 BLAKE2B c798bef3c7c8f0efc051991f10bcdc94ec404d85f2550b975e1bcd590b7c59230fbb01459b2411eed474fcb9860d5d89e854af4c0fdd1612711b4d270d846bfb SHA512 beb9fe765c1958aeef0be65dee700002e53c955bf9178f1ad0bd300dcc9a5cfcd7683e1f8db2330e710c943f2f81ba0260d9c3f3d573c6091b30d5bac48f7e42 -EBUILD uv-0.5.4.ebuild 4309 BLAKE2B 77b25721786b4b555c1ffac50c593d98022a1c55cd30fcc67dca654675db518663d0a3ff7a5dc221ac2f314b9854683aef087e6a5b7ae61a50ebed5582406526 SHA512 97ff1b61492a46fc4020d379aaa08717fa30880bd5c8ea9e4cd1a7e965d411223e390f076dd85c3a8599b16b06d165518a1a5cbbbad3fed2f2fda612035c1afb +DIST uv-0.8.9-crates.tar.xz 46231320 BLAKE2B 39dafade2d08ac997424f8c20ac1d442bd1de4f71f650155f28823408591db13f4aa89c37796060e05e58fe1ec762682cd486a9041d843bf76491126f5e82a5c SHA512 df7624dd137f4677aed008a73330f9111bd854556fa99a0aed4ea1d6cf648fc7227264a065d6a7f0f28809781993e731eea51b951048a2c16a39af147a15a30f +DIST uv-0.8.9.gh.tar.gz 4269678 BLAKE2B 4457e4032a9d32be0103de691468449295bde4a73a0346d0e157441e3186a51066272bc8f7aabca9ee33243e08e071b01b4f5082a19573dab8a55edc6c2db84a SHA512 9b0fe90d4ebf78a2fad17bdc5201c28f9ed9e04a59f656da247093129237b02d0ef63b791e8c119927d30ab563c2cfbfeffe72912d48069c2f6f96a8d23c9259 +EBUILD uv-0.1.35.ebuild 2081 BLAKE2B 343d4e48ecc1738d3dceb297a7553f40d34bdeb2206ac3d85836a883b3cdb9f31434e48918f0db0cd7d32acd818d8639aa5b3109de4fa99d723edba829fc64bb SHA512 dee0609fd3fa3a1db08d35d1c0808edc2022092cc6837adb51c27cc2778687353e9b23b7b5a7b890428742905b8120117504ace7be7a528d45461923700a8d72 +EBUILD uv-0.1.43.ebuild 2442 BLAKE2B fc6b9b980cf20bd3077f400f88aa546a4021311a05da27bde8f9e036a47f12dbea9393d45dbdae7bf673149b9e8806d39cd2e2b5b4addeabfabf7f24c9180dcf SHA512 ba5c75591ebaf2c11dfc547d514e994d2b5610b5ea3b814056ea933ca62e2aca02c798d1d39d860ce34d30ffa78431f327feff30ec761d15180549c9ab96dcfb +EBUILD uv-0.4.15.ebuild 3394 BLAKE2B 7c3e161efa889513d705f0a21c63af8cf1766a24e4016edfaeb9b8b7fd21088e4f4308aaa4466b2a4e3a1b676d4722bd47592a7cfc1e0a47f36c687267d7ea09 SHA512 55e775ca6e0a949e666ddb3159e1c807f5789cac822bd42d9bbc5934fca1ece5231b3d87adb3601662a3dae16352d8f4493d773bf1d645759073523aec05e142 +EBUILD uv-0.4.28.ebuild 3571 BLAKE2B 3d14f730a7259137249fee556531b557eceb94c1b6c80f28b0badac3178f41f7879c14400d64ba42d9d0be4f54ac83350fd4595b04b410f8dd4d7984eb06467c SHA512 6909eb70c8afe72a26af90e4a06c19f4d0fb9111b4dede87d56b5256779ff9420cb182817b9b3678ea2f1c75fab224d6c96cf3a93281bde79037769599b644b5 +EBUILD uv-0.5.4.ebuild 4309 BLAKE2B 86b5ed5517d1e064efd5fb117a6f88599332fa8b08adc0b777a84822bf336a92f8793b59c6dfd06812dc2d089dbbd96c9e27d2634dccc79be6083cf8d8601965 SHA512 69ba45f9a14f60ad20a5a9534c4650be1a85372d1a7ddc30a739d90bb9958cfb236c845ee5923fe3e14e91d78b99b992d8e252f4fc0445a6d90a4c72cd173f0b +EBUILD uv-0.8.9.ebuild 5133 BLAKE2B d3b85c10b2cfcc18e7df804e96b041369f0390362f0ccd4d1e8c3bd8f8cf3ffd36d6cda9ee314367453b1d5355ec822d729e814924869f6fced5fe2c0b4d46cd SHA512 1ef386f38f1f9055d695828273136b5a5d508caf85b4a1bd34af240a27296ecac4871fd0aa46ac1c524adac1e1072408f61062f2b3c5958e2a39857a43a0b418 MISC metadata.xml 504 BLAKE2B f43087a5a4260082dec646a48af4f73eaa230c40d0cfcb263f3eaf4099c0427b98e280a5cc41ab9a19cbd99f4b4dec026108b5c64219a84615e0b9bed2d1c0fa SHA512 e6d457668a50867fd7103d6c8e1b5c15ca4f5229fabb65412054ac5e76f17ebd772be30219f83fc70b561a3432f6d003efa216f4df1be4a343339e494bcb990a diff --git a/dev-python/uv/uv-0.1.35.ebuild b/dev-python/uv/uv-0.1.35.ebuild index b9d02d885..f11f8c1fa 100644 --- a/dev-python/uv/uv-0.1.35.ebuild +++ b/dev-python/uv/uv-0.1.35.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 diff --git a/dev-python/uv/uv-0.1.43.ebuild b/dev-python/uv/uv-0.1.43.ebuild index 961063c6f..65c617346 100644 --- a/dev-python/uv/uv-0.1.43.ebuild +++ b/dev-python/uv/uv-0.1.43.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 diff --git a/dev-python/uv/uv-0.4.15.ebuild b/dev-python/uv/uv-0.4.15.ebuild index be5846c80..92e609dfd 100644 --- a/dev-python/uv/uv-0.4.15.ebuild +++ b/dev-python/uv/uv-0.4.15.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 diff --git a/dev-python/uv/uv-0.4.28.ebuild b/dev-python/uv/uv-0.4.28.ebuild index a6495436b..98fbe768d 100644 --- a/dev-python/uv/uv-0.4.28.ebuild +++ b/dev-python/uv/uv-0.4.28.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 diff --git a/dev-python/uv/uv-0.5.4.ebuild b/dev-python/uv/uv-0.5.4.ebuild index c82ed7962..cdb15c71e 100644 --- a/dev-python/uv/uv-0.5.4.ebuild +++ b/dev-python/uv/uv-0.5.4.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 diff --git a/dev-python/uv/uv-0.8.9.ebuild b/dev-python/uv/uv-0.8.9.ebuild new file mode 100644 index 000000000..d720daf2e --- /dev/null +++ b/dev-python/uv/uv-0.8.9.ebuild @@ -0,0 +1,184 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +CRATES=" +" + +declare -A GIT_CRATES=( + [async_zip]='https://github.com/astral-sh/rs-async-zip;285e48742b74ab109887d62e1ae79e7c15fd4878;rs-async-zip-%commit%' + [pubgrub]='https://github.com/astral-sh/pubgrub;06ec5a5f59ffaeb6cf5079c6cb184467da06c9db;pubgrub-%commit%' + [reqwest-middleware]='https://github.com/astral-sh/reqwest-middleware;ad8b9d332d1773fde8b4cd008486de5973e0a3f8;reqwest-middleware-%commit%/reqwest-middleware' + [reqwest-retry]='https://github.com/astral-sh/reqwest-middleware;ad8b9d332d1773fde8b4cd008486de5973e0a3f8;reqwest-middleware-%commit%/reqwest-retry' + [tl]='https://github.com/astral-sh/tl;6e25b2ee2513d75385101a8ff9f591ef51f314ec;tl-%commit%' + [version-ranges]='https://github.com/astral-sh/pubgrub;06ec5a5f59ffaeb6cf5079c6cb184467da06c9db;pubgrub-%commit%/version-ranges' +) + +RUST_MIN_VER="1.85.0" + +inherit cargo check-reqs + +CRATE_PV=${PV} +DESCRIPTION="A Python package installer and resolver, written in Rust" +HOMEPAGE=" + https://github.com/astral-sh/uv/ + https://pypi.org/project/uv/ +" +# pypi sdist misses scripts/, needed for tests +SRC_URI=" + https://github.com/astral-sh/uv/archive/${PV}.tar.gz + -> ${P}.gh.tar.gz + ${CARGO_CRATE_URIS} +" +if [[ ${PKGBUMPING} != ${PVR} ]]; then + SRC_URI+=" + https://github.com/gentoo-crate-dist/uv/releases/download/${CRATE_PV}/uv-${CRATE_PV}-crates.tar.xz + " +fi + +# most of the code +LICENSE="|| ( Apache-2.0 MIT )" +# crates/pep508-rs is || ( Apache-2.0 BSD-2 ) which is covered below +# Dependent crate licenses +LICENSE+=" + 0BSD Apache-2.0 Apache-2.0-with-LLVM-exceptions BSD-2 BSD + CDLA-Permissive-2.0 ISC MIT MPL-2.0 Unicode-3.0 Unicode-DFS-2016 + ZLIB +" +# ring crate +LICENSE+=" openssl" +SLOT="0" +KEYWORDS="amd64 arm arm64 x86" +IUSE="test" +RESTRICT="test" +PROPERTIES="test_network" + +DEPEND=" + app-arch/bzip2:= + app-arch/xz-utils:= + app-arch/zstd:= +" +RDEPEND=" + ${DEPEND} +" +BDEPEND=" + test? ( + dev-lang/python:3.9 + dev-lang/python:3.10 + dev-lang/python:3.11 + dev-lang/python:3.12 + dev-lang/python:3.13 + !!~dev-python/uv-0.5.0 + ) +" + +QA_FLAGS_IGNORED="usr/bin/.*" + +check_space() { + local CHECKREQS_DISK_BUILD=3G + use debug && CHECKREQS_DISK_BUILD=9G + check-reqs_pkg_setup +} + +pkg_pretend() { + check_space +} + +pkg_setup() { + check_space + rust_pkg_setup +} + +src_prepare() { + default + + # replace upstream crate substitution with our crate substitution, sigh + local pkg + for pkg in reqwest-middleware reqwest-retry; do + local dep=$(grep "^${pkg}" "${ECARGO_HOME}"/config.toml || die) + sed -i -e "/\[patch\.crates-io\]/,\$s;^${pkg}.*$;${dep};" Cargo.toml || die + done + + # force thin lto, makes build much faster and less memory hungry + # (i.e. makes it possible to actually build uv on 32-bit PPC) + sed -i -e '/lto/s:fat:thin:' Cargo.toml || die + + # enable system libraries where supported + export ZSTD_SYS_USE_PKG_CONFIG=1 + # TODO: unbundle libz-ng-sys, tikv-jemalloc-sys? + + # remove unbundled sources, just in case + find "${ECARGO_VENDOR}"/{bzip2,lzma,zstd}-sys-*/ -name '*.c' -delete || die + + # bzip2-sys requires a pkg-config file + # https://github.com/alexcrichton/bzip2-rs/issues/104 + mkdir "${T}/pkg-config" || die + export PKG_CONFIG_PATH=${T}/pkg-config${PKG_CONFIG_PATH+:${PKG_CONFIG_PATH}} + cat >> "${T}/pkg-config/bzip2.pc" <<-EOF || die + Name: bzip2 + Version: 9999 + Description: + Libs: -lbz2 + EOF +} + +src_configure() { + local myfeatures=( + git + pypi + python + ) + + cargo_src_configure --no-default-features +} + +src_compile() { + cd crates/uv || die + cargo_src_compile +} + +src_test() { + # work around https://github.com/astral-sh/uv/issues/4376 + local -x PATH=${BROOT}/usr/lib/python-exec/python3.12:${PATH} + local -x COLUMNS=100 + local -x PYTHONDONTWRITEBYTECODE= + # fix tests failing because of our config + local -x XDG_CONFIG_DIRS=${T} + + cd crates/uv || die + cargo_src_test --no-fail-fast +} + +src_install() { + cd crates/uv || die + cargo_src_install + + insinto /etc/xdg/uv + newins - uv.toml <<-EOF || die + # These defaults match Fedora, see: + # https://src.fedoraproject.org/rpms/uv/pull-request/18 + + # By default ("automatic"), uv downloads missing Python versions + # automatically and keeps them in the user's home directory. + # Disable that to make downloading opt-in, and especially + # to avoid unnecessarily fetching custom Python when the distro + # package would be preferable. Python builds can still be + # downloaded manually via "uv python install". + # + # https://docs.astral.sh/uv/reference/settings/#python-downloads + python-downloads = "manual" + + # By default ("managed"), uv always prefers self-installed + # Python versions over the system Python, independently + # of versions. Since we generally expect users to use that + # to install old Python versions not in ::gentoo anymore, + # this effectively means that uv would end up preferring very + # old Python versions over the newer ones that are provided + # by the system. Default to using the system versions to avoid + # this counter-intuitive behavior. + # + # https://docs.astral.sh/uv/reference/settings/#python-preference + python-preference = "system" + EOF +}