mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-24 18:58:08 -07:00
Merge updates from master
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
# Copyright 2019-2025 Gentoo Authors
|
||||
# Copyright 2019-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
PYTHON_COMPAT=( python3_{10..13} )
|
||||
|
||||
inherit optfeature python-r1
|
||||
inherit optfeature prefix python-r1
|
||||
|
||||
DESCRIPTION="Command-not-found handler for Gentoo"
|
||||
HOMEPAGE="https://github.com/Nowa-Ammerlaan/command-not-found-gentoo"
|
||||
@@ -21,6 +21,11 @@ REQUIRED_USE="${PYTHON_REQUIRED_USE}"
|
||||
|
||||
RDEPEND="${PYTHON_DEPS}"
|
||||
|
||||
src_prepare() {
|
||||
default
|
||||
hprefixify command-not-found.sh
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_foreach_impl python_doscript command-not-found
|
||||
|
||||
@@ -766,6 +766,34 @@ DIST rust-1.93.0-x86_64-unknown-linux-gnu.tar.xz 192930828 BLAKE2B e94ce84407bb7
|
||||
DIST rust-1.93.0-x86_64-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B e02d037cf941d062b22304dcd526c6da8847d55abf8a4a634ffae0af2242d0db052aa7c3b05d483276e30d6352c6c139d991f0990264c538ed0b601424a93ed7 SHA512 024461a3bd1eedca3fa98fe586a6ab4dca7300358d9e95379fe83dd51005e7447ee9de5b08f1cac06d7415de420e47e10288e5fa80cf22f27ce883f3de09a748
|
||||
DIST rust-1.93.0-x86_64-unknown-linux-musl.tar.xz 295317012 BLAKE2B a467ceb75991bf0e464de4d4ea16dc288e06176d6af0a7c9ebfd8dd694bbc5bb7b9cc677ae232997106c404daa72d0734e30234dbbb92af51ba68d70176c7168 SHA512 a3e6677698b9e556583a335b80736ac04b391da4f4e24a943ae472de92dc8c9bff5ecba4165f069041142df54b7d6a9dfda61c30405fb5b25dc4b5d6b9ffb812
|
||||
DIST rust-1.93.0-x86_64-unknown-linux-musl.tar.xz.asc 801 BLAKE2B ffc668e7a4309f078b2c032e21054d988010d2d07a7fb041b0db413f5c8b1a5a68d99f9d94099d270b43ac44b04392981a29fdb8a8c063570f33c345281743cd SHA512 f530ab1e1aae5036587c6bbf11864c38c290d47951a053217d5ea6f943f419798dfc92f33fdca17fde07fbd5817b2573e82f5a136f2cc745a6fd11cf8705ea41
|
||||
DIST rust-1.93.1-aarch64-unknown-linux-gnu.tar.xz 169781296 BLAKE2B 5cc411865373c857e60e6a086ac5fcfc7f17f471034c2576d023d9356423516641e6eab3727b930d278e77121ad781f3866e3bed09417e43faf8355b4ecbda89 SHA512 ba24d928d037fec864ce09b796e077655cd62c8cc07b69b99f629069e67417c6b62a9ac829e37005e50f01274d796d8e95aee03c9c04315bac63b88fb7a372f5
|
||||
DIST rust-1.93.1-aarch64-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B b0f2b8bfd8e1ca5a76acdca9d47b5e5131f522057be0dc9666c74bcf5c6835ed79d3c38e7842351f123a999a170225b70bb8f3c8f14bcfeec8fbe7531c795a2b SHA512 8cae62fc0fd34755bf41da69f32349c23e56824f101716aee1978965cee5b9e81f1a5b16228668a137345992bfee19f05d14e29a464ce7cb409f104788f3dce4
|
||||
DIST rust-1.93.1-aarch64-unknown-linux-musl.tar.xz 244143464 BLAKE2B 61815229a24345b61d6dd7138d8b7475072d14b19c20a65412afbe4500bed6b5b6be0e5fca685f0460f6c1408e8a7de36e52eb4c8864ceca0e41ba40dd2572fb SHA512 904790cd8eddb2610e916329a4f8218079eb0381937704348ccc44e805ea6afceac7623b30f5febcbf566ee7dd72e71518d8395a0d8fdbacc7633df34701f59a
|
||||
DIST rust-1.93.1-aarch64-unknown-linux-musl.tar.xz.asc 801 BLAKE2B 4ca681b890493041acccaaf11d5c64ea125f02198548d2e05b3c7591ec8c000b1925cef75b6fabffd11e7d955fab5992e3799305b02f7256cf5404fe53e84e06 SHA512 8a07504fc0bc3e904351cd4b9ea6e2f498606f53c76508a0b9e6370ca77a0b32f4cf365d4066db6fbf892ee11c96cf695a2c28eb03f5115468bd07903a70c094
|
||||
DIST rust-1.93.1-arm-unknown-linux-gnueabi.tar.xz 225501336 BLAKE2B 021e3a3c11fed9cb2670a32938abfa1a466b32086708415df3b4231c7df1af5dbfc25542a65928487aea1faba93996de7d5b587a01bb0899918e9f044af27bf9 SHA512 e0099c5cea9d669f715577ea68d4174e93b45c9c1bdc72643569ae69f5ef1f19d055d0ddc92e8b24eb4a2c87d231126260d219ac2bd155590317ab306ad3ce96
|
||||
DIST rust-1.93.1-arm-unknown-linux-gnueabi.tar.xz.asc 801 BLAKE2B ce12b43f34dee34597e1df09b6bc322db98f4e7372291b3c62ce68f5d820dc34c1f40d3fb2291a91b08936262c7b9fa12b908e50476fa4ba4e63aeb4aa79c0d1 SHA512 0f6ce2b392192e16bebb29ef579c5a1016347641d14c7a1e228e1ec8d598a744ed3b20de2e5e58725a8c7a5e4ef1039e3851c3103ae8b95adc0b8367a42741e4
|
||||
DIST rust-1.93.1-arm-unknown-linux-gnueabihf.tar.xz 225914300 BLAKE2B e0ee608325326f14e008af13dd109652c493557f92a66e9fbb4ff34dbcdd7578fc81df9f1a68356dd6209c3dab5b6924f61f30d6efe2afcb3e585c409d9396f9 SHA512 c032cfd530619ea8ee78dd885557e3f16daca2c5154ba7acada7e07ece202546f04dba5c7070f2941cf3cf5a0f2c76328e6d35d87983943d6c3a039e5d61933e
|
||||
DIST rust-1.93.1-arm-unknown-linux-gnueabihf.tar.xz.asc 801 BLAKE2B 6815e5f17f31eac119bfd7f1bc3a72df3a9f8352d2fb36396af4253c98fabe7107407fed68830123ba80c397cff7aea2ad7c2f737e1f7da8c6cfc0a579d6ac90 SHA512 e1cf9279bfdc8d8edbcf3df1f66f62970cd3e73faafd27f5c07fb87d459408d0d8fabeaa9ad298c50c0c96f7d771e13c38b37b02af988cb45ce0c634e3c5408b
|
||||
DIST rust-1.93.1-armv7-unknown-linux-gnueabihf.tar.xz 227522816 BLAKE2B a238d773a0d724e6a94d7ad5ded9ff1ed3f4f2bec8f085f3180e82dc538a49fa22f8725bf4ffd0c411630dc49a26893a8296e69c255f8c1814289852aaddc550 SHA512 1a1540f95c51bd7699658bf943ff2a0baef131404b8308db4a9db202cd1d701822e970c046254a38ea90975bc4d12dc59e8700365f100b30ab540c2e39738c51
|
||||
DIST rust-1.93.1-armv7-unknown-linux-gnueabihf.tar.xz.asc 801 BLAKE2B 94c6c471c7c4d97fe44c3975929173a633f2d8fc3ef833fcf0c3ed37ceb3414dfca4732238ba33d603c4be2c8d9f623305477a7109a44b32f7c2fa11147ed888 SHA512 6ae9f955bc24226059f5b9b0e412bbf64af080f6f77a02afc72b6f72b7af61f66d3a8700c8c44604e217696c6290d1e9e39056444b84d8ceb72a12ea30406b33
|
||||
DIST rust-1.93.1-i686-unknown-linux-gnu.tar.xz 267242468 BLAKE2B 7784c64d3e2a57ca497bef0656897d17a1fe28176c46a857fdeaf8193b29f72c9e10fe78221d39b3e101a97a82d0e53ae4a07307b04883029ac87ba1cc388131 SHA512 d842438236816e498b1a5d845f2e09d8a7fc75500c4b0c565911adf67387ae4e1ec2d6ca231fe489800aa57ef6e4f4aa8daa713cabf84b09189ded79010e75bd
|
||||
DIST rust-1.93.1-i686-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B d064833f4887d4f265b04f9b53eb8153e90206e894641f8140e9a933e78d5f326f600aee9c0c7c2fd37d3711b6e73dda3ecb67d8367766a3dee25542a2da2123 SHA512 b6369337deeb055f56fd622ff4481215aab017e8f32a1eaa54efa6d921bd8e136dec159eccc742c2bd75fe785869b8583d461c2114c651dcffa05c5d9523a902
|
||||
DIST rust-1.93.1-loongarch64-unknown-linux-gnu.tar.xz 260093372 BLAKE2B 37a503be2311101fd14c2274c8f03cd66931bc9bbd9cc1991eccefa7e27552f24262795e0e8dd9b8a552e6dfe716a17a2c21be510f766a06a2c8229270e6f565 SHA512 27360935c2c2b76fdc7029dd737c10e1507c86a4d66f92339af47699c972cbfdfe4c9c76efd6f797587a842f32d03a824a7040cd2cf632ea8e72d808dd256f9a
|
||||
DIST rust-1.93.1-loongarch64-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B 245fd3da533a8825ab5c37dbdc06056a0e33215f4960ae29e15592efc4cce830f4ce7b635f056a4875c438345447c176ca580e59712833d37cc2fa279dad8877 SHA512 1393601274ddca503d53f442831d3bcb74c9ecbbdf05a71edaeca704fd6593e699546c70596031ad75f8a50420ab69a72934655ea72175dded6708f8fcc08428
|
||||
DIST rust-1.93.1-powerpc-unknown-linux-gnu.tar.xz 248960324 BLAKE2B 2198131dbac56d4797687ab43ad795440e99ba9538c82e11d595bd84696f1d59fa390b0dd5f73b75cf07383fc9b727bfe4742fd1f3e4eb53eb7bfaf43ff4dd95 SHA512 6b6c0b6ca2f2d26889eca3767913e4c18edb8c22ba30714fd215ff475d08d834e3a4fd0d179c1fa7f8174aec4f79ab5b84fc6438a81a8d42d3471bb7b8eacfa3
|
||||
DIST rust-1.93.1-powerpc-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B 6109e743f7829f6c5ef2885eb9859a94fd301e693810cf8df2a9396e45a656315cb7e32bda733a708515b01d6142a735f10c276b86f9169552ad00460c7891a7 SHA512 b904c3de40715389f91f10f8ce7781951e22510a13f3fc740376ebe1953fcd8197ad8590327fd5c5b537de0c78e7a7366e097bfeee560a318d262774f16e52b4
|
||||
DIST rust-1.93.1-powerpc64-unknown-linux-gnu.tar.xz 250785352 BLAKE2B 1838ef2f74f8cafa6a122ac1c6a25909e57a5ed2da9ce6ccaf91999413e326b92358fe32b3f21df9c9fc6ed95c8482d97c425f7663bf452cdfa88d50cd3bd504 SHA512 6302daeee7039f5c1b1c68dfeeb0e722582c419f6f47a85590cc379b5632308dad8ce8b2c08240c5232769170948322b1e8cb759ddb3a5ae87fb2baa76940992
|
||||
DIST rust-1.93.1-powerpc64-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B d7ad185b8764ae420aadd6eb3739610f2ed61ddc56a41dc72386effaeb04f3fbaae013c7954ee336e42ff6946519e58a38c9dfde912f1e1fd88728e864dee5bb SHA512 e0fef1c123650c9ef85863a7994c0a20023d065853da48880a9e4088ebd56c643fa701a210aef68d89e52d36fe78a134952f48852c5ce4d1067aaf5c85ba0b33
|
||||
DIST rust-1.93.1-powerpc64le-unknown-linux-gnu.tar.xz 268583976 BLAKE2B da1c803065d4c0e60b2b31199015e48298620d9cec916023ec0ae540eaf25a5ffcad6413f53dbab6865367923dc785413e6aab758de342d20aa1b1f7f405f0d1 SHA512 d577bf80a752e171b454ac7dd45a5d5c11ded071ee2ad003a7bb054cb80f688f1ee244114509ea1ef92cf6725ac6cfb9bc65f416d462339807b6995d531a6ecd
|
||||
DIST rust-1.93.1-powerpc64le-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B 31c777095a14cddddb4312fb3a5e8d68e86efc8054c245d5ef0638695eaa359b8eef4677c89d7bb1780d4a76422674e85129493b1882956a1978b0f0e2d8f178 SHA512 0c4f9730c3cdb9993c4dac40206fbc4fd25783601cca4051be259c34752364067bab83e66f6e5c7ce23889cc0eb2b2077d1b240565fc14bcbb3004890f40f90e
|
||||
DIST rust-1.93.1-riscv64gc-unknown-linux-gnu.tar.xz 246512252 BLAKE2B 84adb4e1410ff887a68becec561f7c5fe8cb031e295f27026cac3afa105c09d4b98a5fd2a75af6c2507c335f1155b0b7fc7ebe38525c9426c983c34a745b766c SHA512 e2c8fe32710cca402b366e54fb53e2bf46ca6fd963e381bc276fc3384c64abf90cbe1744484c0c83b4c656e643a73dd48a6e6fc8aa761a1448b087bdc6a8ca83
|
||||
DIST rust-1.93.1-riscv64gc-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B b216d82a8c99420b24a59faf9cc20220fe671ca6c11067e93456e39009c04ec8fd1fceb7edbf6b24e9fb95abf7b8b3ba4c746f8945e1f0f8254826abc4e21617 SHA512 4c119de8c7a5e6f877521634c45ea35d1fbe84b3d36bb0c54bb489f4e940976ba9661df3bfdb9122d4e05eecb67e9f1c159f61e3c52252cbea8b0d085924c8a2
|
||||
DIST rust-1.93.1-s390x-unknown-linux-gnu.tar.xz 239133552 BLAKE2B 0d8b5d585a82f41a660427a7adffd775b9f6dfc772b2f229bbed8ce558051d2314f36674051aee3608728d1bada53b0fde3cb828829d8b5dfefb19eb196c72c9 SHA512 48b96de42fcc849ed13edb7b737c8baba936abe17396abf1b7ffef208406a78642670b0a9761d1c4e790d4012dead9fde8d2f5b0514b3be637908f6b95a8bcbd
|
||||
DIST rust-1.93.1-s390x-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B 860defcd5f5ed8f8989dfe6c8afab18bc9e95bcac98abb53672685acf2b09d111af12748b3b77b25ae097d813b7bff60c252ae3fe8216b63667c363a185d7f31 SHA512 f00606b882ee1dea556c6766b6f784c61c3c018bb7a0fa598669d6eb34830d5c805a045804dff4d89e2aa64f9a737594968b25b8b7a1619154481fe0a97842ee
|
||||
DIST rust-1.93.1-x86_64-unknown-linux-gnu.tar.xz 193192180 BLAKE2B fd8d2f3ab45f390e33ba3244ce5aae49c415fe286c8b42da70a4fa741127b6e6b2e1adebd3c0e586ebb8ad347bfa20960d9231352b51b31b48838d1658b2e952 SHA512 2c111986db72ca33b3d5c73445f1d89af9f417546574993c5bc2ffc721f176d603f16809007c722f22bb337303277ed1175270ddc9b0261c0338a9900c969a90
|
||||
DIST rust-1.93.1-x86_64-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B adf891709bd5c87dafdbd8e8498956257a0fbfb179147f00f23dd00ac2eb43ab19a2d51850632f7a3d9adaa403461144983a2bb172d6eabd6e2e148eda570662 SHA512 25b658237207ef5f99ff3e276412f9ac08b5c5504df066d9178e22e22d3d4e3dfa897313a6393a6a6833ccda09c0c5dbcfeacfce53c09bf5a97e7b36afbb3f3f
|
||||
DIST rust-1.93.1-x86_64-unknown-linux-musl.tar.xz 295454356 BLAKE2B 1e40b50ff65d42a7445ff4d3f4a79fec7e8f729c245ba06d0bea90a05c387ac895df736ff59d27799512aa94703205aeb5235802badd56c3e0b681269e66ab41 SHA512 c805770236eee08cc222022d46e09ba6835c08241644d1d76eeab42463a9faafa26f1d50796faf0223e6601940ff52c507eb04ecc3f26066900c0185341bec4f
|
||||
DIST rust-1.93.1-x86_64-unknown-linux-musl.tar.xz.asc 801 BLAKE2B 40dfd17d105de1bcfb3fecf0b41c066c3f9c93a563396a0bf88d975667776b1c1d2784a0cc495a14c78878b9c3b0043800b06de702eca6720f0f340f7afd1989 SHA512 6f584cbe33f7678632929f9395ac92a75721da376883432c6608fd0383fa713342a8971f85645a4dc9311477a7c2a6cc905f4e25fca47eb8a35dc9996f8fbb3f
|
||||
DIST rust-1.94.0_beta20260126-aarch64-unknown-linux-gnu.tar.xz 168363516 BLAKE2B 38c623524417e98bfbe448f0be605552598b1b879fabac744d8263c5baa1d5eadd1a757582531eddc9bf7924b382073f33fe72f6fe6c3839f67410ba8456c2ab SHA512 c06171cfca7bc42ac62a718541147ab6c3dc0221468ce3de673cd9fac0bde86f1b7d5fee060acf53f090f6cebb386c701625cde4658e0ae876417993cec6c872
|
||||
DIST rust-1.94.0_beta20260126-aarch64-unknown-linux-gnu.tar.xz.asc 801 BLAKE2B a81116d147b0bccc93944ed0ec82e1c4666620b4e45c0c38a18e6454fbc7b6a890ad04147f4a17e156a5e6cfdd08815f579cd8b5cdb806d001ee445e51e3b534 SHA512 dd1843c35cbcecf70d14da312a8340e3c523f8e2e37526a499a37bc94616852e597768d6fd6cd2e9f467674634b79c71b54b7cd40151b82e10cb446de5ef4f28
|
||||
DIST rust-1.94.0_beta20260126-aarch64-unknown-linux-musl.tar.xz 242112904 BLAKE2B af6a5ffa79ecebf271e09a2aecde8fa5a83e3aae421b7d1069464774345dcba122f6231a288c3f56cf0bb1e5195f80f149a9d851390494313c132166c6c27c7b SHA512 083a69343a86244e006e78e4a4de39e42a6e4a4b91ace04a9706132fd38457be7227ece588245159a78d31fa5f87828d403190429a472dec847a203054cf9d98
|
||||
@@ -816,4 +844,5 @@ DIST rust-src-1.90.0.tar.xz 3473408 BLAKE2B 09e9d17af7acb38b99e33874cd4b14ad7e0e
|
||||
DIST rust-src-1.91.0.tar.xz 3509292 BLAKE2B b1cf99db4cbd864fda34c2068a19e8b36c99f6bb5c2fa3c22ef7aa006d4c084bd706fff872a7f87a0ded3db3dead5927153183e4425ffd90e51af468a29db48e SHA512 8d7c5a3aa11b42d5b89b38d1167f6be64de49288738e0fd949d1fe9ac3312830301d578a13de2030b45a7c51179b5adb934deb52e1070afa76520944050baa2e
|
||||
DIST rust-src-1.92.0.tar.xz 3530724 BLAKE2B 1385e8cc8062dffa69829e4ffeee7daaaeddc35c20c5e841e5183952d2eb8e3c33fe64deff46a7017057723ac3623f1b918d6a61ba2efadc6501bae36241c161 SHA512 be31d704b936d421dae7774dd7243d2a2668c54eac07f3e8d6c289a994c9e238a6e775be2735c4b609e710d8bbb1afe9bf028375e573e5d16def58a53ebc4ba7
|
||||
DIST rust-src-1.93.0.tar.xz 3722768 BLAKE2B 9b80cd62e3345cb523fc1596dc1957c03a5edb42e9144fdf1466959ebf347dba3725a1a777e9197dcdbdb7b99ef3cc6d2de9e6359c245db2a919064a2a92f91e SHA512 02535cf5aca3efdc708d959c641994dc3f7f60385afbe3c4aa14037b5b7107ddfe1af0bca6493b97e0144e5d31e45937fe86b026e48bf6231ac7efd404762d83
|
||||
DIST rust-src-1.93.1.tar.xz 3722488 BLAKE2B 61a63c8eb169917dd9140ddba06fbbf8e05ce54ee7331e6fb906eb705c69615922502da72f3646d35cf2a126b1624f3afe3ca45b611b6c7ebed843a38f8e6a3a SHA512 5d4a5a3dede3b0334c779e9936030cfa46577600ee6d69e92e190d04c26c6020d262a6fd4e9b4516e7325a0e256ad18bc6d659bab0c638aa53dbe76f7d4dfa0f
|
||||
DIST rust-src-1.94.0_beta20260126.tar.xz 3749064 BLAKE2B ff884008033aac3b7bb9282ec3d4d4d43c2280a0514d3e43ccb588c545057a4df241b7645dfe679d6b4dfc1ac7de1f5df02ad33c8a5fc16185e2c3c775b27acd SHA512 9a76eff1af369eb29f646d1125e37cf140685c3aa4930a75bfa7a6b299672c46525db06b2459626ddfa5ddabd26dcde297e8dadf0158ce302c2fcd5663769cc2
|
||||
|
||||
337
dev-lang/rust-bin/rust-bin-1.93.1.ebuild
Normal file
337
dev-lang/rust-bin/rust-bin-1.93.1.ebuild
Normal file
@@ -0,0 +1,337 @@
|
||||
# Copyright 1999-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
LLVM_COMPAT=( 21 )
|
||||
LLVM_OPTIONAL="yes"
|
||||
|
||||
inherit edo llvm-r1 multilib prefix rust-toolchain verify-sig multilib-minimal optfeature
|
||||
|
||||
if [[ ${PV} == *9999* ]]; then
|
||||
# We need to fetch a tarball in src_unpack
|
||||
PROPERTIES+=" live"
|
||||
elif [[ ${PV} == *beta* ]]; then
|
||||
# curl -Ls static.rust-lang.org/dist/channel-rust-beta.toml | grep "xz_url.*rust-src"
|
||||
betaver=${PV//*beta}
|
||||
BETA_SNAPSHOT="${betaver:0:4}-${betaver:4:2}-${betaver:6:2}"
|
||||
RUST_TOOLCHAIN_BASEURL=https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/
|
||||
SRC_URI="$(rust_all_arch_uris rust-beta rust-${PV})
|
||||
rust-src? ( ${RUST_TOOLCHAIN_BASEURL%/}/rust-src-beta.tar.xz -> rust-src-${PV}.tar.xz )
|
||||
"
|
||||
else
|
||||
# curl -Ls static.rust-lang.org/dist/channel-rust-${PV}.toml | grep "xz_url.*rust-src"
|
||||
SRC_URI="$(rust_all_arch_uris "rust-${PV}")
|
||||
rust-src? ( ${RUST_TOOLCHAIN_BASEURL%/}/2026-02-12/rust-src-${PV}.tar.xz )
|
||||
"
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~s390 ~x86"
|
||||
fi
|
||||
|
||||
GENTOO_BIN_BASEURI="https://github.com/projg2/rust-bootstrap/releases/download/${PVR}" # omit trailing slash
|
||||
|
||||
DESCRIPTION="Systems programming language from Mozilla"
|
||||
HOMEPAGE="https://www.rust-lang.org/"
|
||||
|
||||
if false ; then #[[ ${PV} != *9999* && ${PV} != *beta* ]] ; then
|
||||
# Keep this separate to allow easy commenting out if not yet built
|
||||
SRC_URI+=" sparc? ( ${GENTOO_BIN_BASEURI}/rust-${PVR}-sparc64-unknown-linux-gnu.tar.xz ) "
|
||||
SRC_URI+=" mips? (
|
||||
abi_mips_o32? (
|
||||
big-endian? ( ${GENTOO_BIN_BASEURI}/rust-${PVR}-mips-unknown-linux-gnu.tar.xz )
|
||||
!big-endian? ( ${GENTOO_BIN_BASEURI}/rust-${PVR}-mipsel-unknown-linux-gnu.tar.xz )
|
||||
)
|
||||
abi_mips_n64? (
|
||||
big-endian? ( ${GENTOO_BIN_BASEURI}/rust-${PVR}-mips64-unknown-linux-gnuabi64.tar.xz )
|
||||
!big-endian? ( ${GENTOO_BIN_BASEURI}/rust-${PVR}-mips64el-unknown-linux-gnuabi64.tar.xz )
|
||||
)
|
||||
)"
|
||||
SRC_URI+=" riscv? (
|
||||
elibc_musl? ( ${GENTOO_BIN_BASEURI}/rust-${PVR}-riscv64gc-unknown-linux-musl.tar.xz )
|
||||
)"
|
||||
SRC_URI+=" ppc64? ( elibc_musl? (
|
||||
big-endian? ( ${GENTOO_BIN_BASEURI}/rust-${PVR}-powerpc64-unknown-linux-musl.tar.xz )
|
||||
!big-endian? ( ${GENTOO_BIN_BASEURI}/rust-${PVR}-powerpc64le-unknown-linux-musl.tar.xz )
|
||||
) )"
|
||||
fi
|
||||
|
||||
LICENSE="|| ( MIT Apache-2.0 ) BSD BSD-1 BSD-2 BSD-4"
|
||||
SLOT="${PV%%_*}" # Beta releases get to share the same SLOT as the eventual stable
|
||||
IUSE="big-endian +clippy cpu_flags_x86_sse2 +doc prefix rust-analyzer rust-src +rustfmt"
|
||||
|
||||
# net-misc/curl is needed for our own bootstrapped rustc, since cross-compiling bundled curl is not supported
|
||||
RDEPEND="
|
||||
>=app-eselect/eselect-rust-20190311
|
||||
dev-libs/openssl
|
||||
net-misc/curl
|
||||
sys-apps/lsb-release
|
||||
|| (
|
||||
llvm-runtimes/libgcc
|
||||
sys-devel/gcc:*
|
||||
)
|
||||
!dev-lang/rust:stable
|
||||
!dev-lang/rust-bin:stable
|
||||
"
|
||||
BDEPEND="
|
||||
prefix? ( dev-util/patchelf )
|
||||
verify-sig? ( sec-keys/openpgp-keys-rust )
|
||||
"
|
||||
[[ ${PV} == *9999* ]] && BDEPEND+=" net-misc/curl"
|
||||
|
||||
REQUIRED_USE="x86? ( cpu_flags_x86_sse2 )"
|
||||
|
||||
# stripping rust may break it (at least on x86_64)
|
||||
# https://github.com/rust-lang/rust/issues/112286
|
||||
RESTRICT="strip"
|
||||
|
||||
QA_PREBUILT="
|
||||
opt/rust-bin-${SLOT}/bin/.*
|
||||
opt/rust-bin-${SLOT}/lib/.*.so*
|
||||
opt/rust-bin-${SLOT}/libexec/.*
|
||||
opt/rust-bin-${SLOT}/lib/rustlib/.*/bin/.*
|
||||
opt/rust-bin-${SLOT}/lib/rustlib/.*/lib/.*
|
||||
"
|
||||
|
||||
# An rmeta file is custom binary format that contains the metadata for the crate.
|
||||
# rmeta files do not support linking, since they do not contain compiled object files.
|
||||
# so we can safely silence the warning for this QA check.
|
||||
QA_EXECSTACK="opt/${PN}-${SLOT}/lib/rustlib/*/lib*.rlib:lib.rmeta"
|
||||
|
||||
VERIFY_SIG_OPENPGP_KEY_PATH="/usr/share/openpgp-keys/rust.asc"
|
||||
|
||||
src_unpack() {
|
||||
if [[ ${PV} == *9999* ]]; then
|
||||
# We need to fetch the latest nightly listing and get the apprapriate src_uri for our arch
|
||||
local rust_bin_url rustc_src_url
|
||||
# Cut down on webrequests by fetching the nightly toml once
|
||||
curl -Ls static.rust-lang.org/dist/channel-rust-nightly.toml > "${WORKDIR}/channel-rust-nightly.toml" ||
|
||||
die "Failed to fetch nightly revision info"
|
||||
rustc_src_url=$(grep 'xz_url.*rust-src' "${WORKDIR}/channel-rust-nightly.toml" | cut -d '"' -f 2)
|
||||
|
||||
if use rust-src; then
|
||||
einfo "Using nightly Rust-src from: ${rustc_src_url}"
|
||||
# We need to fetch the rust-src tarball
|
||||
einfo "Fetching nightly rust-src tarball ..."
|
||||
curl --progress-bar -L "${rustc_src_url}" -o "${WORKDIR}/rust-src-${PV}.tar.xz" ||
|
||||
die "Failed to fetch nightly rust-src tarball."
|
||||
# no verify-sig here, just unpack it
|
||||
tar -xf "${WORKDIR}/rust-src-${PV}.tar.xz" || die "Failed to unpack nightly rust-src tarball"
|
||||
fi
|
||||
|
||||
local v
|
||||
for v in $(multilib_get_enabled_abi_pairs); do
|
||||
rust_target="$(rust_abi $(get_abi_CHOST ${v##*.}))"
|
||||
rust_bin_url=$(grep "xz_url.*rust-nightly-${rust_target}" "${WORKDIR}/channel-rust-nightly.toml" | cut -d '"' -f 2)
|
||||
einfo "Using nightly Rust from ${rust_bin_url} for ${rust_target}"
|
||||
|
||||
einfo "Fetching nightly Rust tarball for ${rust_target} ..."
|
||||
curl --progress-bar -L "${rust_bin_url}" -O || die "Failed to fetch nightly tarball for ${rust_target}"
|
||||
if use verify-sig; then
|
||||
einfo "Fetching nightly signature for ${rust_target} ..."
|
||||
curl --progress-bar -L "${rust_bin_url}.asc" -O || die "Failed to fetch nightly signature for ${rust_target}"
|
||||
verify-sig_verify_detached "${WORKDIR}/rust-nightly-${rust_target}.tar.xz" \
|
||||
"${WORKDIR}/rust-nightly-${rust_target}.tar.xz.asc"
|
||||
fi
|
||||
|
||||
tar -xf "${WORKDIR}/rust-nightly-${rust_target}.tar.xz" || die "Failed to unpack nightly tarball for ${rust_target}"
|
||||
done
|
||||
else
|
||||
# sadly rust-src tarball does not have corresponding .asc file
|
||||
# so do partial verification
|
||||
if use verify-sig; then
|
||||
for f in ${A}; do
|
||||
if [[ -f ${DISTDIR}/${f}.asc ]]; then
|
||||
verify-sig_verify_detached "${DISTDIR}/${f}" "${DISTDIR}/${f}.asc"
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
default_src_unpack
|
||||
fi
|
||||
|
||||
# We only want to do this for the native ABI. Non-native ABIs are
|
||||
# handled differently in multilib_src_install.
|
||||
case ${PV} in
|
||||
*9999*)
|
||||
mv "${WORKDIR}/rust-nightly-$(rust_abi)" "${S}" || die
|
||||
;;
|
||||
*beta*)
|
||||
mv "${WORKDIR}/rust-beta-$(rust_abi)" "${S}" || die
|
||||
;;
|
||||
*)
|
||||
mv "${WORKDIR}/rust-${PV}-$(rust_abi)" "${S}" || die
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
patchelf_for_bin() {
|
||||
local filetype=$(file -b ${1})
|
||||
if [[ ${filetype} == *ELF*interpreter* ]]; then
|
||||
einfo "${1}'s interpreter changed"
|
||||
patchelf ${1} --set-interpreter ${2} || die
|
||||
elif [[ ${filetype} == *script* ]]; then
|
||||
hprefixify ${1}
|
||||
fi
|
||||
}
|
||||
|
||||
rust_native_abi_install() {
|
||||
pushd "${S}" >/dev/null || die
|
||||
local std="$(grep 'std' ./components || die "std not found in components")"
|
||||
local components=( "rustc" "cargo" "${std}" )
|
||||
use doc && components+=( "rust-docs" )
|
||||
use clippy && components+=( "clippy-preview" )
|
||||
use rustfmt && components+=( "rustfmt-preview" )
|
||||
if use rust-analyzer; then
|
||||
local analysis="$(grep 'analysis' ./components || die "analysis not found in components")"
|
||||
components+=( "rust-analyzer-preview" "${analysis}" )
|
||||
fi
|
||||
# Rust component 'rust-src' is extracted from separate archive
|
||||
if use rust-src; then
|
||||
einfo "Combining rust and rust-src installers"
|
||||
case ${PV} in
|
||||
*9999*)
|
||||
mv -v "${WORKDIR}/rust-src-nightly/rust-src" "${S}" || die
|
||||
;;
|
||||
*beta*)
|
||||
mv -v "${WORKDIR}/rust-src-beta/rust-src" "${S}" || die
|
||||
;;
|
||||
*)
|
||||
mv -v "${WORKDIR}/rust-src-${PV}/rust-src" "${S}" || die
|
||||
;;
|
||||
esac
|
||||
echo rust-src >> ./components || die
|
||||
components+=( "rust-src" )
|
||||
fi
|
||||
edo ./install.sh \
|
||||
--components="$(IFS=,; echo "${components[*]}")" \
|
||||
--disable-verify \
|
||||
--prefix="${ED}/opt/rust-bin-${SLOT}" \
|
||||
--mandir="${ED}/opt/rust-bin-${SLOT}/man" \
|
||||
--disable-ldconfig
|
||||
|
||||
docompress /opt/${P}/man/
|
||||
|
||||
if use prefix; then
|
||||
local interpreter=$(patchelf --print-interpreter "${EPREFIX}"/bin/bash)
|
||||
ebegin "Changing interpreter to ${interpreter} for Gentoo prefix at ${ED}/opt/rust-bin-${SLOT}/bin"
|
||||
find "${ED}/opt/rust-bin-${SLOT}/bin" -type f -print0 | \
|
||||
while IFS= read -r -d '' filename; do
|
||||
patchelf_for_bin ${filename} ${interpreter} \; || die
|
||||
done
|
||||
eend $?
|
||||
fi
|
||||
|
||||
local symlinks=(
|
||||
cargo
|
||||
rustc
|
||||
rustdoc
|
||||
rust-gdb
|
||||
rust-gdbgui
|
||||
rust-lldb
|
||||
)
|
||||
|
||||
use clippy && symlinks+=( clippy-driver cargo-clippy )
|
||||
use rustfmt && symlinks+=( rustfmt cargo-fmt )
|
||||
use rust-analyzer && symlinks+=( rust-analyzer )
|
||||
|
||||
einfo "installing eselect-rust symlinks and paths"
|
||||
local i
|
||||
for i in "${symlinks[@]}"; do
|
||||
# we need realpath on /usr/bin/* symlink return version-appended binary path.
|
||||
# so /usr/bin/rustc should point to /opt/rust-bin-<ver>/bin/rustc-<ver>
|
||||
local ver_i="${i}-bin-${SLOT}"
|
||||
ln -v "${ED}/opt/rust-bin-${SLOT}/bin/${i}" "${ED}/opt/rust-bin-${SLOT}/bin/${ver_i}" || die
|
||||
dosym -r "/opt/rust-bin-${SLOT}/bin/${ver_i}" "/usr/bin/${ver_i}"
|
||||
done
|
||||
|
||||
# symlinks to switch components to active rust in eselect
|
||||
dosym -r "/opt/rust-bin-${SLOT}/lib" "/usr/lib/rust/lib-bin-${SLOT}"
|
||||
dosym -r "/opt/rust-bin-${SLOT}/man" "/usr/lib/rust/man-bin-${SLOT}"
|
||||
dosym -r "/opt/rust-bin-${SLOT}/lib/rustlib" "/usr/lib/rustlib-bin-${SLOT}"
|
||||
dosym -r "/opt/rust-bin-${SLOT}/share/doc/rust" "/usr/share/doc/rust-bin-${SLOT}"
|
||||
|
||||
# make all capital underscored variable
|
||||
local CARGO_TRIPLET="$(rust_abi)"
|
||||
CARGO_TRIPLET="${CARGO_TRIPLET//-/_}"
|
||||
CARGO_TRIPLET="${CARGO_TRIPLET^^}"
|
||||
cat <<-_EOF_ > "${T}/50${P}"
|
||||
MANPATH="${EPREFIX}/usr/lib/rust/man-bin-${SLOT}"
|
||||
$(usev elibc_musl "CARGO_TARGET_${CARGO_TRIPLET}_RUSTFLAGS=\"-C target-feature=-crt-static\"")
|
||||
_EOF_
|
||||
doenvd "${T}/50${P}"
|
||||
|
||||
# note: eselect-rust adds EROOT to all paths below
|
||||
cat <<-_EOF_ > "${T}/provider-${PN}-${SLOT}"
|
||||
/usr/bin/cargo
|
||||
/usr/bin/rustdoc
|
||||
/usr/bin/rust-gdb
|
||||
/usr/bin/rust-gdbgui
|
||||
/usr/bin/rust-lldb
|
||||
/usr/lib/rustlib
|
||||
/usr/lib/rust/lib
|
||||
/usr/lib/rust/man
|
||||
/usr/share/doc/rust
|
||||
_EOF_
|
||||
|
||||
if use clippy; then
|
||||
echo /usr/bin/clippy-driver >> "${T}/provider-${PN}-${SLOT}"
|
||||
echo /usr/bin/cargo-clippy >> "${T}/provider-${PN}-${SLOT}"
|
||||
fi
|
||||
if use rustfmt; then
|
||||
echo /usr/bin/rustfmt >> "${T}/provider-${PN}-${SLOT}"
|
||||
echo /usr/bin/cargo-fmt >> "${T}/provider-${PN}-${SLOT}"
|
||||
fi
|
||||
if use rust-analyzer; then
|
||||
echo /usr/bin/rust-analyzer >> "${T}/provider-${PN}-${SLOT}"
|
||||
fi
|
||||
|
||||
insinto /etc/env.d/rust
|
||||
doins "${T}/provider-${PN}-${SLOT}"
|
||||
popd >/dev/null || die
|
||||
}
|
||||
|
||||
multilib_src_install() {
|
||||
if multilib_is_native_abi; then
|
||||
rust_native_abi_install
|
||||
else
|
||||
local rust_target version
|
||||
case ${PV} in
|
||||
*9999*)
|
||||
version=nightly
|
||||
;;
|
||||
*beta*)
|
||||
version=beta
|
||||
;;
|
||||
*)
|
||||
version=${PV}
|
||||
;;
|
||||
esac
|
||||
rust_target="$(rust_abi $(get_abi_CHOST ${v##*.}))"
|
||||
dodir "/opt/${P}/lib/rustlib"
|
||||
cp -vr "${WORKDIR}/rust-${version}-${rust_target}/rust-std-${rust_target}/lib/rustlib/${rust_target}"\
|
||||
"${ED}/opt/${P}/lib/rustlib" || die
|
||||
fi
|
||||
|
||||
# BUG: installs x86_64 binary on other arches
|
||||
rm -f "${ED}/opt/${P}/lib/rustlib/"*/bin/rust-llvm-dwp || die
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
eselect rust update
|
||||
|
||||
if has_version dev-debug/gdb || has_version llvm-core/lldb; then
|
||||
elog "Rust installs helper scripts for calling GDB and LLDB,"
|
||||
elog "for convenience they are installed under /usr/bin/rust-{gdb,lldb}-${PV}."
|
||||
fi
|
||||
|
||||
if has_version app-editors/emacs; then
|
||||
optfeature "emacs support for rust" app-emacs/rust-mode
|
||||
fi
|
||||
|
||||
if has_version app-editors/gvim || has_version app-editors/vim; then
|
||||
optfeature "vim support for rust" app-vim/rust-vim
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
eselect rust cleanup
|
||||
}
|
||||
@@ -24,5 +24,7 @@ DIST rustc-1.92.0-src.tar.xz 271887480 BLAKE2B 765e0f216dde8d375e19ca5b1cd3e051b
|
||||
DIST rustc-1.92.0-src.tar.xz.asc 801 BLAKE2B 0d223a763b4a3bf0583c4c2c19b2a30dfbe48b6b06c17a764c894ec29d1d0543201a78a263df3c1314c4ad9e050009e1cacb580633f8c2a8e6b2bf35d9a87fce SHA512 7355e5d641ac6f1d27decdf24dbf4af5640ae4f3177a678f8c040aa7288e660c87ed3de33efdcf4e881691b1c13cd9b2a0b6ff3067892aaed1649a4b73b610df
|
||||
DIST rustc-1.93.0-src.tar.xz 270925104 BLAKE2B f96a05dae3494452471f6797fdc2246cc0f5e8205b2a664da72fcae25399b3729aac6d8c3e0a8ed86daaa7081ca803fb5d58c6fdcf9e1d5c5d598ef9976e1da7 SHA512 9362a4b56529ce29362e256daf382b73c73204d0e9fe5b39addf07ff66a30aa66c967e34df9021ea007c13a9f3bb6efdefca1c8e4ea1bde9aac050a9fb0c736b
|
||||
DIST rustc-1.93.0-src.tar.xz.asc 801 BLAKE2B 9c1762c0bb431da8fda0a8a47f5745998ff31434bb0b2747aa4aafc34e09c1507207eb91b7ba80f7a780b7f7258a4b8e49b5c5b06f9fa9f4cfabf72edb9cb07e SHA512 a6ea05bb6b7d3b429a1c863622c93ac4c97b25f56027f7f06f085acde26d1395f3515cc764ae3ef941d1669556a02365755b34e28ccaebe70c1ccb84c977228f
|
||||
DIST rustc-1.93.1-src.tar.xz 270888296 BLAKE2B fe5a9072161cf758221974f1f59b1a198b2c62b2317360cdb8b2516cfac8eecf40cd5e69bb186053555688a167cabae3a3227b9079c360d238b12c229ff2ddc1 SHA512 fbff2e960e20a5b4c1320bfe22aca445a5792c10f902c6eb69fc7de2a1f8965b06b0906141526a5f0fa02bcbb6b02d80865481bd62656f7b9a11fbdcf5bc9f02
|
||||
DIST rustc-1.93.1-src.tar.xz.asc 801 BLAKE2B 9e059c894770a402d5fee2a29ffdb42030d8d723a40d6312d983e53cd4fa64e97019a0ea6054dcb17ba2ead7f27db17eec2632950f13e4ef1410324afc4dcaf8 SHA512 8a290300e370b3833d2d365a451ed4708dbe1fa69fc57b73eef0b2b5d9dd4fb3d87344315aee3aea474d4071cfb535234e167f6576abf2e06ef3225c85e3c30d
|
||||
DIST rustc-1.94.0_beta20260126-src.tar.xz 273937952 BLAKE2B 14deb9a1a837283ae544c9e05a490d6d2b6fe924838505f22ee821713ada640ec6c11ddc5fdf11bb7925fd4bff0e1399975bbe5ef47c926aab4ed10976db60dc SHA512 3e0517ebd37a9b459a92a432e9c6c7e276878bb8453007ce3b3c1ef53dbee8b436252d09cdfbe4482321076c9b4a0d49a3ab74b6ae845260ce4d4f47112d0b68
|
||||
DIST rustc-1.94.0_beta20260126-src.tar.xz.asc 801 BLAKE2B 6b807dce7ca74cec7cefd7886aa569e0f5a908a9199149624f4d641d94e9daea4ea837a6dd96792efaebd6b21e70acd6654e78f01325e36f9108b0e0b3bc5c4e SHA512 c425b9ff8eeb4973ce3b53eca5cc35f78983062195be9b671565fc48fc7fe2edf424d7618ccc98fec89c2ca8f7f43e176f06c624c1d1172b7033ea66cee6d575
|
||||
|
||||
73
dev-lang/rust-common/rust-common-1.93.1.ebuild
Normal file
73
dev-lang/rust-common/rust-common-1.93.1.ebuild
Normal file
@@ -0,0 +1,73 @@
|
||||
# Copyright 1999-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/rust.asc
|
||||
inherit shell-completion verify-sig
|
||||
|
||||
DESCRIPTION="Common files shared between multiple slots of Rust"
|
||||
HOMEPAGE="https://www.rust-lang.org/"
|
||||
|
||||
if [[ ${PV} = *9999* ]]; then
|
||||
inherit git-r3
|
||||
# In case cargo is not in sync we'll fetch it as a submodule
|
||||
# Nightly users will probably already have the repo cloned and up-to-date anyway.
|
||||
EGIT_REPO_URI="https://github.com/rust-lang/rust.git"
|
||||
EGIT_SUBMODULES=( "-*" "src/tools/cargo" )
|
||||
elif [[ ${PV} == *beta* ]]; then
|
||||
# Identify the snapshot date of the beta release:
|
||||
# curl -Ls static.rust-lang.org/dist/channel-rust-beta.toml | grep beta-src.tar.xz
|
||||
MY_PV=beta
|
||||
betaver=${PV//*beta}
|
||||
BETA_SNAPSHOT="${betaver:0:4}-${betaver:4:2}-${betaver:6:2}"
|
||||
SRC_URI="https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz -> rustc-${PV}-src.tar.xz
|
||||
verify-sig? ( https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz.asc
|
||||
-> rustc-${PV}-src.tar.xz.asc )
|
||||
"
|
||||
S="${WORKDIR}/rustc-${MY_PV}-src"
|
||||
else
|
||||
MY_PV=${PV}
|
||||
SRC_URI="https://static.rust-lang.org/dist/rustc-${PV}-src.tar.xz
|
||||
verify-sig? ( https://static.rust-lang.org/dist/rustc-${PV}-src.tar.xz.asc )
|
||||
"
|
||||
S="${WORKDIR}/rustc-${MY_PV}-src"
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
|
||||
fi
|
||||
|
||||
LICENSE="|| ( MIT Apache-2.0 ) BSD BSD-1 BSD-2 BSD-4"
|
||||
SLOT="0"
|
||||
|
||||
# Legacy non-slotted versions bash completions will collide.
|
||||
RDEPEND="
|
||||
!dev-lang/rust:stable
|
||||
!dev-lang/rust-bin:stable
|
||||
"
|
||||
BDEPEND="verify-sig? ( sec-keys/openpgp-keys-rust )"
|
||||
|
||||
src_unpack() {
|
||||
if [[ ${PV} == *9999* ]]; then
|
||||
git-r3_src_unpack
|
||||
else
|
||||
if use verify-sig ; then
|
||||
verify-sig_verify_detached "${DISTDIR}"/rustc-${PV}-src.tar.xz "${DISTDIR}"/rustc-${PV}-src.tar.xz.asc
|
||||
fi
|
||||
|
||||
# Avoid unpacking the whole tarball which would need check-reqs
|
||||
tar -xf "${DISTDIR}"/rustc-${PV}-src.tar.xz \
|
||||
"rustc-${MY_PV}-src/src/tools/cargo/src/etc/"{_cargo,cargo.bashcomp.sh} || die
|
||||
fi
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
:
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
:
|
||||
}
|
||||
|
||||
src_install() {
|
||||
newbashcomp src/tools/cargo/src/etc/cargo.bashcomp.sh cargo
|
||||
dozshcomp src/tools/cargo/src/etc/_cargo
|
||||
}
|
||||
@@ -20,6 +20,7 @@ DIST rust-patches-1.90.0_p1.tar.bz2 6095 BLAKE2B d94899021a2ad0bd2de00c15a04b6a5
|
||||
DIST rust-patches-1.91.0.tar.bz2 6041 BLAKE2B 7ebc846e0ae7b496b4ed89a8b0a5c397923e4dd6c83a1289e0b98f57477feea35978224b9c4ae19a129282a8c53bdd68f8ab615821f62e4bb5fda8e39b03eeb9 SHA512 fee179ec4e4c90aacfc7f8de2b4d41c80472e1fee17dbfc5ebf384d0fb8ec5afb3f8110a429abaf5a74a924fd1926ab69b29d1b2bafd3b5014b2ad360ca24cce
|
||||
DIST rust-patches-1.92.0_p1.tar.bz2 5993 BLAKE2B aa3183a46834b9442fd79fcda61a308b6b1831c9eab6c5a48c6fca7eef49267af815a3d53c0f17563483dbb58e4c4cb9ab09e4f00c32c37b5411d184e222079b SHA512 c2ec50796e8037b1bb1074c516816c9edc815db503ccac0cde4884a7f190e186897cb91ecbad7e1bb7e34b6753d2ccbbc59e83c8efdff452c1ed446850347000
|
||||
DIST rust-patches-1.93.0.tar.bz2 3175 BLAKE2B 4849208072cf0a047a9fe2ee27d384349b713149b7d087a6ff39a41ec1a7b77884710374dcac44c4378b320da0b4061fa531edd8b2b1cc04199fd51cdb1c2e78 SHA512 b818e14653a66447a221f84363cad54ee893842025c2b6c02c08df76bdf8666664564a5bc405ee988223048c2b986ea818d685babfddee5ff7559f9567bb9dbb
|
||||
DIST rust-patches-1.93.1.tar.bz2 3186 BLAKE2B 6ff137eb2c1b43857922ac3d9b0cc3dbe71180c05d318c5b0f54c371117426ad8daa8ec19cffc19c2550564ac4b7cfd38f4c0fa42a5b8d2ae94fe668a94aa567 SHA512 ded2af5cc9516d8bbce675f323747a96fea814f2344065a45ca7968a21e31aaa5e0bf0a45f6f831a9d62047e782306d5319c6c3ed887e3ceb75011d1849a5303
|
||||
DIST rust-patches-1.94.0_beta20260126.tar.bz2 3173 BLAKE2B 003a78d43575127fcadb423be6d231269753cb75cdc35eb063ff65293031bdfbd32ea91456f454aeeaae5e411aeacbddb388c6b08f079129482bef841277f497 SHA512 1fe20b04d7537d02fbe1d73e348d66543472c7938ee5eb18e283c2185a7e9253ddbf6600c4e56175744d62ba7f453b77624f3aa252bc2c9f07ce797c0bc0707d
|
||||
DIST rustc-1.74.1-src.tar.xz 155968724 BLAKE2B e05f2379ac94b286f85791a138e1928e5b5b5a7749f0981d82c40c2a12860f55bf96bb2f0e924e35a0f8b2447b13052d38adea909aaa3199105787bb5a4861b3 SHA512 14c7e7ed2f38ab60299d8c7d41d78f042b6b57ef822d577b5138e60bdde31cf141eccd4332a25bc5da3d58eb5313d63c1448b5dfe9e11b8055bb8ea133a9038d
|
||||
DIST rustc-1.74.1-src.tar.xz.asc 801 BLAKE2B ddf73175b164233babf31ca3a381b03e20c0f36d017c1d5f85d6ab11f0986d861ab23b11c061e6b2444ced70c3d6a494cc3de4ec86f0deb221a805491bd75420 SHA512 9a96ff9ba9a4e2af4e267b2ec126fc0675c78d0eb767703daa2f28491c3d85c2ab00fbd8584390bf658812ec6c4ab6c57e43b386db59fd505bd3134a8873a09e
|
||||
@@ -65,5 +66,7 @@ DIST rustc-1.92.0-src.tar.xz 271887480 BLAKE2B 765e0f216dde8d375e19ca5b1cd3e051b
|
||||
DIST rustc-1.92.0-src.tar.xz.asc 801 BLAKE2B 0d223a763b4a3bf0583c4c2c19b2a30dfbe48b6b06c17a764c894ec29d1d0543201a78a263df3c1314c4ad9e050009e1cacb580633f8c2a8e6b2bf35d9a87fce SHA512 7355e5d641ac6f1d27decdf24dbf4af5640ae4f3177a678f8c040aa7288e660c87ed3de33efdcf4e881691b1c13cd9b2a0b6ff3067892aaed1649a4b73b610df
|
||||
DIST rustc-1.93.0-src.tar.xz 270925104 BLAKE2B f96a05dae3494452471f6797fdc2246cc0f5e8205b2a664da72fcae25399b3729aac6d8c3e0a8ed86daaa7081ca803fb5d58c6fdcf9e1d5c5d598ef9976e1da7 SHA512 9362a4b56529ce29362e256daf382b73c73204d0e9fe5b39addf07ff66a30aa66c967e34df9021ea007c13a9f3bb6efdefca1c8e4ea1bde9aac050a9fb0c736b
|
||||
DIST rustc-1.93.0-src.tar.xz.asc 801 BLAKE2B 9c1762c0bb431da8fda0a8a47f5745998ff31434bb0b2747aa4aafc34e09c1507207eb91b7ba80f7a780b7f7258a4b8e49b5c5b06f9fa9f4cfabf72edb9cb07e SHA512 a6ea05bb6b7d3b429a1c863622c93ac4c97b25f56027f7f06f085acde26d1395f3515cc764ae3ef941d1669556a02365755b34e28ccaebe70c1ccb84c977228f
|
||||
DIST rustc-1.93.1-src.tar.xz 270888296 BLAKE2B fe5a9072161cf758221974f1f59b1a198b2c62b2317360cdb8b2516cfac8eecf40cd5e69bb186053555688a167cabae3a3227b9079c360d238b12c229ff2ddc1 SHA512 fbff2e960e20a5b4c1320bfe22aca445a5792c10f902c6eb69fc7de2a1f8965b06b0906141526a5f0fa02bcbb6b02d80865481bd62656f7b9a11fbdcf5bc9f02
|
||||
DIST rustc-1.93.1-src.tar.xz.asc 801 BLAKE2B 9e059c894770a402d5fee2a29ffdb42030d8d723a40d6312d983e53cd4fa64e97019a0ea6054dcb17ba2ead7f27db17eec2632950f13e4ef1410324afc4dcaf8 SHA512 8a290300e370b3833d2d365a451ed4708dbe1fa69fc57b73eef0b2b5d9dd4fb3d87344315aee3aea474d4071cfb535234e167f6576abf2e06ef3225c85e3c30d
|
||||
DIST rustc-1.94.0_beta20260126-src.tar.xz 273937952 BLAKE2B 14deb9a1a837283ae544c9e05a490d6d2b6fe924838505f22ee821713ada640ec6c11ddc5fdf11bb7925fd4bff0e1399975bbe5ef47c926aab4ed10976db60dc SHA512 3e0517ebd37a9b459a92a432e9c6c7e276878bb8453007ce3b3c1ef53dbee8b436252d09cdfbe4482321076c9b4a0d49a3ab74b6ae845260ce4d4f47112d0b68
|
||||
DIST rustc-1.94.0_beta20260126-src.tar.xz.asc 801 BLAKE2B 6b807dce7ca74cec7cefd7886aa569e0f5a908a9199149624f4d641d94e9daea4ea837a6dd96792efaebd6b21e70acd6654e78f01325e36f9108b0e0b3bc5c4e SHA512 c425b9ff8eeb4973ce3b53eca5cc35f78983062195be9b671565fc48fc7fe2edf424d7618ccc98fec89c2ca8f7f43e176f06c624c1d1172b7033ea66cee6d575
|
||||
|
||||
890
dev-lang/rust/rust-1.93.1.ebuild
Normal file
890
dev-lang/rust/rust-1.93.1.ebuild
Normal file
@@ -0,0 +1,890 @@
|
||||
# Copyright 1999-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
# Bump notes: https://wiki.gentoo.org/wiki/Project:Rust/Rust_bump
|
||||
|
||||
LLVM_COMPAT=( 21 )
|
||||
PYTHON_COMPAT=( python3_{11..14} )
|
||||
|
||||
# Patches are kept in rust-patches.git, see its README.rst for the versioning
|
||||
# scheme.
|
||||
#
|
||||
# We use _pN from the ebuild version for the patchset but it can be overridden
|
||||
# in the ebuild for changes that don't require a revbump.
|
||||
#
|
||||
# Uncomment this line when the ebuild needs a patchset update but no revbump.
|
||||
#RUST_PATCH_VER=${PV}-1
|
||||
|
||||
RUST_MAX_VER=${PV%%_*}
|
||||
RUST_PV=${PV%%_p*}
|
||||
RUST_P=${PN}-${RUST_PV}
|
||||
[[ -z ${RUST_PATCH_VER} ]] && RUST_PATCH_VER=${PV}
|
||||
|
||||
if [[ ${PV} == *9999* ]]; then
|
||||
# Update this as new `beta` releases come out.
|
||||
RUST_MIN_VER="1.92.0"
|
||||
elif [[ ${PV} == *beta* ]]; then
|
||||
RUST_MIN_VER="$(ver_cut 1).$(($(ver_cut 2) - 1)).0"
|
||||
else
|
||||
RUST_MIN_VER="$(ver_cut 1).$(($(ver_cut 2) - 1)).0"
|
||||
fi
|
||||
|
||||
inherit check-reqs estack flag-o-matic llvm-r1 multiprocessing optfeature
|
||||
inherit multilib multilib-build python-any-r1 rust rust-toolchain toolchain-funcs
|
||||
inherit verify-sig
|
||||
|
||||
if [[ ${PV} = *9999* ]]; then
|
||||
inherit git-r3
|
||||
elif [[ ${PV} == *beta* ]]; then
|
||||
# Identify the snapshot date of the beta release:
|
||||
# curl -Ls static.rust-lang.org/dist/channel-rust-beta.toml | grep beta-src.tar.xz
|
||||
betaver=${PV//*beta}
|
||||
BETA_SNAPSHOT="${betaver:0:4}-${betaver:4:2}-${betaver:6:2}"
|
||||
MY_P="rustc-beta"
|
||||
SRC_URI="
|
||||
https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz -> rustc-${RUST_PV}-src.tar.xz
|
||||
https://gitweb.gentoo.org/proj/rust-patches.git/snapshot/rust-patches-${RUST_PATCH_VER}.tar.bz2
|
||||
verify-sig? (
|
||||
https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz.asc
|
||||
-> rustc-${RUST_PV}-src.tar.xz.asc
|
||||
)
|
||||
"
|
||||
S="${WORKDIR}/${MY_P}-src"
|
||||
else
|
||||
MY_P="rustc-${RUST_PV}"
|
||||
SRC_URI="
|
||||
https://static.rust-lang.org/dist/${MY_P}-src.tar.xz
|
||||
https://gitweb.gentoo.org/proj/rust-patches.git/snapshot/rust-patches-${RUST_PATCH_VER}.tar.bz2
|
||||
verify-sig? ( https://static.rust-lang.org/dist/${MY_P}-src.tar.xz.asc )
|
||||
"
|
||||
S="${WORKDIR}/${MY_P}-src"
|
||||
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
|
||||
fi
|
||||
|
||||
DESCRIPTION="Systems programming language originally developed by Mozilla"
|
||||
HOMEPAGE="https://www.rust-lang.org/"
|
||||
|
||||
# keep in sync with llvm ebuild of the same version as bundled one.
|
||||
ALL_LLVM_TARGETS=( AArch64 AMDGPU ARC ARM AVR BPF CSKY DirectX Hexagon Lanai )
|
||||
ALL_LLVM_TARGETS+=( LoongArch M68k Mips MSP430 NVPTX PowerPC RISCV Sparc SPIRV )
|
||||
ALL_LLVM_TARGETS+=( SystemZ VE WebAssembly X86 XCore Xtensa )
|
||||
ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" )
|
||||
LLVM_TARGET_USEDEPS=${ALL_LLVM_TARGETS[@]/%/(-)?}
|
||||
|
||||
# https://github.com/rust-lang/llvm-project/blob/rustc-1.87.0/llvm/CMakeLists.txt
|
||||
_ALL_RUST_EXPERIMENTAL_TARGETS=( ARC CSKY DirectX M68k Xtensa )
|
||||
declare -A ALL_RUST_EXPERIMENTAL_TARGETS
|
||||
for _x in "${_ALL_RUST_EXPERIMENTAL_TARGETS[@]}"; do
|
||||
ALL_RUST_EXPERIMENTAL_TARGETS["llvm_targets_${_x}"]=0
|
||||
done
|
||||
|
||||
# Bare metal targets which can be built on the host system and have no
|
||||
# dependency on compiler runtime, libc and unwinder.
|
||||
ALL_RUST_SYSROOTS=( bpf wasm )
|
||||
ALL_RUST_SYSROOTS=( "${ALL_RUST_SYSROOTS[@]/#/rust_sysroots_}" )
|
||||
|
||||
LICENSE="|| ( MIT Apache-2.0 ) BSD BSD-1 BSD-2 BSD-4"
|
||||
SLOT="${PV%%_*}" # Beta releases get to share the same SLOT as the eventual stable
|
||||
|
||||
IUSE="big-endian +clippy cpu_flags_x86_sse2 debug dist +doc llvm-libunwind lto"
|
||||
IUSE+=" +rustfmt rust-analyzer rust-src +system-llvm test"
|
||||
IUSE+=" ${ALL_LLVM_TARGETS[*]} ${ALL_RUST_SYSROOTS[*]}"
|
||||
|
||||
if [[ ${PV} = *9999* ]]; then
|
||||
# These USE flags require nightly rust
|
||||
IUSE+=" miri"
|
||||
fi
|
||||
|
||||
LLVM_DEPEND=()
|
||||
# splitting usedeps needed to avoid CI/pkgcheck's UncheckableDep limitation
|
||||
for _x in "${ALL_LLVM_TARGETS[@]}"; do
|
||||
LLVM_DEPEND+=( " ${_x}? ( $(llvm_gen_dep "llvm-core/llvm:\${LLVM_SLOT}[${_x}=]") )" )
|
||||
if [[ -v ALL_RUST_EXPERIMENTAL_TARGETS["${_x}"] ]] ; then
|
||||
ALL_RUST_EXPERIMENTAL_TARGETS["${_x}"]=1
|
||||
fi
|
||||
done
|
||||
LLVM_DEPEND+=( " rust_sysroots_wasm? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') )" )
|
||||
LLVM_DEPEND+=( " $(llvm_gen_dep 'llvm-core/llvm:${LLVM_SLOT}')" )
|
||||
|
||||
# dev-libs/oniguruma is used for documentation
|
||||
BDEPEND="
|
||||
${PYTHON_DEPS}
|
||||
app-eselect/eselect-rust
|
||||
dev-libs/oniguruma
|
||||
|| (
|
||||
>=sys-devel/gcc-4.7[cxx]
|
||||
>=llvm-core/clang-3.5
|
||||
)
|
||||
lto? ( system-llvm? (
|
||||
|| (
|
||||
$(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}')
|
||||
sys-devel/mold
|
||||
)
|
||||
) )
|
||||
rust_sysroots_wasm? ( llvm-core/clang )
|
||||
!system-llvm? (
|
||||
>=dev-build/cmake-3.13.4
|
||||
app-alternatives/ninja
|
||||
)
|
||||
test? ( dev-debug/gdb )
|
||||
verify-sig? ( sec-keys/openpgp-keys-rust )
|
||||
"
|
||||
|
||||
DEPEND="
|
||||
>=app-arch/xz-utils-5.2
|
||||
net-misc/curl:=[http2,ssl]
|
||||
virtual/zlib:=
|
||||
dev-libs/openssl:0=
|
||||
system-llvm? (
|
||||
${LLVM_DEPEND[*]}
|
||||
llvm-libunwind? ( llvm-runtimes/libunwind:= )
|
||||
)
|
||||
!system-llvm? (
|
||||
!llvm-libunwind? (
|
||||
elibc_musl? ( sys-libs/libunwind:= )
|
||||
)
|
||||
)
|
||||
"
|
||||
|
||||
RDEPEND="
|
||||
${DEPEND}
|
||||
app-eselect/eselect-rust
|
||||
dev-lang/rust-common
|
||||
sys-apps/lsb-release
|
||||
!dev-lang/rust:stable
|
||||
!dev-lang/rust-bin:stable
|
||||
"
|
||||
|
||||
REQUIRED_USE="
|
||||
|| ( ${ALL_LLVM_TARGETS[*]} )
|
||||
rust-analyzer? ( rust-src )
|
||||
test? ( ${ALL_LLVM_TARGETS[*]} )
|
||||
rust_sysroots_bpf? ( llvm_targets_BPF )
|
||||
rust_sysroots_wasm? ( llvm_targets_WebAssembly )
|
||||
x86? ( cpu_flags_x86_sse2 )
|
||||
"
|
||||
|
||||
# we don't use cmake.eclass, but can get a warning
|
||||
CMAKE_WARN_UNUSED_CLI=no
|
||||
|
||||
QA_FLAGS_IGNORED="
|
||||
usr/lib/${PN}/${SLOT}/bin/.*
|
||||
usr/lib/${PN}/${SLOT}/libexec/.*
|
||||
usr/lib/${PN}/${SLOT}/lib/lib.*.so
|
||||
usr/lib/${PN}/${SLOT}/lib/rustlib/.*/bin/.*
|
||||
usr/lib/${PN}/${SLOT}/lib/rustlib/.*/lib/lib.*.so
|
||||
"
|
||||
|
||||
QA_SONAME="
|
||||
usr/lib/${PN}/${SLOT}/lib/lib.*.so.*
|
||||
usr/lib/${PN}/${SLOT}/lib/rustlib/.*/lib/lib.*.so
|
||||
"
|
||||
|
||||
QA_PRESTRIPPED="
|
||||
usr/lib/${PN}/${SLOT}/lib/rustlib/.*/bin/rust-llvm-dwp
|
||||
usr/lib/${PN}/${SLOT}/lib/rustlib/.*/lib/self-contained/crtn.o
|
||||
"
|
||||
|
||||
# An rmeta file is custom binary format that contains the metadata for the crate.
|
||||
# rmeta files do not support linking, since they do not contain compiled object files.
|
||||
# so we can safely silence the warning for this QA check.
|
||||
QA_EXECSTACK="usr/lib/${PN}/${SLOT}/lib/rustlib/*/lib*.rlib:lib.rmeta"
|
||||
|
||||
# causes double bootstrap
|
||||
RESTRICT="test"
|
||||
|
||||
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/rust.asc
|
||||
|
||||
clear_vendor_checksums() {
|
||||
sed -i 's/\("files":{\)[^}]*/\1/' "vendor/${1}/.cargo-checksum.json" || die
|
||||
}
|
||||
|
||||
toml_usex() {
|
||||
usex "${1}" true false
|
||||
}
|
||||
|
||||
pre_build_checks() {
|
||||
local M=9216
|
||||
# multiply requirements by 1.3 if we are doing x86-multilib
|
||||
if use amd64; then
|
||||
M=$(( $(usex abi_x86_32 13 10) * ${M} / 10 ))
|
||||
fi
|
||||
M=$(( $(usex clippy 128 0) + ${M} ))
|
||||
if [[ ${PV} == *9999* ]]; then
|
||||
M=$(( $(usex miri 128 0) + ${M} ))
|
||||
fi
|
||||
M=$(( $(usex rustfmt 256 0) + ${M} ))
|
||||
# add 2G if we compile llvm and 256M per llvm_target
|
||||
if ! use system-llvm; then
|
||||
M=$(( 2048 + ${M} ))
|
||||
local ltarget
|
||||
for ltarget in ${ALL_LLVM_TARGETS[@]}; do
|
||||
M=$(( $(usex ${ltarget} 256 0) + ${M} ))
|
||||
done
|
||||
fi
|
||||
M=$(( $(usex rust_sysroots_bpf 256 0) + ${M} ))
|
||||
M=$(( $(usex rust_sysroots_wasm 256 0) + ${M} ))
|
||||
M=$(( $(usex debug 2 1) * ${M} ))
|
||||
eshopts_push -s extglob
|
||||
if is-flagq '-g?(gdb)?([1-9])'; then
|
||||
M=$(( 15 * ${M} / 10 ))
|
||||
fi
|
||||
eshopts_pop
|
||||
M=$(( $(usex doc 256 0) + ${M} ))
|
||||
CHECKREQS_DISK_BUILD=${M}M check-reqs_pkg_${EBUILD_PHASE}
|
||||
}
|
||||
|
||||
llvm_check_deps() {
|
||||
has_version -r "llvm-core/llvm:${LLVM_SLOT}[${LLVM_TARGET_USEDEPS// /,}]"
|
||||
}
|
||||
|
||||
# Is LLVM being linked against libc++?
|
||||
is_libcxx_linked() {
|
||||
local code='#include <ciso646>
|
||||
#if defined(_LIBCPP_VERSION)
|
||||
HAVE_LIBCXX
|
||||
#endif
|
||||
'
|
||||
local out=$($(tc-getCXX) ${CXXFLAGS} ${CPPFLAGS} -x c++ -E -P - <<<"${code}") || return 1
|
||||
[[ ${out} == *HAVE_LIBCXX* ]]
|
||||
}
|
||||
|
||||
pkg_pretend() {
|
||||
pre_build_checks
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
pre_build_checks
|
||||
python-any-r1_pkg_setup
|
||||
|
||||
export LIBGIT2_NO_PKG_CONFIG=1 #749381
|
||||
if tc-is-cross-compiler; then
|
||||
use system-llvm && die "USE=system-llvm not allowed when cross-compiling"
|
||||
local cross_llvm_target="$(llvm_tuple_to_target "${CBUILD}")"
|
||||
use "llvm_targets_${cross_llvm_target}" || \
|
||||
die "Must enable LLVM_TARGETS=${cross_llvm_target} matching CBUILD=${CBUILD} when cross-compiling"
|
||||
fi
|
||||
|
||||
rust_pkg_setup
|
||||
|
||||
if use system-llvm; then
|
||||
llvm-r1_pkg_setup
|
||||
|
||||
local llvm_config="$(get_llvm_prefix)/bin/llvm-config"
|
||||
export LLVM_LINK_SHARED=1
|
||||
export RUSTFLAGS="${RUSTFLAGS} -Lnative=$("${llvm_config}" --libdir)"
|
||||
fi
|
||||
}
|
||||
|
||||
rust_live_get_sources() {
|
||||
EGIT_REPO_URI="
|
||||
https://anongit.gentoo.org/git/proj/rust-patches.git
|
||||
"
|
||||
EGIT_CHECKOUT_DIR="${WORKDIR}/rust-patches-${RUST_PATCH_VER}"
|
||||
git-r3_src_unpack
|
||||
|
||||
EGIT_REPO_URI="
|
||||
https://github.com/rust-lang/rust.git
|
||||
"
|
||||
EGIT_SUBMODULES=(
|
||||
"*"
|
||||
"-src/gcc"
|
||||
)
|
||||
S="${WORKDIR}/rust"
|
||||
EGIT_CHECKOUT_DIR="${S}"
|
||||
git-r3_src_unpack
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
if [[ ${PV} == *9999* ]] ; then
|
||||
rust_live_get_sources
|
||||
|
||||
# Vendor dependencies
|
||||
mkdir "${S}/.cargo" || die # The vendor script has a check for .cargo/config{,.toml}
|
||||
touch "${S}/.cargo/bootstrap.toml" || die
|
||||
local rust_stage0_root="$(${RUSTC} --print sysroot || die "Can't determine rust's sysroot")"
|
||||
# Configure vendor to use the portage-provided toolchain. This prevents it from
|
||||
# attempting to fetch a `beta` toolchain from the internet.
|
||||
cat <<- _EOF_ > "${T}/vendor-bootstrap.toml"
|
||||
# Suppresses a warning about tracking changes which we don't care about.
|
||||
change-id = "ignore"
|
||||
[build]
|
||||
build = "$(rust_abi "${CBUILD}")"
|
||||
host = ["$(rust_abi "${CHOST}")"]
|
||||
target = ["$(rust_abi "${CHOST}")"]
|
||||
cargo = "${rust_stage0_root}/bin/cargo"
|
||||
rustc = "${rust_stage0_root}/bin/rustc"
|
||||
rustfmt = "${rust_stage0_root}/bin/rustfmt"
|
||||
_EOF_
|
||||
# We're using git sources so we need to run the Vendor script
|
||||
# to ensure that all dependencies are present and up-to-date
|
||||
mkdir "${S}/vendor" || die
|
||||
# This also compiles the 'build helper', there's no way to avoid this.
|
||||
${EPYTHON} "${S}"/x.py vendor -v --config="${T}"/vendor-bootstrap.toml -j$(makeopts_jobs) ||
|
||||
die "Failed to vendor dependencies"
|
||||
# TODO: This has to be generated somehow, this is from a 1.84.x tarball I had lying around.
|
||||
cat <<- _EOF_ > "${S}/.cargo/config.toml"
|
||||
[source.crates-io]
|
||||
replace-with = "vendored-sources"
|
||||
|
||||
[source."git+https://github.com/rust-lang/team"]
|
||||
git = "https://github.com/rust-lang/team"
|
||||
replace-with = "vendored-sources"
|
||||
|
||||
[source.vendored-sources]
|
||||
directory = "vendor"
|
||||
_EOF_
|
||||
elif use verify-sig ; then
|
||||
# Patch tarballs are not signed (but we trust Gentoo infra)
|
||||
verify-sig_verify_detached "${DISTDIR}"/rustc-${RUST_PV}-src.tar.xz{,.asc}
|
||||
default
|
||||
else
|
||||
default
|
||||
fi
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Commit patches to the appropriate branch in proj/rust-patches.git
|
||||
# then cut a new tag / tarball. Don't add patches to ${FILESDIR}
|
||||
PATCHES=(
|
||||
"${WORKDIR}/rust-patches-${RUST_PATCH_VER}/"
|
||||
)
|
||||
|
||||
if use lto && tc-is-clang && ! tc-ld-is-lld && ! tc-ld-is-mold; then
|
||||
export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld"
|
||||
fi
|
||||
|
||||
default
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
if tc-is-cross-compiler; then
|
||||
export PKG_CONFIG_ALLOW_CROSS=1
|
||||
export PKG_CONFIG_PATH="${ESYSROOT}/usr/$(get_libdir)/pkgconfig"
|
||||
export OPENSSL_INCLUDE_DIR="${ESYSROOT}/usr/include"
|
||||
export OPENSSL_LIB_DIR="${ESYSROOT}/usr/$(get_libdir)"
|
||||
fi
|
||||
|
||||
# Avoid bundled copies of libraries
|
||||
export RUSTONIG_SYSTEM_LIBONIG=1
|
||||
# Need to check if these can be optional
|
||||
#export LIBSQLITE3_SYS_USE_PKG_CONFIG=1
|
||||
#export LIBSSH2_SYS_USE_PKG_CONFIG=1
|
||||
|
||||
filter-lto # https://bugs.gentoo.org/862109 https://bugs.gentoo.org/866231
|
||||
|
||||
local rust_target="" rust_targets="" arch_cflags
|
||||
|
||||
# Collect rust target names to compile standard libs for all ABIs.
|
||||
for v in $(multilib_get_enabled_abi_pairs); do
|
||||
rust_targets+=",\"$(rust_abi $(get_abi_CHOST ${v##*.}))\""
|
||||
done
|
||||
if use rust_sysroots_bpf; then
|
||||
rust_targets+=",\"bpfeb-unknown-none\",\"bpfel-unknown-none\""
|
||||
fi
|
||||
if use rust_sysroots_wasm; then
|
||||
rust_targets+=",\"wasm32-unknown-unknown\""
|
||||
if use system-llvm; then
|
||||
# un-hardcode rust-lld linker for this target
|
||||
# https://bugs.gentoo.org/715348
|
||||
sed -i '/linker:/ s/rust-lld/wasm-ld/' compiler/rustc_target/src/spec/base/wasm.rs || die
|
||||
fi
|
||||
fi
|
||||
rust_targets="${rust_targets#,}"
|
||||
|
||||
# cargo and rustdoc are mandatory and should always be included
|
||||
local tools='"cargo","rustdoc"'
|
||||
use clippy && tools+=',"clippy"'
|
||||
use rustfmt && tools+=',"rustfmt"'
|
||||
use rust-analyzer && tools+=',"rust-analyzer","rust-analyzer-proc-macro-srv"'
|
||||
use rust-src && tools+=',"src"'
|
||||
|
||||
if [[ ${PV} == *9999* ]]; then
|
||||
use miri && tools+=',"miri"'
|
||||
fi
|
||||
|
||||
local rust_stage0_root="$(${RUSTC} --print sysroot || die "Can't determine rust's sysroot")"
|
||||
# in case of prefix it will be already prefixed, as --print sysroot returns full path
|
||||
[[ -d ${rust_stage0_root} ]] || die "${rust_stage0_root} is not a directory"
|
||||
|
||||
rust_target="$(rust_abi)"
|
||||
rust_build="$(rust_abi "${CBUILD}")"
|
||||
rust_host="$(rust_abi "${CHOST}")"
|
||||
|
||||
RUST_EXPERIMENTAL_TARGETS=()
|
||||
for _x in "${!ALL_RUST_EXPERIMENTAL_TARGETS[@]}"; do
|
||||
if [[ ${ALL_RUST_EXPERIMENTAL_TARGETS[${_x}]} == 1 ]] && use ${_x} ; then
|
||||
RUST_EXPERIMENTAL_TARGETS+=( ${_x#llvm_targets_} )
|
||||
fi
|
||||
done
|
||||
RUST_EXPERIMENTAL_TARGETS=${RUST_EXPERIMENTAL_TARGETS[@]}
|
||||
|
||||
local cm_btype="$(usex debug DEBUG RELEASE)"
|
||||
local build_channel
|
||||
local build_miri="false"
|
||||
case "${PV}" in
|
||||
*9999*)
|
||||
build_channel="nightly"
|
||||
;;
|
||||
*beta*)
|
||||
build_channel="beta"
|
||||
;;
|
||||
*)
|
||||
build_channel="stable"
|
||||
;;
|
||||
esac
|
||||
|
||||
# TODO: Add optimized-compiler-builtins for system-llvm to avoid
|
||||
# building bundled compiler-rt.
|
||||
cat <<- _EOF_ > "${S}"/bootstrap.toml
|
||||
# Suppresses a warning about tracking changes which we don't care about.
|
||||
change-id = "ignore"
|
||||
# https://github.com/rust-lang/rust/issues/135358 (bug #947897)
|
||||
profile = "dist"
|
||||
[llvm]
|
||||
download-ci-llvm = false
|
||||
optimize = $(toml_usex !debug)
|
||||
release-debuginfo = $(toml_usex debug)
|
||||
assertions = $(toml_usex debug)
|
||||
ninja = true
|
||||
targets = "${LLVM_TARGETS// /;}"
|
||||
experimental-targets = "${RUST_EXPERIMENTAL_TARGETS// /;}"
|
||||
link-shared = $(toml_usex system-llvm)
|
||||
$(if is_libcxx_linked; then
|
||||
# https://bugs.gentoo.org/732632
|
||||
echo "use-libcxx = true"
|
||||
echo "static-libstdcpp = false"
|
||||
fi)
|
||||
$(case "${rust_target}" in
|
||||
i586-*-linux-*)
|
||||
# https://github.com/rust-lang/rust/issues/93059
|
||||
echo 'cflags = "-fcf-protection=none"'
|
||||
echo 'cxxflags = "-fcf-protection=none"'
|
||||
echo 'ldflags = "-fcf-protection=none"'
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac)
|
||||
enable-warnings = false
|
||||
[llvm.build-config]
|
||||
CMAKE_VERBOSE_MAKEFILE = "ON"
|
||||
$(if ! tc-is-cross-compiler; then
|
||||
# When cross-compiling, LLVM is compiled twice, once for host and
|
||||
# once for target. Unfortunately, this build configuration applies
|
||||
# to both, which means any flags applicable to one target but not
|
||||
# the other will break. Conditionally disable respecting user
|
||||
# flags when cross-compiling.
|
||||
echo "CMAKE_C_FLAGS_${cm_btype} = \"${CFLAGS}\""
|
||||
echo "CMAKE_CXX_FLAGS_${cm_btype} = \"${CXXFLAGS}\""
|
||||
echo "CMAKE_EXE_LINKER_FLAGS_${cm_btype} = \"${LDFLAGS}\""
|
||||
echo "CMAKE_MODULE_LINKER_FLAGS_${cm_btype} = \"${LDFLAGS}\""
|
||||
echo "CMAKE_SHARED_LINKER_FLAGS_${cm_btype} = \"${LDFLAGS}\""
|
||||
echo "CMAKE_STATIC_LINKER_FLAGS_${cm_btype} = \"${ARFLAGS}\""
|
||||
fi)
|
||||
[build]
|
||||
build-stage = 2
|
||||
test-stage = 2
|
||||
build = "${rust_build}"
|
||||
host = ["${rust_host}"]
|
||||
target = [${rust_targets}]
|
||||
cargo = "${rust_stage0_root}/bin/cargo"
|
||||
rustc = "${rust_stage0_root}/bin/rustc"
|
||||
rustfmt = "${rust_stage0_root}/bin/rustfmt"
|
||||
description = "gentoo"
|
||||
docs = $(toml_usex doc)
|
||||
compiler-docs = false
|
||||
submodules = false
|
||||
python = "${EPYTHON}"
|
||||
locked-deps = true
|
||||
vendor = true
|
||||
extended = true
|
||||
tools = [${tools}]
|
||||
verbose = 2
|
||||
sanitizers = false
|
||||
profiler = true
|
||||
cargo-native-static = false
|
||||
[install]
|
||||
prefix = "${EPREFIX}/usr/lib/${PN}/${SLOT}"
|
||||
sysconfdir = "etc"
|
||||
docdir = "share/doc/rust"
|
||||
bindir = "bin"
|
||||
libdir = "lib"
|
||||
mandir = "share/man"
|
||||
[rust]
|
||||
# https://github.com/rust-lang/rust/issues/54872
|
||||
codegen-units-std = 1
|
||||
optimize = true
|
||||
debug = $(toml_usex debug)
|
||||
debug-assertions = $(toml_usex debug)
|
||||
debug-assertions-std = $(toml_usex debug)
|
||||
debuginfo-level = $(usex debug 2 0)
|
||||
debuginfo-level-rustc = $(usex debug 2 0)
|
||||
debuginfo-level-std = $(usex debug 2 0)
|
||||
debuginfo-level-tools = $(usex debug 2 0)
|
||||
debuginfo-level-tests = 0
|
||||
backtrace = true
|
||||
incremental = false
|
||||
$(if ! tc-is-cross-compiler; then
|
||||
echo "default-linker = \"${CHOST}-cc\""
|
||||
fi)
|
||||
channel = "${build_channel}"
|
||||
rpath = true
|
||||
verbose-tests = true
|
||||
optimize-tests = $(toml_usex !debug)
|
||||
codegen-tests = true
|
||||
omit-git-hash = false
|
||||
dist-src = false
|
||||
remap-debuginfo = true
|
||||
lld = $(usex system-llvm false $(toml_usex rust_sysroots_wasm))
|
||||
$(if use lto && tc-is-clang && ! tc-ld-is-mold; then
|
||||
echo "use-lld = true"
|
||||
fi)
|
||||
# only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it
|
||||
# https://github.com/rust-lang/rust/issues/74976
|
||||
# https://github.com/rust-lang/rust/issues/76526
|
||||
deny-warnings = $(usex rust_sysroots_wasm $(usex doc false true) true)
|
||||
backtrace-on-ice = true
|
||||
jemalloc = false
|
||||
# See https://github.com/rust-lang/rust/issues/121124
|
||||
lto = "$(usex lto thin off)"
|
||||
[dist]
|
||||
src-tarball = false
|
||||
compression-formats = ["xz"]
|
||||
compression-profile = "balanced"
|
||||
_EOF_
|
||||
|
||||
for v in $(multilib_get_enabled_abi_pairs); do
|
||||
rust_target=$(rust_abi $(get_abi_CHOST ${v##*.}))
|
||||
arch_cflags="$(get_abi_CFLAGS ${v##*.})"
|
||||
|
||||
export CFLAGS_${rust_target//-/_}="${arch_cflags}"
|
||||
|
||||
cat <<- _EOF_ >> "${S}"/bootstrap.toml
|
||||
[target.${rust_target}]
|
||||
ar = "$(tc-getAR)"
|
||||
cc = "$(tc-getCC)"
|
||||
cxx = "$(tc-getCXX)"
|
||||
linker = "$(tc-getCC)"
|
||||
ranlib = "$(tc-getRANLIB)"
|
||||
llvm-libunwind = "$(usex llvm-libunwind $(usex system-llvm system in-tree) no)"
|
||||
_EOF_
|
||||
if use system-llvm; then
|
||||
cat <<- _EOF_ >> "${S}"/bootstrap.toml
|
||||
llvm-config = "$(get_llvm_prefix)/bin/llvm-config"
|
||||
_EOF_
|
||||
fi
|
||||
# by default librustc_target/spec/linux_musl_base.rs sets base.crt_static_default = true;
|
||||
# but we patch it and set to false here as well
|
||||
if use elibc_musl; then
|
||||
cat <<- _EOF_ >> "${S}"/bootstrap.toml
|
||||
crt-static = false
|
||||
musl-root = "$($(tc-getCC) -print-sysroot)/usr"
|
||||
_EOF_
|
||||
fi
|
||||
done
|
||||
if use rust_sysroots_wasm; then
|
||||
wasm_target="wasm32-unknown-unknown"
|
||||
if tc-is-clang; then
|
||||
local wasm_cc=$(tc-getCC)
|
||||
local wasm_cxx=$(tc-getCXX)
|
||||
else
|
||||
local wasm_cc=${CHOST}-clang
|
||||
local wasm_cxx=${CHOST}-clang++
|
||||
fi
|
||||
export CFLAGS_${wasm_target//-/_}="$(
|
||||
CC="${wasm_cc} --target=wasm32-unknown-unknown"
|
||||
filter-flags '-mcpu*' '-march*' '-mtune*'
|
||||
strip-unsupported-flags
|
||||
echo "${CFLAGS}"
|
||||
)"
|
||||
cat <<- _EOF_ >> "${S}"/bootstrap.toml
|
||||
[target.wasm32-unknown-unknown]
|
||||
cc = "${wasm_cc}"
|
||||
cxx = "${wasm_cxx}"
|
||||
linker = "$(usex system-llvm lld rust-lld)"
|
||||
# wasm target does not have profiler_builtins https://bugs.gentoo.org/848483
|
||||
profiler = false
|
||||
_EOF_
|
||||
fi
|
||||
|
||||
if [[ -n ${I_KNOW_WHAT_I_AM_DOING_CROSS} ]]; then # whitespace intentionally shifted below
|
||||
# experimental cross support
|
||||
# discussion: https://bugs.gentoo.org/679878
|
||||
# TODO: c*flags, clang, system-llvm, cargo.eclass target support
|
||||
# it would be much better if we could split out stdlib
|
||||
# complilation to separate ebuild and abuse CATEGORY to
|
||||
# just install to /usr/lib/rustlib/<target>
|
||||
|
||||
# extra targets defined as a bash array
|
||||
# spec format: <LLVM target>:<rust-target>:<CTARGET>
|
||||
# best place would be /etc/portage/env/dev-lang/rust
|
||||
# Example:
|
||||
# RUST_CROSS_TARGETS=(
|
||||
# "AArch64:aarch64-unknown-linux-gnu:aarch64-unknown-linux-gnu"
|
||||
# )
|
||||
# no extra hand holding is done, no target transformations, all
|
||||
# values are passed as-is with just basic checks, so it's up to user to supply correct values
|
||||
# valid rust targets can be obtained with
|
||||
# rustc --print target-list
|
||||
# matching cross toolchain has to be installed
|
||||
# matching LLVM_TARGET has to be enabled for both rust and llvm (if using system one)
|
||||
# only gcc toolchains installed with crossdev are checked for now.
|
||||
|
||||
# BUG: we can't pass host flags to cross compiler, so just filter for now
|
||||
# BUG: this should be more fine-grained.
|
||||
filter-flags '-mcpu=*' '-march=*' '-mtune=*'
|
||||
|
||||
local cross_target_spec
|
||||
for cross_target_spec in "${RUST_CROSS_TARGETS[@]}";do
|
||||
# extracts first element form <LLVM target>:<rust-target>:<CTARGET>
|
||||
local cross_llvm_target="${cross_target_spec%%:*}"
|
||||
# extracts toolchain triples, <rust-target>:<CTARGET>
|
||||
local cross_triples="${cross_target_spec#*:}"
|
||||
# extracts first element after before : separator
|
||||
local cross_rust_target="${cross_triples%%:*}"
|
||||
# extracts last element after : separator
|
||||
local cross_toolchain="${cross_triples##*:}"
|
||||
use llvm_targets_${cross_llvm_target} || die "need llvm_targets_${cross_llvm_target} target enabled"
|
||||
command -v ${cross_toolchain}-gcc > /dev/null 2>&1 || die "need ${cross_toolchain} cross toolchain"
|
||||
|
||||
cat <<- _EOF_ >> "${S}"/bootstrap.toml
|
||||
[target.${cross_rust_target}]
|
||||
ar = "${cross_toolchain}-ar"
|
||||
cc = "${cross_toolchain}-gcc"
|
||||
cxx = "${cross_toolchain}-g++"
|
||||
linker = "${cross_toolchain}-gcc"
|
||||
ranlib = "${cross_toolchain}-ranlib"
|
||||
_EOF_
|
||||
if use system-llvm; then
|
||||
cat <<- _EOF_ >> "${S}"/bootstrap.toml
|
||||
llvm-config = "$(get_llvm_prefix)/bin/llvm-config"
|
||||
_EOF_
|
||||
fi
|
||||
if [[ "${cross_toolchain}" == *-musl* ]]; then
|
||||
cat <<- _EOF_ >> "${S}"/bootstrap.toml
|
||||
musl-root = "$(${cross_toolchain}-gcc -print-sysroot)/usr"
|
||||
_EOF_
|
||||
fi
|
||||
if [[ "${cross_rust_target}" == *-uefi ]]; then
|
||||
# Profiler is not supported on bare-metal
|
||||
cat <<- _EOF_ >> "${S}"/bootstrap.toml
|
||||
profiler = false
|
||||
_EOF_
|
||||
fi
|
||||
|
||||
# append cross target to "normal" target list
|
||||
# example 'target = ["powerpc64le-unknown-linux-gnu"]'
|
||||
# becomes 'target = ["powerpc64le-unknown-linux-gnu","aarch64-unknown-linux-gnu"]'
|
||||
|
||||
rust_targets="${rust_targets},\"${cross_rust_target}\""
|
||||
sed -i "/^target = \[/ s#\[.*\]#\[${rust_targets}\]#" bootstrap.toml || die
|
||||
|
||||
ewarn
|
||||
ewarn "Enabled ${cross_rust_target} rust target"
|
||||
ewarn "Using ${cross_toolchain} cross toolchain"
|
||||
ewarn
|
||||
if ! has_version -b 'sys-devel/binutils[multitarget]' ; then
|
||||
ewarn "'sys-devel/binutils[multitarget]' is not installed"
|
||||
ewarn "'strip' will be unable to strip cross libraries"
|
||||
ewarn "cross targets will be installed with full debug information"
|
||||
ewarn "enable 'multitarget' USE flag for binutils to be able to strip object files"
|
||||
ewarn
|
||||
ewarn "Alternatively llvm-strip can be used, it supports stripping any target"
|
||||
ewarn "define STRIP=\"llvm-strip\" to use it (experimental)"
|
||||
ewarn
|
||||
fi
|
||||
done
|
||||
fi # I_KNOW_WHAT_I_AM_DOING_CROSS
|
||||
|
||||
einfo "Rust configured with the following flags:"
|
||||
echo
|
||||
echo RUSTFLAGS="\"${RUSTFLAGS}\""
|
||||
echo RUSTFLAGS_BOOTSTRAP="\"${RUSTFLAGS_BOOTSTRAP}\""
|
||||
echo RUSTFLAGS_NOT_BOOTSTRAP="\"${RUSTFLAGS_NOT_BOOTSTRAP}\""
|
||||
echo MAGIC_EXTRA_RUSTFLAGS="\"${MAGIC_EXTRA_RUSTFLAGS}\""
|
||||
env | grep "CARGO_TARGET_.*_RUSTFLAGS="
|
||||
env | grep "CFLAGS_.*"
|
||||
echo
|
||||
einfo "bootstrap.toml contents:"
|
||||
cat "${S}"/bootstrap.toml || die
|
||||
echo
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
# -v will show invocations, -vv "very verbose" is overkill, -vvv "very very verbose" is insane
|
||||
RUST_BACKTRACE=1 "${EPYTHON}" ./x.py build -v --config="${S}"/bootstrap.toml -j$(makeopts_jobs) || die
|
||||
}
|
||||
|
||||
src_test() {
|
||||
# https://rustc-dev-guide.rust-lang.org/tests/intro.html
|
||||
|
||||
# those are basic and codegen tests.
|
||||
local tests=(
|
||||
codegen
|
||||
codegen-units
|
||||
compile-fail
|
||||
incremental
|
||||
mir-opt
|
||||
pretty
|
||||
run-make
|
||||
)
|
||||
|
||||
# fails if llvm is not built with ALL targets.
|
||||
# and known to fail with system llvm sometimes.
|
||||
use system-llvm || tests+=( assembly )
|
||||
|
||||
# fragile/expensive/less important tests
|
||||
# or tests that require extra builds
|
||||
# TODO: instead of skipping, just make some nonfatal.
|
||||
if [[ ${ERUST_RUN_EXTRA_TESTS:-no} != no ]]; then
|
||||
tests+=(
|
||||
rustdoc
|
||||
rustdoc-js
|
||||
rustdoc-js-std
|
||||
rustdoc-ui
|
||||
run-make-fulldeps
|
||||
ui
|
||||
ui-fulldeps
|
||||
)
|
||||
fi
|
||||
|
||||
local i failed=()
|
||||
einfo "rust_src_test: enabled tests ${tests[@]/#/src/test/}"
|
||||
for i in "${tests[@]}"; do
|
||||
local t="src/test/${i}"
|
||||
einfo "rust_src_test: running ${t}"
|
||||
if ! RUST_BACKTRACE=1 "${EPYTHON}" ./x.py test -vv --config="${S}"/bootstrap.toml \
|
||||
-j$(makeopts_jobs) --no-doc --no-fail-fast "${t}"
|
||||
then
|
||||
failed+=( "${t}" )
|
||||
eerror "rust_src_test: ${t} failed"
|
||||
fi
|
||||
done
|
||||
|
||||
if [[ ${#failed[@]} -ne 0 ]]; then
|
||||
eerror "rust_src_test: failure summary: ${failed[@]}"
|
||||
die "aborting due to test failures"
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
DESTDIR="${D}" "${EPYTHON}" ./x.py install -v --config="${S}"/bootstrap.toml -j$(makeopts_jobs) || die
|
||||
|
||||
docompress /usr/lib/${PN}/${SLOT}/share/man/
|
||||
|
||||
# bash-completion files are installed by dev-lang/rust-common instead
|
||||
# bug #689562, #689160.
|
||||
rm -v "${ED}/usr/lib/${PN}/${SLOT}/etc/bash_completion.d/cargo" || die
|
||||
rmdir -v "${ED}/usr/lib/${PN}/${SLOT}/etc/bash_completion.d" || die
|
||||
|
||||
local symlinks=(
|
||||
cargo
|
||||
rustc
|
||||
rustdoc
|
||||
rust-gdb
|
||||
rust-gdbgui
|
||||
rust-lldb
|
||||
)
|
||||
|
||||
use clippy && symlinks+=( clippy-driver cargo-clippy )
|
||||
if [[ ${PV} = *9999* ]]; then
|
||||
use miri && symlinks+=( miri cargo-miri )
|
||||
fi
|
||||
use rustfmt && symlinks+=( rustfmt cargo-fmt )
|
||||
use rust-analyzer && symlinks+=( rust-analyzer )
|
||||
|
||||
einfo "installing eselect-rust symlinks and paths: ${symlinks[@]}"
|
||||
local i
|
||||
for i in "${symlinks[@]}"; do
|
||||
# we need realpath on /usr/bin/* symlink return version-appended binary path.
|
||||
# so /usr/bin/rustc should point to /usr/lib/rust/<ver>/bin/rustc-<ver>
|
||||
# need to fix eselect-rust to remove this hack.
|
||||
local ver_i="${i}-${RUST_PV%%_*}"
|
||||
if [[ -f "${ED}/usr/lib/${PN}/${SLOT}/bin/${i}" ]]; then
|
||||
einfo "Installing ${i} symlink"
|
||||
ln -v "${ED}/usr/lib/${PN}/${SLOT}/bin/${i}" "${ED}/usr/lib/${PN}/${SLOT}/bin/${ver_i}" || die
|
||||
else
|
||||
ewarn "${i} symlink requested, but source file not found"
|
||||
ewarn "please report this"
|
||||
fi
|
||||
dosym "../lib/${PN}/${SLOT}/bin/${ver_i}" "/usr/bin/${ver_i}"
|
||||
done
|
||||
|
||||
# symlinks to switch components to active rust in eselect
|
||||
dosym "${SLOT}/lib" "/usr/lib/${PN}/lib-${SLOT}"
|
||||
use rust-analyzer && dosym "${SLOT}/libexec" "/usr/lib/${PN}/libexec-${SLOT}"
|
||||
dosym "${SLOT}/share/man" "/usr/lib/${PN}/man-${SLOT}"
|
||||
dosym "rust/${SLOT}/lib/rustlib" "/usr/lib/rustlib-${SLOT}"
|
||||
dosym "../../lib/${PN}/${SLOT}/share/doc/rust" "/usr/share/doc/${RUST_P}"
|
||||
|
||||
newenvd - "50${RUST_P}" <<-_EOF_
|
||||
MANPATH="${EPREFIX}/usr/lib/rust/man-${SLOT}"
|
||||
_EOF_
|
||||
|
||||
rm -rf "${ED}/usr/lib/${PN}/${SLOT}"/*.old || die
|
||||
rm -rf "${ED}/usr/lib/${PN}/${SLOT}/bin"/*.old || die
|
||||
rm -rf "${ED}/usr/lib/${PN}/${SLOT}/doc"/*.old || die
|
||||
|
||||
# note: eselect-rust adds EROOT to all paths below
|
||||
cat <<-_EOF_ > "${T}/provider-${PN}-${SLOT}"
|
||||
/usr/bin/cargo
|
||||
/usr/bin/rustdoc
|
||||
/usr/bin/rust-gdb
|
||||
/usr/bin/rust-gdbgui
|
||||
/usr/bin/rust-lldb
|
||||
/usr/lib/rustlib
|
||||
/usr/lib/rust/lib
|
||||
/usr/lib/rust/man
|
||||
/usr/share/doc/rust
|
||||
_EOF_
|
||||
|
||||
if use clippy; then
|
||||
echo /usr/bin/clippy-driver >> "${T}/provider-${RUST_P}"
|
||||
echo /usr/bin/cargo-clippy >> "${T}/provider-${RUST_P}"
|
||||
fi
|
||||
if [[ ${SLOT} == *9999* ]] && use miri; then
|
||||
echo /usr/bin/miri >> "${T}/provider-${RUST_P}"
|
||||
echo /usr/bin/cargo-miri >> "${T}/provider-${RUST_P}"
|
||||
fi
|
||||
if use rustfmt; then
|
||||
echo /usr/bin/rustfmt >> "${T}/provider-${RUST_P}"
|
||||
echo /usr/bin/cargo-fmt >> "${T}/provider-${RUST_P}"
|
||||
fi
|
||||
if use rust-analyzer; then
|
||||
echo /usr/lib/rust/libexec >> "${T}/provider-${RUST_P}"
|
||||
echo /usr/bin/rust-analyzer >> "${T}/provider-${RUST_P}"
|
||||
fi
|
||||
|
||||
insinto /etc/env.d/rust
|
||||
doins "${T}/provider-${PN}-${SLOT}"
|
||||
|
||||
if use dist; then
|
||||
"${EPYTHON}" ./x.py dist -v --config="${S}"/bootstrap.toml -j$(makeopts_jobs) || die
|
||||
insinto "/usr/lib/${PN}/${SLOT}/dist"
|
||||
doins -r "${S}/build/dist/."
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
eselect rust update
|
||||
|
||||
if has_version dev-debug/gdb || has_version llvm-core/lldb; then
|
||||
elog "Rust installs helper scripts for calling GDB and LLDB,"
|
||||
elog "for convenience they are installed under /usr/bin/rust-{gdb,lldb}-${RUST_PV}."
|
||||
fi
|
||||
|
||||
if has_version app-editors/emacs; then
|
||||
optfeature "emacs support for rust" app-emacs/rust-mode
|
||||
fi
|
||||
|
||||
if has_version app-editors/gvim || has_version app-editors/vim; then
|
||||
optfeature "vim support for rust" app-vim/rust-vim
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
eselect rust cleanup
|
||||
}
|
||||
8
dev-util/esbuild/Manifest
Normal file
8
dev-util/esbuild/Manifest
Normal file
@@ -0,0 +1,8 @@
|
||||
DIST esbuild-0.25.1-vendor.tar.xz 285316 BLAKE2B cb6504562c9d93b19d68dcab1692769bd70d353e71083f7fb817bf1f014c46535664755fee72a7006d2c95b67988b7c665f1f0a6d472ca95737313df32b144a6 SHA512 759583dab5d6f859599bfe39768a5dad19a73ffb551d4a8c869c791440190ce0ea298894764626ad783baea4da319fda1a65fb425f187821f11f4999f3c797cb
|
||||
DIST esbuild-0.25.1.tar.gz 1934119 BLAKE2B bc580f830f9a955d09e96bfbab93f4bece51bef7f6eb80a2e348526ac8bf47d8d83f42e9f05355df195e7bff026dc8e25d6573f9e3d1049ce513759d8287ce37 SHA512 61616bbf2fbdbd1eb298a465180971a07f09eeb172a16cf1bd0e1315aec4fc9ac8f447991b4d25226cb1ba8758ad9efaf5f1e86608918107f89467edbc1ff498
|
||||
DIST esbuild-0.25.2-vendor.tar.xz 285548 BLAKE2B e53afa7f1a9e4c5dc4bc2340be0565518bbd90fb558ee657cc598c2e48796693dd0125db3460e30278707ce50d7d83c8e38c835b83629dcb1f0db94aad255d47 SHA512 419f1e94c82f0aa40fb6d7e3f540d5924df92758e8a88056232a76c564f9223de07462dc73966a92fd839d8a38144e5a7bc1a8c861edacd2cd3b6722b095ac04
|
||||
DIST esbuild-0.25.2.tar.gz 1938735 BLAKE2B 98ebf2dce4c5715eba2b749ea7f6f00d5fcf6daf8f22ded970ec41df9676d1ca40d6185dab03a9bf6d7931489d2e5aca0c510c991dfc80294826c57b216921da SHA512 6e1a868de7c1b6c672175a1f0eef42bcf04f236a00d21e23dd8935accd80d1accacb53cb1ead0edfabdb0dc0e5440907ee070aa061779c2c9faa57f94935152c
|
||||
DIST esbuild-0.25.5-vendor.tar.xz 285372 BLAKE2B 0539694a0c059282effb9fd670e8539bbca05d3be80adba4dea752140b85719b2fdd9f82643b9f8315b19a2613b73137d3e8f9701759fcb9cd649cc6e19bdbe8 SHA512 debd700f35ca99d4e52385d3332e592d50c2e03eb63c48981ec21b229acb68e49009d14d795ff10d18eedc30d4ac8ba612d95fcb6419b975d2c9953838f7f5ed
|
||||
DIST esbuild-0.25.5.tar.gz 1946445 BLAKE2B 4eb9200fe2fd3667a5965241aa9daa401ae2e11fce8cd90074c61da9cd2e1072ba10a17f74463e7d333b965c45131a654febf4c3c87cd1249ba0c188019ae705 SHA512 70ca6398f026b67d0b32fd17652dbfe13e8de741a9017555d499a0e606279b0ad4536f1912d6aacc9c41ac518ef5421a07a42b957a028f8f95dc5e415dbaa2f0
|
||||
DIST esbuild-0.27.3-vendor.tar.xz 285712 BLAKE2B 404a4c078e3f3ac3f965f0cfe3b979d5103d1d36d4d690d44a7f0f89c6f6f3ade3f0f3dc7c1f60e36269542956d6b313e6da43be56b752bf058f2dabd4861d3d SHA512 98dde208b529d2eabbb8dc675b3f2a9af347d5d24282d7a408252a0c28b0fdc0acabb74038c8049b323ec0fc53f9ee692a822f869df770d5671aee2414623981
|
||||
DIST esbuild-0.27.3.tar.gz 1983973 BLAKE2B b9a3f3d5c573e64e983d87d49de4b677aaab3f71d5c3dd32b22956833c407129a82b7caf4b2b5025dae95d56edec42acbf4f8f61c0b6860d0c29ee1e007c448e SHA512 169861c528ffb4943b8c7074017e1b65d97c3b598eb7be355e9842ce40ea75393e6ecc40a29e6a9d865175b354a5c74e18f3b024c480a3a09446a66db4ee02a4
|
||||
34
dev-util/esbuild/esbuild-0.25.1.ebuild
Normal file
34
dev-util/esbuild/esbuild-0.25.1.ebuild
Normal file
@@ -0,0 +1,34 @@
|
||||
# Copyright 2025-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
: ${ESBUILD_VENDOR_TARBALL:=1}
|
||||
|
||||
inherit go-module
|
||||
|
||||
DESCRIPTION="A modern, extremely fast, JavaScript and CSS bundler and minifier"
|
||||
HOMEPAGE="https://esbuild.github.io/"
|
||||
SRC_URI="https://github.com/evanw/esbuild/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
if [[ ${ESBUILD_VENDOR_TARBALL} -eq 1 ]]; then
|
||||
SRC_URI+=" https://deps.gentoo.zip/dev-util/esbuild/esbuild-${PV}-vendor.tar.xz"
|
||||
fi
|
||||
|
||||
LICENSE="BSD MIT"
|
||||
SLOT="${PV}"
|
||||
KEYWORDS="~amd64 ~arm64"
|
||||
|
||||
RESTRICT="test" # tests require more work, but chromium needs esbuild already.
|
||||
|
||||
src_compile() {
|
||||
# Build using vendored dependencies instead of Makefile
|
||||
ego build -mod=vendor -v -ldflags="-s -w" ./cmd/esbuild
|
||||
}
|
||||
|
||||
src_install() {
|
||||
newbin esbuild esbuild-${PV}
|
||||
}
|
||||
|
||||
src_test() {
|
||||
ego test -mod=vendor -v -ldflags="-s -w" ./cmd/esbuild
|
||||
}
|
||||
30
dev-util/esbuild/esbuild-0.25.2.ebuild
Normal file
30
dev-util/esbuild/esbuild-0.25.2.ebuild
Normal file
@@ -0,0 +1,30 @@
|
||||
# Copyright 2025-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
: ${ESBUILD_VENDOR_TARBALL:=1}
|
||||
|
||||
inherit go-module
|
||||
|
||||
DESCRIPTION="A modern, extremely fast, JavaScript and CSS bundler and minifier"
|
||||
HOMEPAGE="https://esbuild.github.io/"
|
||||
SRC_URI="https://github.com/evanw/esbuild/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
if [[ ${ESBUILD_VENDOR_TARBALL} -eq 1 ]]; then
|
||||
SRC_URI+=" https://deps.gentoo.zip/dev-util/esbuild/esbuild-${PV}-vendor.tar.xz"
|
||||
fi
|
||||
|
||||
LICENSE="BSD MIT"
|
||||
SLOT="${PV}"
|
||||
KEYWORDS="~amd64 ~arm64"
|
||||
|
||||
RESTRICT="test"
|
||||
|
||||
src_compile() {
|
||||
# Build using vendored dependencies instead of Makefile
|
||||
ego build -mod=vendor -v -ldflags="-s -w" ./cmd/esbuild
|
||||
}
|
||||
|
||||
src_install() {
|
||||
newbin esbuild esbuild-${PV}
|
||||
}
|
||||
30
dev-util/esbuild/esbuild-0.25.5.ebuild
Normal file
30
dev-util/esbuild/esbuild-0.25.5.ebuild
Normal file
@@ -0,0 +1,30 @@
|
||||
# Copyright 2025-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
: ${ESBUILD_VENDOR_TARBALL:=1}
|
||||
|
||||
inherit go-module
|
||||
|
||||
DESCRIPTION="A modern, extremely fast, JavaScript and CSS bundler and minifier"
|
||||
HOMEPAGE="https://esbuild.github.io/"
|
||||
SRC_URI="https://github.com/evanw/esbuild/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
if [[ ${ESBUILD_VENDOR_TARBALL} -eq 1 ]]; then
|
||||
SRC_URI+=" https://deps.gentoo.zip/dev-util/esbuild/esbuild-${PV}-vendor.tar.xz"
|
||||
fi
|
||||
|
||||
LICENSE="BSD MIT"
|
||||
SLOT="${PV}"
|
||||
KEYWORDS="~amd64 ~arm64"
|
||||
|
||||
RESTRICT="test"
|
||||
|
||||
src_compile() {
|
||||
# Build using vendored dependencies instead of Makefile
|
||||
ego build -mod=vendor -v -ldflags="-s -w" ./cmd/esbuild
|
||||
}
|
||||
|
||||
src_install() {
|
||||
newbin esbuild esbuild-${PV}
|
||||
}
|
||||
34
dev-util/esbuild/esbuild-0.27.3.ebuild
Normal file
34
dev-util/esbuild/esbuild-0.27.3.ebuild
Normal file
@@ -0,0 +1,34 @@
|
||||
# Copyright 2025-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
: ${ESBUILD_VENDOR_TARBALL:=1}
|
||||
|
||||
inherit go-module
|
||||
|
||||
DESCRIPTION="A modern, extremely fast, JavaScript and CSS bundler and minifier"
|
||||
HOMEPAGE="https://esbuild.github.io/"
|
||||
SRC_URI="https://github.com/evanw/esbuild/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
if [[ ${ESBUILD_VENDOR_TARBALL} -eq 1 ]]; then
|
||||
SRC_URI+=" https://deps.gentoo.zip/dev-util/esbuild/esbuild-${PV}-vendor.tar.xz"
|
||||
fi
|
||||
|
||||
LICENSE="BSD MIT"
|
||||
SLOT="${PV}"
|
||||
KEYWORDS="~amd64 ~arm64"
|
||||
|
||||
RESTRICT="test" # tests require more work, but chromium needs esbuild already.
|
||||
|
||||
src_compile() {
|
||||
# Build using vendored dependencies instead of Makefile
|
||||
ego build -mod=vendor -v -ldflags="-s -w" ./cmd/esbuild
|
||||
}
|
||||
|
||||
src_install() {
|
||||
newbin esbuild esbuild-${PV}
|
||||
}
|
||||
|
||||
src_test() {
|
||||
ego test -mod=vendor -v -ldflags="-s -w" ./cmd/esbuild
|
||||
}
|
||||
20
dev-util/esbuild/metadata.xml
Normal file
20
dev-util/esbuild/metadata.xml
Normal file
@@ -0,0 +1,20 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer type="person">
|
||||
<email>kangie@gentoo.org</email>
|
||||
<description>Primary maintainer</description>
|
||||
</maintainer>
|
||||
<maintainer type="project">
|
||||
<email>chromium@gentoo.org</email>
|
||||
<name>Gentoo Chromium Project</name>
|
||||
</maintainer>
|
||||
<longdescription>
|
||||
The main goal of the esbuild bundler project is to bring about a
|
||||
new era of build tool performance, and create an easy-to-use
|
||||
modern bundler along the way.
|
||||
</longdescription>
|
||||
<upstream>
|
||||
<remote-id type="github">evanw/esbuild</remote-id>
|
||||
</upstream>
|
||||
</pkgmetadata>
|
||||
@@ -69,6 +69,7 @@ fi
|
||||
declare -A -g -r _RUST_LLVM_MAP=(
|
||||
["9999"]=22
|
||||
["1.94.0"]=21
|
||||
["1.93.1"]=21
|
||||
["1.93.0"]=21
|
||||
["1.92.0"]=21
|
||||
["1.91.0"]=21
|
||||
@@ -102,6 +103,7 @@ declare -A -g -r _RUST_LLVM_MAP=(
|
||||
declare -a -g -r _RUST_SLOTS_ORDERED=(
|
||||
"9999"
|
||||
"1.94.0"
|
||||
"1.93.1"
|
||||
"1.93.0"
|
||||
"1.92.0"
|
||||
"1.91.0"
|
||||
|
||||
@@ -9,7 +9,7 @@ inherit ecm frameworks.kde.org
|
||||
DESCRIPTION="Framework for network service discovery using Zeroconf"
|
||||
|
||||
LICENSE="LGPL-2+"
|
||||
KEYWORDS="amd64 arm64 ~ppc64 ~x86"
|
||||
KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
DEPEND="
|
||||
|
||||
@@ -89,6 +89,8 @@ llvm-runtimes/libcxxabi clang
|
||||
# done
|
||||
dev-lang/rust:1.94.0 llvm_slot_21
|
||||
dev-lang/rust-bin:1.94.0 llvm_slot_21
|
||||
dev-lang/rust:1.93.1 llvm_slot_21
|
||||
dev-lang/rust-bin:1.93.1 llvm_slot_21
|
||||
dev-lang/rust:1.93.0 llvm_slot_21
|
||||
dev-lang/rust-bin:1.93.0 llvm_slot_21
|
||||
dev-lang/rust:1.92.0 llvm_slot_21
|
||||
|
||||
@@ -24,5 +24,7 @@ DIST rustc-1.92.0-src.tar.xz 271887480 BLAKE2B 765e0f216dde8d375e19ca5b1cd3e051b
|
||||
DIST rustc-1.92.0-src.tar.xz.asc 801 BLAKE2B 0d223a763b4a3bf0583c4c2c19b2a30dfbe48b6b06c17a764c894ec29d1d0543201a78a263df3c1314c4ad9e050009e1cacb580633f8c2a8e6b2bf35d9a87fce SHA512 7355e5d641ac6f1d27decdf24dbf4af5640ae4f3177a678f8c040aa7288e660c87ed3de33efdcf4e881691b1c13cd9b2a0b6ff3067892aaed1649a4b73b610df
|
||||
DIST rustc-1.93.0-src.tar.xz 270925104 BLAKE2B f96a05dae3494452471f6797fdc2246cc0f5e8205b2a664da72fcae25399b3729aac6d8c3e0a8ed86daaa7081ca803fb5d58c6fdcf9e1d5c5d598ef9976e1da7 SHA512 9362a4b56529ce29362e256daf382b73c73204d0e9fe5b39addf07ff66a30aa66c967e34df9021ea007c13a9f3bb6efdefca1c8e4ea1bde9aac050a9fb0c736b
|
||||
DIST rustc-1.93.0-src.tar.xz.asc 801 BLAKE2B 9c1762c0bb431da8fda0a8a47f5745998ff31434bb0b2747aa4aafc34e09c1507207eb91b7ba80f7a780b7f7258a4b8e49b5c5b06f9fa9f4cfabf72edb9cb07e SHA512 a6ea05bb6b7d3b429a1c863622c93ac4c97b25f56027f7f06f085acde26d1395f3515cc764ae3ef941d1669556a02365755b34e28ccaebe70c1ccb84c977228f
|
||||
DIST rustc-1.93.1-src.tar.xz 270888296 BLAKE2B fe5a9072161cf758221974f1f59b1a198b2c62b2317360cdb8b2516cfac8eecf40cd5e69bb186053555688a167cabae3a3227b9079c360d238b12c229ff2ddc1 SHA512 fbff2e960e20a5b4c1320bfe22aca445a5792c10f902c6eb69fc7de2a1f8965b06b0906141526a5f0fa02bcbb6b02d80865481bd62656f7b9a11fbdcf5bc9f02
|
||||
DIST rustc-1.93.1-src.tar.xz.asc 801 BLAKE2B 9e059c894770a402d5fee2a29ffdb42030d8d723a40d6312d983e53cd4fa64e97019a0ea6054dcb17ba2ead7f27db17eec2632950f13e4ef1410324afc4dcaf8 SHA512 8a290300e370b3833d2d365a451ed4708dbe1fa69fc57b73eef0b2b5d9dd4fb3d87344315aee3aea474d4071cfb535234e167f6576abf2e06ef3225c85e3c30d
|
||||
DIST rustc-1.94.0_beta20260126-src.tar.xz 273937952 BLAKE2B 14deb9a1a837283ae544c9e05a490d6d2b6fe924838505f22ee821713ada640ec6c11ddc5fdf11bb7925fd4bff0e1399975bbe5ef47c926aab4ed10976db60dc SHA512 3e0517ebd37a9b459a92a432e9c6c7e276878bb8453007ce3b3c1ef53dbee8b436252d09cdfbe4482321076c9b4a0d49a3ab74b6ae845260ce4d4f47112d0b68
|
||||
DIST rustc-1.94.0_beta20260126-src.tar.xz.asc 801 BLAKE2B 6b807dce7ca74cec7cefd7886aa569e0f5a908a9199149624f4d641d94e9daea4ea837a6dd96792efaebd6b21e70acd6654e78f01325e36f9108b0e0b3bc5c4e SHA512 c425b9ff8eeb4973ce3b53eca5cc35f78983062195be9b671565fc48fc7fe2edf424d7618ccc98fec89c2ca8f7f43e176f06c624c1d1172b7033ea66cee6d575
|
||||
|
||||
180
sys-devel/rust-std/rust-std-1.93.1.ebuild
Normal file
180
sys-devel/rust-std/rust-std-1.93.1.ebuild
Normal file
@@ -0,0 +1,180 @@
|
||||
# Copyright 2020-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
PYTHON_COMPAT=( python3_{11..13} )
|
||||
|
||||
inherit edo flag-o-matic multiprocessing python-any-r1 rust-toolchain toolchain-funcs verify-sig
|
||||
|
||||
DESCRIPTION="Rust standard library, standalone (for crossdev)"
|
||||
HOMEPAGE="https://www.rust-lang.org"
|
||||
|
||||
if [[ ${PV} = *9999* ]]; then
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/rust-lang/rust.git"
|
||||
EGIT_SUBMODULES=(
|
||||
"*"
|
||||
"-src/gcc"
|
||||
)
|
||||
elif [[ ${PV} == *beta* ]]; then
|
||||
# Identify the snapshot date of the beta release:
|
||||
# curl -Ls static.rust-lang.org/dist/channel-rust-beta.toml | grep beta-src.tar.xz
|
||||
betaver=${PV//*beta}
|
||||
BETA_SNAPSHOT="${betaver:0:4}-${betaver:4:2}-${betaver:6:2}"
|
||||
MY_P="rustc-beta"
|
||||
SRC_URI="https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz -> rustc-${PV}-src.tar.xz
|
||||
verify-sig? ( https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz.asc
|
||||
-> rustc-${PV}-src.tar.xz.asc )
|
||||
"
|
||||
S="${WORKDIR}/${MY_P}-src"
|
||||
else
|
||||
MY_P="rustc-${PV}"
|
||||
SRC_URI="https://static.rust-lang.org/dist/${MY_P}-src.tar.xz
|
||||
verify-sig? ( https://static.rust-lang.org/dist/${MY_P}-src.tar.xz.asc )
|
||||
"
|
||||
S="${WORKDIR}/${MY_P}-src"
|
||||
fi
|
||||
|
||||
LICENSE="|| ( MIT Apache-2.0 ) BSD-1 BSD-2 BSD-4"
|
||||
SLOT="stable/$(ver_cut 1-2)"
|
||||
# please do not keyword
|
||||
#KEYWORDS="" #nowarn
|
||||
IUSE="debug"
|
||||
|
||||
BDEPEND="
|
||||
${PYTHON_DEPS}
|
||||
~dev-lang/rust-${PV}:=
|
||||
verify-sig? ( sec-keys/openpgp-keys-rust )
|
||||
"
|
||||
DEPEND="||
|
||||
(
|
||||
>="${CATEGORY}"/gcc-4.7:*
|
||||
>="${CATEGORY/sys-devel/llvm-core}"/clang-3.5:*
|
||||
)
|
||||
"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
# need full compiler to run tests
|
||||
RESTRICT="test"
|
||||
|
||||
VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/rust.asc
|
||||
|
||||
QA_FLAGS_IGNORED="usr/lib/rust/${PV}/rustlib/.*/lib/lib.*.so"
|
||||
|
||||
#
|
||||
# The cross magic
|
||||
#
|
||||
export CTARGET=${CTARGET:-${CHOST}}
|
||||
if [[ ${CTARGET} == ${CHOST} ]] ; then
|
||||
if [[ ${CATEGORY} == cross-* ]] ; then
|
||||
export CTARGET=${CATEGORY#cross-}
|
||||
fi
|
||||
fi
|
||||
|
||||
is_cross() {
|
||||
[[ ${CHOST} != ${CTARGET} ]]
|
||||
}
|
||||
|
||||
toml_usex() {
|
||||
usex "$1" true false
|
||||
}
|
||||
|
||||
pkg_pretend() {
|
||||
is_cross || die "${PN} should only be used for cross"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
python-any-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
default
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
# do the great cleanup
|
||||
strip-flags
|
||||
filter-flags '-mcpu=*' '-march=*' '-mtune=*' '-m32' '-m64'
|
||||
strip-unsupported-flags
|
||||
|
||||
local rust_root x
|
||||
rust_root="$(rustc --print sysroot)"
|
||||
rtarget="$(rust_abi ${CTARGET})"
|
||||
rtarget="${ERUST_STD_RTARGET:-${rtarget}}" # some targets need to be custom.
|
||||
rbuild="$(rust_abi ${CBUILD})"
|
||||
rhost="$(rust_abi ${CHOST})"
|
||||
|
||||
echo
|
||||
for x in CATEGORY rust_root rbuild rhost rtarget RUSTFLAGS CFLAGS CXXFLAGS LDFLAGS; do
|
||||
einfo "$(printf '%10s' ${x^^}:) ${!x}"
|
||||
done
|
||||
|
||||
cat <<- EOF > "${S}"/bootstrap.toml
|
||||
[build]
|
||||
build = "${rbuild}"
|
||||
host = ["${rhost}"]
|
||||
target = ["${rtarget}"]
|
||||
cargo = "${rust_root}/bin/cargo"
|
||||
rustc = "${rust_root}/bin/rustc"
|
||||
submodules = false
|
||||
local-rebuild = true
|
||||
python = "${EPYTHON}"
|
||||
locked-deps = true
|
||||
vendor = true
|
||||
extended = true
|
||||
verbose = 2
|
||||
cargo-native-static = false
|
||||
[install]
|
||||
prefix = "${EPREFIX}/usr/lib/${PN}/${PV}"
|
||||
sysconfdir = "etc"
|
||||
docdir = "share/doc/rust"
|
||||
bindir = "bin"
|
||||
libdir = "lib"
|
||||
mandir = "share/man"
|
||||
[rust]
|
||||
# https://github.com/rust-lang/rust/issues/54872
|
||||
codegen-units-std = 1
|
||||
optimize = true
|
||||
debug = $(toml_usex debug)
|
||||
debug-assertions = $(toml_usex debug)
|
||||
debuginfo-level-rustc = 0
|
||||
backtrace = true
|
||||
incremental = false
|
||||
default-linker = "$(tc-getCC)"
|
||||
rpath = false
|
||||
dist-src = false
|
||||
remap-debuginfo = true
|
||||
jemalloc = false
|
||||
[dist]
|
||||
src-tarball = false
|
||||
[target.${rtarget}]
|
||||
ar = "$(tc-getAR ${CTARGET})"
|
||||
cc = "$(tc-getCC ${CTARGET})"
|
||||
cxx = "$(tc-getCXX ${CTARGET})"
|
||||
linker = "$(tc-getCC ${CTARGET})"
|
||||
ranlib = "$(tc-getRANLIB ${CTARGET})"
|
||||
$(usev elibc_musl 'crt-static = false')
|
||||
EOF
|
||||
|
||||
einfo "${PN^} configured with the following settings:"
|
||||
cat "${S}"/bootstrap.toml || die
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
edo env RUST_BACKTRACE=1 \
|
||||
"${EPYTHON}" ./x.py build -vv --config="${S}"/bootstrap.toml -j$(makeopts_jobs) \
|
||||
library/std --stage 0
|
||||
}
|
||||
|
||||
src_test() {
|
||||
ewarn "${PN} can't run tests"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
local rustlib="lib/rust/${PV}/lib/rustlib"
|
||||
dodir "/usr/${rustlib}"
|
||||
pushd "build/${rhost}/stage0-sysroot/lib/rustlib" > /dev/null || die
|
||||
cp -pPRv "${rtarget}" "${ED}/usr/${rustlib}" || die
|
||||
popd > /dev/null || die
|
||||
}
|
||||
@@ -2,3 +2,4 @@ DIST chromedriver-bin-141.0.7390.107.linux64.zip 9444876 BLAKE2B 7a7b0e91eb63f36
|
||||
DIST chromedriver-bin-142.0.7444.175.linux64.zip 9462388 BLAKE2B 173a497f80548789adff605a62e406b66dd62251dddea93a86446699ef42a961430d58d1382573a9b39341333c3096092b992e1eacdc7246004dd620e2f1e948 SHA512 a22149a6cb313f4120895696fe63137503523be5bd3dd122b52321cd5d8a700b7402bff83addb991e3c57182be262bc0172686d86e1c937790c575d324fd4621
|
||||
DIST chromedriver-bin-143.0.7499.169.linux64.zip 9462910 BLAKE2B db18a68c7867b70975c1bf55e8735a506ae17a144c7ca1186f5b4fdeea71818e1599e387718e5dfd1b4509484cf888191faf6de429a838d0f7e53d107fbfec73 SHA512 a7659fa0be40ead1fa88621b909ae2905502307a75972e572c8bb1050fcfa5967d602d7e4fdca0f3abf0c5c23385965ed654c9211c25346e8f784e76d0b86deb
|
||||
DIST chromedriver-bin-144.0.7559.132.linux64.zip 9721507 BLAKE2B 4eed32fa6c1f6c6d6386bee3f1db6eced95b9475d04327cc4823c7ed9406791e3217e0109d019edc136001e8e9cd542d8b14e7e9762eb1220fcb2255f8b4e6ba SHA512 86d5125844d2f4e764b70f89b2a4eb233c56317db0cddee3db8b59289c24f1f8944dc346ad061efaf018998f81ffa3d2eeeab8fcd047e120fc8821d34077c75e
|
||||
DIST chromedriver-bin-145.0.7632.67.linux64.zip 9661503 BLAKE2B 79099c74a17226845db7d2cbf3052e33cfe0a5aa1f2aff7ad5d69f3b26f17938bce98659a1ba015c0dfd6d6be7eeaf77bade02e3628c634b6a4e58422b11b673 SHA512 d7994afbc2913f0ab8a206f072d833a1c654e130a1448323f34285772c60e0ff41911af113d73de9918b5fdb3615509631106af82f56e5f8841c8234b6d92309
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
# Copyright 1999-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
# See https://googlechromelabs.github.io/chrome-for-testing/#stable for URLs
|
||||
DESCRIPTION="WebDriver for Chrome"
|
||||
HOMEPAGE="https://sites.google.com/corp/chromium.org/driver/"
|
||||
SRC_URI="amd64? ( https://storage.googleapis.com/chrome-for-testing-public/${PV}/linux64/chromedriver-linux64.zip -> ${P}.linux64.zip )"
|
||||
S="${WORKDIR}/chromedriver-linux64"
|
||||
|
||||
LICENSE="google-chrome"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64"
|
||||
RESTRICT="bindist mirror strip"
|
||||
|
||||
RDEPEND="
|
||||
sys-libs/glibc
|
||||
www-client/google-chrome
|
||||
!www-client/chromium
|
||||
"
|
||||
BDEPEND="app-arch/unzip"
|
||||
|
||||
QA_PREBUILT="usr/bin/chromedriver"
|
||||
|
||||
src_install() {
|
||||
dobin chromedriver
|
||||
}
|
||||
@@ -3,7 +3,7 @@ DIST chromium-138.0.7204.157-linux.tar.xz 1555757520 BLAKE2B d46405fdb3e1e2bb919
|
||||
DIST chromium-143.0.7499.109-linux.tar.xz 1140751164 BLAKE2B 2d92edef264b5d3145e952e6f8b2a986c8adb6ef47c2a0ddf6c5acb6cdd0d47144123a8e15944c4a22fb42177f9e6c7e84ea3ab6f6bb17dc464ff9c3e9c2c851 SHA512 9d9a24f9e424b8121c73edc8c5ad685447ccfc67d29878cc3b248eed86273702a0f26eb91ed501d492f165de1319bfdaed7a4071f2a9e7cfd7551f845b066f65
|
||||
DIST chromium-144.0.7559.109-linux.tar.xz 1292530744 BLAKE2B 08101a0433f52a9537d879be638b4a5b7dac9a2df63de23b53c4a9f45e3fbc5d4726f7255010d07aaabdbc6367eddbe15eabbfe09bb415c7d2aad6ee34be7c15 SHA512 72c199078007585f93d666c85fd4538e907365c1ecee6c1d41d9f7d31fb302ff3e01586591a7806529561f0dd64acf82d899d5199564b15ab5c7e575d68b25b9
|
||||
DIST chromium-144.0.7559.132-linux.tar.xz 1292631752 BLAKE2B 6d54992b9314f9f4b3691e9369f722143c640f535adba40f6ba8ff4bace6ab5142b96151e38d11b1e85c28f6c828eab20722d4a84623988042c50754e4d422ef SHA512 df0137ca6f8235ee89ec45ad2747d4f475972bf47bdd5a9db5893b32ec61ae4c62e5825581ad8454644b6e16fe631e416c727400e40adf65c103f49bac302ad0
|
||||
DIST chromium-145.0.7632.45-linux.tar.xz 1416448168 BLAKE2B 97b40e84d1cfdee8384611f75c1e42e9b8aad0eb75cb7cdfe103da915674cda022ea3010db58983e9ee4e1d39d17cfbf877c76abcdd27a9797483aabdc774769 SHA512 14b1b89a3b82577313673df8f98d476fc7442138aa20917bdee1e4fc02bfb1ba075bc9551ca07c82b7e2fe54b659cf4bd3e1a860cfab2761763662f580db25a4
|
||||
DIST chromium-145.0.7632.67-linux.tar.xz 1416526708 BLAKE2B 5b8e7b952443a68824d039292d6f13dac0a4fb6cba3d35cbedfeba404f92cede0c2aef71d165c8c83c086055a7a74c3b4f7d6e458ee9a54e14d33dd7f1aaccc3 SHA512 5bc7a683b8fb261051871193b48f83341b094407e47ded4ee1ff6e5dcaec7c1496be394a6a3bc2af476a668b30b029de2a99ecdfd0de3766343359568aca0704
|
||||
DIST chromium-clang-llvmorg-21-init-11777-gfd3fecfc-1.tar.xz 272 BLAKE2B 4423dd821d8ad88aad0ae734551defa28362d4ad3f263ef0e525d57f4266108ea58661749c8b82403426b25ae4ea189021dfbb016fad280d4ef18d3b48f43a46 SHA512 76158ad6a30c9905dd3a1044125114e90d6cbc74eabe38a0c49e07e5f52813615074bd22088578b91a763b5186e924c322e9fce5281b672e2748cd563c9cfad8
|
||||
DIST chromium-clang-llvmorg-22-init-14273-gea10026b-2.tar.xz 56526480 BLAKE2B ed3c838ab171c4b54a8a51316d84e6fcbaa7189cbfc700918be99920399b1ebb00b69288b5b85699d6307dc7c0728f392707893079be2ba34cfd00cd32015b77 SHA512 94c7d595b04442dcb82a26b3fb58188a85cd97b059fc64c7617c565be3e9a69b6fcc3a949eb5f46075b0bbc91aa2642ce7319a3f0f829c34e9bf9c33d8fae2ce
|
||||
DIST chromium-clang-llvmorg-22-init-17020-gbd1bd178-2.tar.xz 57165612 BLAKE2B 7fdd52f8f72cf5fd5c32528bed47d0377d6d78ab14edd39f0301e93a73cff7b2dcbadeb1dacec32fff4c29439f0770f72a930b1461bc8713dadb6063d4bfa8ed SHA512 db7d58837a36b4b3b436de7c721cd71d8a51f476ed3dce37e18071fd925fb846ab1197ed75b88acff8b740ca0a1cbed4445f33d9bd5ce3e3e43b3c097f53e1df
|
||||
@@ -23,3 +23,4 @@ DIST chromium-rust-toolchain-15283f6fe9-1-llvmorg-22-init-8940-g4d4cb757.tar.xz
|
||||
DIST chromium-rust-toolchain-4a0969e06d-1-llvmorg-21-init-11777-gfd3fecfc.tar.xz 118529212 BLAKE2B 595fb0f3b1526f75c69b19936b93547168a7d4b53fe9afe34c0f3a08b58434dcfbd214c86963a0d54e726c475296d5b54a5a436d63f3f5ac84409fdf86a17cfc SHA512 837bde1b8a0750dca3b298d3a83e54a92574060e93af3d9fdc72ec5873b4e2e22abeb286dd81573eb787af2c0ccc7878eb2ba5e9fdfb8b0f22dd4b77fc1dcac1
|
||||
DIST chromium-rust-toolchain-a4cfac7093-2-llvmorg-22-init-17020-gbd1bd178.tar.xz 140484296 BLAKE2B 6b22b982b08b0728dda4bbbec2ad4f43977a792501a7ef0e5bba1c23996ec158ccaeabb3baced1d2335f3d7de0f5ca1f44dce40206ad57b63c9a17c675c35b86 SHA512 2d3fb70c9265e653bc952cae41ee81b3907e1c89d74e8c935c5d706a908424d32ebe6addde5230fd9ab366a53705fda9999ed511eee04de4ead14dced009d4de
|
||||
DIST chromium-testfonts-a28b222b79.tar.gz 33233004 BLAKE2B 2329d6a6069a19058c6fd58b61ae2d66cff3b4971984a5d2449be708ead2ef169bd4401ba3b5e9d3aedeeb910b6bb8e7c81b6e338808df327b3102420d6ab2d0 SHA512 ca4f98300f2037a40e02f6c2ffa04427fdf08cdce8de34cc944a5ccb69d4279090d2b8476d5e77bd610db6542696eb3ed4d135c3462fc0375cbf9277bf2fa670
|
||||
DIST rollup-wasm-node-4.57.1.tgz 792515 BLAKE2B 52fa9c4b65f3e20149c66fdd44b3c2a8b47e836d87de85535dbbf8b7243acef3d65c5be9f794eebb1533af2f16888a1cb42a75ed392ba65251cf60b73b41d559 SHA512 6f4adc247f329046a77e04de0ed94fb9b86984850ec74a1a01e93ede18b34da164a02d450524ec6341a2c700780f91d9e6bdc6b76c88f5cf0cd7739c5bf916e4
|
||||
|
||||
@@ -31,6 +31,8 @@ BUNDLED_CLANG_VER="llvmorg-22-init-17020-gbd1bd178-2"
|
||||
BUNDLED_RUST_VER="a4cfac7093a1c1c7fbdb6bc75d6b6dc4d385fc69-2"
|
||||
RUST_SHORT_HASH=${BUNDLED_RUST_VER:0:10}-${BUNDLED_RUST_VER##*-}
|
||||
NODE_VER="24.11.1"
|
||||
ESBUILD_VER="0.25.1" # currently manual
|
||||
ROLLUP_VER="4.57.1" # currently manual.
|
||||
VIRTUALX_REQUIRED="pgo"
|
||||
|
||||
CHROMIUM_LANGS="af am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu he
|
||||
@@ -53,6 +55,7 @@ PPC64_HASH="a85b64f07b489b8c6fdb13ecf79c16c56c560fc6"
|
||||
PATCH_V="${PV%%\.*}"
|
||||
COPIUM_COMMIT="fe1caafa06f27542c18a881348f78e984e2d9fe2"
|
||||
SRC_URI="https://github.com/chromium-linux-tarballs/chromium-tarballs/releases/download/${PV}/chromium-${PV}-linux.tar.xz
|
||||
https://deps.gentoo.zip/www-client/chromium/rollup-wasm-node-${ROLLUP_VER}.tgz
|
||||
!bundled-toolchain? (
|
||||
https://gitlab.com/Matt.Jolly/chromium-patches/-/archive/${PATCH_V}/chromium-patches-${PATCH_V}.tar.bz2
|
||||
https://codeberg.org/selfisekai/copium/archive/${COPIUM_COMMIT}.tar.gz
|
||||
@@ -64,9 +67,6 @@ SRC_URI="https://github.com/chromium-linux-tarballs/chromium-tarballs/releases/d
|
||||
https://commondatastorage.googleapis.com/chromium-browser-clang/Linux_x64/rust-toolchain-${BUNDLED_RUST_VER}-${BUNDLED_CLANG_VER%-*}.tar.xz
|
||||
-> chromium-rust-toolchain-${RUST_SHORT_HASH}-${BUNDLED_CLANG_VER%-*}.tar.xz
|
||||
)
|
||||
ppc64? (
|
||||
https://gitlab.raptorengineering.com/raptor-engineering-public/chromium/openpower-patches/-/archive/${PPC64_HASH}/openpower-patches-${PPC64_HASH}.tar.bz2 -> chromium-openpower-${PPC64_HASH:0:10}.tar.bz2
|
||||
)
|
||||
pgo? ( https://github.com/elkablo/chromium-profiler/releases/download/v0.2/chromium-profiler-0.2.tar )"
|
||||
|
||||
# https://gitweb.gentoo.org/proj/chromium-tools.git/tree/get-chromium-licences.py
|
||||
@@ -121,7 +121,7 @@ COMMON_SNAPSHOT_DEPEND="
|
||||
system-zstd? ( >=app-arch/zstd-1.5.5:= )
|
||||
>=media-libs/libwebp-0.4.0:=
|
||||
media-libs/mesa:=[gbm(+)]
|
||||
>=media-libs/openh264-1.6.0:=
|
||||
>=media-libs/openh264-2.6.0:=
|
||||
sys-libs/zlib:=
|
||||
!headless? (
|
||||
dev-libs/glib:2
|
||||
@@ -210,11 +210,12 @@ BDEPEND="
|
||||
>=dev-python/selenium-3.141.0
|
||||
>=dev-util/web_page_replay_go-20220314
|
||||
)
|
||||
>=dev-util/bindgen-0.68.0
|
||||
>=dev-util/bindgen-0.72.1
|
||||
>=dev-build/gn-${GN_MIN_VER}
|
||||
app-alternatives/ninja
|
||||
dev-lang/perl
|
||||
>=dev-util/gperf-3.2
|
||||
dev-util/esbuild:${ESBUILD_VER}
|
||||
dev-vcs/git
|
||||
>=net-libs/nodejs-${NODE_VER}[inspector]
|
||||
sys-apps/hwdata
|
||||
@@ -408,6 +409,10 @@ src_unpack() {
|
||||
if use ppc64; then
|
||||
unpack chromium-openpower-${PPC64_HASH:0:10}.tar.bz2
|
||||
fi
|
||||
|
||||
# This is a dirty hack, but we need rollup to build successfully and it's proving to be challenging
|
||||
# to build locally due to deps
|
||||
unpack rollup-wasm-node-${ROLLUP_VER}.tgz
|
||||
}
|
||||
|
||||
remove_compiler_builtins() {
|
||||
@@ -467,6 +472,38 @@ src_prepare() {
|
||||
# Calling this here supports resumption via FEATURES=keepwork
|
||||
python_setup
|
||||
|
||||
elog "Removing bundled binaries from source tree ..."
|
||||
# Purge bundled ELF files: These are non-portable and will cause issues if used instead of system versions.
|
||||
# Use `--wasm` to also remove WebAssembly binaries, if desired - they're portable so shouldn't break builds.
|
||||
python3 "${FILESDIR}/bin-finder.py" --elf "${S}" | awk '{print $1}' | xargs rm -f ||
|
||||
die "Failed to remove bundled binaries"
|
||||
|
||||
# And now we restore any that we actually need, from the host system
|
||||
local esbuild_path="${S}/third_party/devtools-frontend/src/third_party/esbuild"
|
||||
local -A restore_list=(
|
||||
["/usr/bin/esbuild-${ESBUILD_VER}"]="${esbuild_path}/esbuild"
|
||||
["/usr/bin/node"]="${S}/third_party/node/linux/node-linux-x64/bin/node"
|
||||
)
|
||||
|
||||
for src in "${!restore_list[@]}"; do
|
||||
dst="${restore_list[${src}]}"
|
||||
if [[ -f "${src}" ]]; then
|
||||
einfo "Symlinking ${src} ..."
|
||||
# Make sure the parent dir exists; some tarballs don't include (e.g.) node's bindir
|
||||
mkdir -p "$(dirname "${dst}")" || die "Failed to create directory for ${dst}"
|
||||
ln -s "${src}" "${dst}" || die "Failed to symlink ${dst} from ${src}"
|
||||
else
|
||||
die "Expected to find ${src} to restore ${dst}, but it does not exist."
|
||||
fi
|
||||
done
|
||||
|
||||
# Until we can just symlink in a system rollup, we'll `mv` the wasm version and modify some files.
|
||||
einfo "Moving rollup wasm-node package into place ..."
|
||||
mkdir -p third_party/devtools-frontend/src/node_modules/@rollup/wasm-node ||
|
||||
die "Failed to create node_modules/@rollup/wasm-node"
|
||||
mv "${WORKDIR}"/package/* third_party/devtools-frontend/src/node_modules/@rollup/wasm-node ||
|
||||
die "Failed to move rollup package"
|
||||
|
||||
# To know which patches are safe to drop from files/ after tidying up old ebuilds:
|
||||
# comm -13 \
|
||||
# <(grep 'FILESDIR' *.ebuild | grep patch | grep -o '\${FILESDIR}/[^") ]*' \
|
||||
@@ -480,11 +517,10 @@ src_prepare() {
|
||||
"${FILESDIR}/${PN}-138-nodejs-version-check.patch"
|
||||
"${FILESDIR}/cr144-glibc-2.43.patch"
|
||||
"${FILESDIR}/cr145-oauth2-client-switches.patch"
|
||||
"${FILESDIR}/cr145-revert-to-rollup-wasm.patch"
|
||||
)
|
||||
|
||||
PATCHES+=(
|
||||
"${WORKDIR}/copium/cr143-libsync-__BEGIN_DECLS.patch"
|
||||
)
|
||||
# No copium patches here: they should only need to apply to unbundled toolchain builds
|
||||
# and don't get fetched or unpacked.
|
||||
|
||||
# https://issues.chromium.org/issues/442698344
|
||||
# Unreleased fontconfig changed magic numbers and google have rolled to this version
|
||||
@@ -513,6 +549,12 @@ src_prepare() {
|
||||
"${WORKDIR}"/rust-toolchain/INSTALLED_VERSION || die "Failed to set rust version"
|
||||
else
|
||||
# We don't need our toolchain patches if we're using the official toolchain
|
||||
|
||||
# Copium patches go here.
|
||||
PATCHES+=(
|
||||
"${WORKDIR}/copium/cr143-libsync-__BEGIN_DECLS.patch"
|
||||
)
|
||||
|
||||
shopt -s globstar nullglob
|
||||
# 130: moved the PPC64 patches into the chromium-patches repo
|
||||
local patch
|
||||
@@ -556,14 +598,6 @@ src_prepare() {
|
||||
|
||||
default
|
||||
|
||||
# Not included in -lite tarballs, but we should check for it anyway.
|
||||
if [[ -f third_party/node/linux/node-linux-x64/bin/node ]]; then
|
||||
rm third_party/node/linux/node-linux-x64/bin/node || die
|
||||
else
|
||||
mkdir -p third_party/node/linux/node-linux-x64/bin || die
|
||||
fi
|
||||
ln -s "${EPREFIX}"/usr/bin/node third_party/node/linux/node-linux-x64/bin/node || die
|
||||
|
||||
# adjust python interpreter version
|
||||
sed -i -e "s|\(^script_executable = \).*|\1\"${EPYTHON}\"|g" .gn || die
|
||||
|
||||
@@ -1384,24 +1418,9 @@ src_compile() {
|
||||
|
||||
rm -f out/Release/locales/*.pak.info || die
|
||||
|
||||
# Build manpage; bug #684550
|
||||
sed -e 's|@@PACKAGE@@|chromium-browser|g;
|
||||
s|@@MENUNAME@@|Chromium|g;' \
|
||||
chrome/app/resources/manpage.1.in > \
|
||||
out/Release/chromium-browser.1 || die
|
||||
|
||||
# Build desktop file; bug #706786
|
||||
sed -e 's|@@MENUNAME@@|Chromium|g;
|
||||
s|@@USR_BIN_SYMLINK_NAME@@|chromium-browser|g;
|
||||
s|@@PACKAGE@@|chromium-browser|g;
|
||||
s|\(^Exec=\)/usr/bin/|\1|g;' \
|
||||
chrome/installer/linux/common/desktop.template > \
|
||||
out/Release/chromium-browser-chromium.desktop || die
|
||||
|
||||
# Build vk_swiftshader_icd.json; bug #827861
|
||||
sed -e 's|${ICD_LIBRARY_PATH}|./libvk_swiftshader.so|g' \
|
||||
third_party/swiftshader/src/Vulkan/vk_swiftshader_icd.json.tmpl > \
|
||||
out/Release/vk_swiftshader_icd.json || die
|
||||
# Generate support files (desktop file, manpage, etc.) See: #684550 #706786 #968958
|
||||
python3 "${FILESDIR}/generate-support-files.py" --installdir "/usr/$(get_libdir)/chromium-browser" ||
|
||||
die "Failed to generate support files"
|
||||
}
|
||||
|
||||
src_test() {
|
||||
@@ -1510,7 +1529,7 @@ src_install() {
|
||||
|
||||
pushd out/Release/locales > /dev/null || die
|
||||
chromium_remove_language_paks
|
||||
popd
|
||||
popd > /dev/null || die
|
||||
|
||||
insinto "${CHROMIUM_HOME}"
|
||||
doins out/Release/*.bin
|
||||
@@ -1568,7 +1587,11 @@ src_install() {
|
||||
|
||||
# Install GNOME default application entry (bug #303100).
|
||||
insinto /usr/share/gnome-control-center/default-apps
|
||||
newins "${FILESDIR}"/chromium-browser.xml chromium-browser.xml
|
||||
doins out/Release/chromium-browser.xml
|
||||
|
||||
# Install AppStream metadata
|
||||
insinto /usr/share/appdata
|
||||
doins out/Release/chromium-browser.appdata.xml
|
||||
|
||||
# Install manpage; bug #684550
|
||||
doman out/Release/chromium-browser.1
|
||||
104
www-client/chromium/files/bin-finder.py
Normal file
104
www-client/chromium/files/bin-finder.py
Normal file
@@ -0,0 +1,104 @@
|
||||
#!/usr/bin/env python3
|
||||
# A simple script to find ELF and WebAssembly executables in a directory tree.
|
||||
# Spdx-License-Identifier: GPL-2.0-or-later
|
||||
import os
|
||||
import struct
|
||||
import argparse
|
||||
|
||||
# Magic numbers
|
||||
ELF_MAGIC = b"\x7fELF"
|
||||
WASM_MAGIC = b"\x00asm"
|
||||
|
||||
# Machine ID Mapping for things in Chromium
|
||||
ELF_MACHINE_MAP = {
|
||||
0x02: "SPARC",
|
||||
0x03: "x86",
|
||||
0x08: "MIPS",
|
||||
0x12: "SPARC",
|
||||
0x14: "PowerPC",
|
||||
0x15: "PowerPC64",
|
||||
0x28: "ARM",
|
||||
0x2B: "SPARC V9",
|
||||
0x34: "SuperH",
|
||||
0x3E: "x86_64",
|
||||
0xB7: "AArch64",
|
||||
0xA4: "Hexagon",
|
||||
0xF3: "RISC-V",
|
||||
}
|
||||
|
||||
|
||||
def get_elf_info(fd):
|
||||
"""Parses ELF header using the file's own endianness."""
|
||||
os.lseek(fd, 0, os.SEEK_SET)
|
||||
header = os.read(fd, 20)
|
||||
|
||||
if len(header) < 20:
|
||||
return None
|
||||
|
||||
# Offset 4: 1=32-bit, 2=64-bit
|
||||
bit_mode = "32-bit" if header[4] == 1 else "64-bit"
|
||||
|
||||
# Offset 5: 1=LSB (Little Endian), 2=MSB (Big Endian)
|
||||
endian_byte = header[5]
|
||||
endian = "<" if endian_byte == 1 else ">"
|
||||
endian_name = "LSB" if endian_byte == 1 else "MSB"
|
||||
|
||||
# Machine ID is 2 bytes at offset 18
|
||||
machine_id = struct.unpack(f"{endian}H", header[18:20])[0]
|
||||
|
||||
# Object Type is 2 bytes at offset 16
|
||||
obj_type_id = struct.unpack(f"{endian}H", header[16:18])[0]
|
||||
obj_types = {1: "relocatable", 2: "executable", 3: "shared object", 4: "core"}
|
||||
obj_type = obj_types.get(obj_type_id, "unknown type")
|
||||
|
||||
arch = ELF_MACHINE_MAP.get(machine_id, f"Unknown (0x{machine_id:x})")
|
||||
return f"ELF {bit_mode} {endian_name} {arch} ({obj_type})"
|
||||
|
||||
|
||||
def scan_path(root_path, show_elf, show_wasm):
|
||||
try:
|
||||
with os.scandir(root_path) as it:
|
||||
for entry in it:
|
||||
if entry.is_dir(follow_symlinks=False):
|
||||
scan_path(entry.path, show_elf, show_wasm)
|
||||
elif entry.is_file(follow_symlinks=False):
|
||||
fd = None
|
||||
try:
|
||||
fd = os.open(entry.path, os.O_RDONLY | os.O_NOFOLLOW)
|
||||
# Hit the header (64 bytes covers most ELF header variants)
|
||||
os.posix_fadvise(fd, 0, 64, os.POSIX_FADV_WILLNEED)
|
||||
|
||||
magic = os.read(fd, 4)
|
||||
|
||||
if magic == ELF_MAGIC and show_elf:
|
||||
info = get_elf_info(fd)
|
||||
if info:
|
||||
print(f"{entry.path} -> {info}")
|
||||
|
||||
elif magic == WASM_MAGIC and show_wasm:
|
||||
print(f"{entry.path} -> WebAssembly binary")
|
||||
|
||||
# Performance: Drop from page cache
|
||||
os.posix_fadvise(fd, 0, 0, os.POSIX_FADV_DONTNEED)
|
||||
except (PermissionError, OSError):
|
||||
continue
|
||||
finally:
|
||||
if fd is not None:
|
||||
os.close(fd)
|
||||
except (PermissionError, OSError):
|
||||
pass
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
parser = argparse.ArgumentParser(description="Fast Linux binary sniffer")
|
||||
parser.add_argument("directory", help="Directory to scan")
|
||||
parser.add_argument("--elf", action="store_true", help="Only show ELF files")
|
||||
parser.add_argument("--wasm", action="store_true", help="Only show WASM files")
|
||||
|
||||
args = parser.parse_args()
|
||||
|
||||
# If neither is specified, default to showing both
|
||||
show_elf = args.elf or (not args.elf and not args.wasm)
|
||||
show_wasm = args.wasm or (not args.elf and not args.wasm)
|
||||
|
||||
scan_path(args.directory, show_elf, show_wasm)
|
||||
90
www-client/chromium/files/cr145-revert-to-rollup-wasm.patch
Normal file
90
www-client/chromium/files/cr145-revert-to-rollup-wasm.patch
Normal file
@@ -0,0 +1,90 @@
|
||||
From dc66bab2e7a13ebfc18b83b70e77a5165ad36521 Mon Sep 17 00:00:00 2001
|
||||
From: Matt Jolly <kangie@gentoo.org>
|
||||
Date: Fri, 13 Feb 2026 19:25:21 +1000
|
||||
Subject: [PATCH] cr145: revert to rollup wasm
|
||||
|
||||
This commit reverts most of 0cea597366df8740da5cc046cde6de2468ba1e56,
|
||||
where the wasm version of rollup was replaced by a native node module
|
||||
which is a _collossal pain_ for those of us that can't just download
|
||||
random binaries from the internet.
|
||||
|
||||
Signed-off-by: Matt Jolly <kangie@gentoo.org>
|
||||
--- a/third_party/devtools-frontend/src/front_end/Images/BUILD.gn
|
||||
+++ b/third_party/devtools-frontend/src/front_end/Images/BUILD.gn
|
||||
@@ -28,7 +28,7 @@ node_action("generate_css_vars") {
|
||||
}
|
||||
|
||||
node_action("optimize_images") {
|
||||
- script = "node_modules/rollup/dist/bin/rollup"
|
||||
+ script = "node_modules/@rollup/wasm-node/dist/bin/rollup"
|
||||
|
||||
_bundled_entrypoint = target_gen_dir + "/Images.prebundle.js"
|
||||
_output_file_location = target_gen_dir + "/Images.js"
|
||||
--- a/third_party/devtools-frontend/src/front_end/models/live-metrics/web-vitals-injected/BUILD.gn
|
||||
+++ b/third_party/devtools-frontend/src/front_end/models/live-metrics/web-vitals-injected/BUILD.gn
|
||||
@@ -26,7 +26,7 @@ devtools_module("web-vitals-injected") {
|
||||
}
|
||||
|
||||
node_action("bundled_library") {
|
||||
- script = "node_modules/rollup/dist/bin/rollup"
|
||||
+ script = "node_modules/@rollup/wasm-node/dist/bin/rollup"
|
||||
|
||||
_bundled_entrypoint = target_gen_dir + "/web-vitals-injected.js"
|
||||
_output_file_location = target_gen_dir + "/web-vitals-injected.generated.js"
|
||||
--- a/third_party/devtools-frontend/src/front_end/panels/recorder/injected/BUILD.gn
|
||||
+++ b/third_party/devtools-frontend/src/front_end/panels/recorder/injected/BUILD.gn
|
||||
@@ -55,7 +55,7 @@ devtools_entrypoint("bundle") {
|
||||
}
|
||||
|
||||
node_action("bundled_library") {
|
||||
- script = "node_modules/rollup/dist/bin/rollup"
|
||||
+ script = "node_modules/@rollup/wasm-node/dist/bin/rollup"
|
||||
|
||||
_bundled_entrypoint = target_gen_dir + "/injected.js"
|
||||
_output_file_location = target_gen_dir + "/injected.generated.js"
|
||||
--- a/third_party/devtools-frontend/src/front_end/third_party/codemirror.next/rebuild.sh
|
||||
+++ b/third_party/devtools-frontend/src/front_end/third_party/codemirror.next/rebuild.sh
|
||||
@@ -1,6 +1,6 @@
|
||||
npm install
|
||||
../../../node_modules/.bin/tsc -d -t esnext -m esnext --moduleResolution node bundle.ts
|
||||
-../../../node_modules/rollup/dist/bin/rollup -c
|
||||
+../../../node_modules/@rollup/wasm-node/dist/bin/rollup -c
|
||||
rm -rf node_modules bundle.js bundle.d.ts
|
||||
# Because there's a bug in clang causing it to reformat import lists even where formatting is disabled, run it right away
|
||||
git cl format --js
|
||||
--- a/third_party/devtools-frontend/src/front_end/third_party/lit/rebuild.sh
|
||||
+++ b/third_party/devtools-frontend/src/front_end/third_party/lit/rebuild.sh
|
||||
@@ -1,6 +1,6 @@
|
||||
npm install
|
||||
../../../node_modules/.bin/tsc -d -t esnext -m esnext --moduleResolution node src/*
|
||||
-../../../node_modules/rollup/dist/bin/rollup -c
|
||||
+../../../node_modules/@rollup/wasm-node/dist/bin/rollup -c
|
||||
rm -rf node_modules src/*.js src/*.d.ts
|
||||
# Because there's a bug in clang causing it to reformat import lists even where formatting is disabled, run it right away
|
||||
git cl format --js
|
||||
--- a/third_party/devtools-frontend/src/inspector_overlay/BUILD.gn
|
||||
+++ b/third_party/devtools-frontend/src/inspector_overlay/BUILD.gn
|
||||
@@ -36,7 +36,7 @@ action("build_inspector_overlay") {
|
||||
"$target_gen_dir/tool_window_controls.css",
|
||||
"$target_gen_dir/main.js",
|
||||
devtools_location_prepend + "inspector_overlay/loadCSS.rollup.js",
|
||||
- devtools_location_prepend + "node_modules/rollup/dist/bin/rollup",
|
||||
+ devtools_location_prepend + "node_modules/@rollup/wasm-node/dist/bin/rollup",
|
||||
]
|
||||
|
||||
outputs = [ "$resources_out_dir/main.js" ]
|
||||
--- a/third_party/devtools-frontend/src/scripts/devtools_paths.py
|
||||
+++ b/third_party/devtools-frontend/src/scripts/devtools_paths.py
|
||||
@@ -65,7 +65,8 @@ def license_checker_path():
|
||||
def rollup_path():
|
||||
return path.join(
|
||||
node_modules_path(),
|
||||
- 'rollup',
|
||||
+ '@rollup',
|
||||
+ 'wasm-node',
|
||||
'dist',
|
||||
'bin',
|
||||
'rollup',
|
||||
--
|
||||
2.52.0
|
||||
|
||||
82
www-client/chromium/files/generate-support-files.py
Normal file
82
www-client/chromium/files/generate-support-files.py
Normal file
@@ -0,0 +1,82 @@
|
||||
#!/usr/bin/env python3
|
||||
# Spdx-License-Identifier: GPL-2.0-or-later
|
||||
# A wrapper script to generate support files, see #684550 #706786 #968958
|
||||
# Use upstream's python installer script to generate support files
|
||||
# This replaces fragile sed commands and handles @@include@@ directives.
|
||||
# It'll also verify that all substitution markers have been resolved, meaning that
|
||||
# future changes to templates that add new variables will be caught during the build.
|
||||
import sys
|
||||
import argparse
|
||||
from pathlib import Path
|
||||
|
||||
# Add upstream installer script to search path
|
||||
sys.path.insert(0, str(Path.cwd() / "chrome/installer/linux/common"))
|
||||
import installer
|
||||
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser()
|
||||
parser.add_argument(
|
||||
"-i",
|
||||
"--installdir",
|
||||
required=True,
|
||||
help="Installation directory (e.g. /usr/lib/chromium-browser)",
|
||||
)
|
||||
args = parser.parse_args()
|
||||
|
||||
# Configure contexts strictly for file generation
|
||||
# Common variables used across templates
|
||||
context = {
|
||||
"BUGTRACKERURL": "https://bugs.gentoo.org/enter_bug.cgi?product=Gentoo Linux&component=Current packages",
|
||||
"DEVELOPER_NAME": "The Chromium Authors",
|
||||
"EXTRA_DESKTOP_ENTRIES": "",
|
||||
"FULLDESC": "An open-source browser project that aims to build a safer, faster, and more stable way to experience the web.",
|
||||
"HELPURL": "https://wiki.gentoo.org/wiki/Chromium",
|
||||
"INSTALLDIR": args.installdir,
|
||||
"MAINTMAIL": "Gentoo Chromium Project <chromium@gentoo.org>",
|
||||
"MENUNAME": "Chromium",
|
||||
"PACKAGE": "chromium-browser",
|
||||
"PRODUCTURL": "https://www.chromium.org/",
|
||||
"PROGNAME": "chrome",
|
||||
"PROJECT_LICENSE": "BSD, LGPL-2, LGPL-2.1, MPL-1.1, MPL-2.0, Apache-2.0, and others",
|
||||
"SHORTDESC": "Open-source foundation of many web browsers including Google Chrome",
|
||||
"URI_SCHEME": "x-scheme-handler/chromium",
|
||||
"USR_BIN_SYMLINK_NAME": "chromium-browser",
|
||||
}
|
||||
|
||||
# upstream is currently (M145) converting from upper to lower case
|
||||
# we need to support both until we drop old versions _and_ the conversion is complete.
|
||||
for key in list(context):
|
||||
context[key.lower()] = context[key]
|
||||
|
||||
# Generate Desktop file
|
||||
installer.process_template(
|
||||
Path("chrome/installer/linux/common/desktop.template"),
|
||||
Path("out/Release/chromium-browser-chromium.desktop"),
|
||||
context,
|
||||
)
|
||||
|
||||
# Generate Manpage
|
||||
installer.process_template(
|
||||
Path("chrome/app/resources/manpage.1.in"),
|
||||
Path("out/Release/chromium-browser.1"),
|
||||
context,
|
||||
)
|
||||
|
||||
# Generate AppData (AppStream)
|
||||
installer.process_template(
|
||||
Path("chrome/installer/linux/common/appdata.xml.template"),
|
||||
Path("out/Release/chromium-browser.appdata.xml"),
|
||||
context,
|
||||
)
|
||||
|
||||
# Generate GNOME Default Apps entry
|
||||
installer.process_template(
|
||||
Path("chrome/installer/linux/common/default-app.template"),
|
||||
Path("out/Release/chromium-browser.xml"),
|
||||
context,
|
||||
)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
@@ -2,3 +2,4 @@ DIST google-chrome-beta_142.0.7444.34-1_amd64.deb 117502860 BLAKE2B 129f909409cf
|
||||
DIST google-chrome-beta_143.0.7499.40-1_amd64.deb 117949484 BLAKE2B 9d61a2a0fea90cc3d1e5e233d3b179c5b6b410b6a06df418bea3a5b64b56dd187c09c707856254021eb32c9209da72998c7d3dac73ec3954a00700f63a172904 SHA512 0745c8f78cd5e694ab201ab154dad4dbe958580ba6cb6519c1f545b6ddd705c8baf60d4fc202ccaf234ad41feecff6897531b5913a81483a9e9de04d58bca478
|
||||
DIST google-chrome-beta_144.0.7559.31-1_amd64.deb 118815912 BLAKE2B 92f6dff1da3e18e097b60ed2826f903abb0901a2f6ea37b3859ab9eb1a3b66f35d8eeea77f63a48c05535fde493815cefd5b695e72b42b31fcd6f18c5a0382ee SHA512 0ef8115594bc850111a876ca4f85a995b23b75fd581c26efe8ac807ee9f3bc77e15f3c24fc6423565fd8326c139e3065d1080d247304b99848e3a4f0d8087c3e
|
||||
DIST google-chrome-beta_145.0.7632.45-1_amd64.deb 121087192 BLAKE2B 3b5f44ac08414f9aa4194a628c722c7cd0035b76c448beb511389136e4574961696e1c094b6e576557f576b4bb1e004394220bf8d2cbf55d3402cd3c6ecd8835 SHA512 38bff481636fa32c9e6fe20826cbcc71b6445d7afb18770c977e20569aac427398ceb1f919e77e6e6371c42a02cd21adf39e4ae9f097ac2fa3fdcb9a503bd716
|
||||
DIST google-chrome-beta_146.0.7680.0-1_amd64.deb 127612020 BLAKE2B 1a5ab43ae07295f9a4efee498c0dc34fa90623c78baa182bdb2e335843ab1a1c00bba93e91317640a772d788293996ba374602defff3fd0d677021d6656e4006 SHA512 421b9e193aa5ae51d87ea64e93dd9eebdc58e050c6fff3bf05e7189ec840f12e74d1abd726f66accbc8d8ee246b5ed0152c3bf0a0d26337fc20e07a3546c01ea
|
||||
|
||||
@@ -0,0 +1,129 @@
|
||||
# Copyright 2011-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
CHROMIUM_LANGS="af am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu he
|
||||
hi hr hu id it ja kn ko lt lv ml mr ms nb nl pl pt-BR pt-PT ro ru sk sl sr
|
||||
sv sw ta te th tr uk ur vi zh-CN zh-TW"
|
||||
|
||||
inherit chromium-2 desktop pax-utils unpacker xdg
|
||||
|
||||
DESCRIPTION="The web browser from Google"
|
||||
HOMEPAGE="https://www.google.com/chrome/"
|
||||
|
||||
if [[ ${PN} == google-chrome ]]; then
|
||||
MY_PN=${PN}-stable
|
||||
else
|
||||
MY_PN=${PN}
|
||||
fi
|
||||
|
||||
MY_P="${MY_PN}_${PV}-1"
|
||||
SRC_URI="https://dl.google.com/linux/chrome/deb/pool/main/g/${MY_PN}/${MY_P}_amd64.deb"
|
||||
S=${WORKDIR}
|
||||
|
||||
LICENSE="google-chrome"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64"
|
||||
|
||||
IUSE="qt6 selinux"
|
||||
|
||||
RESTRICT="bindist mirror strip"
|
||||
|
||||
RDEPEND="
|
||||
>=app-accessibility/at-spi2-core-2.46.0:2
|
||||
app-misc/ca-certificates
|
||||
dev-libs/expat
|
||||
dev-libs/glib:2
|
||||
dev-libs/nspr
|
||||
>=dev-libs/nss-3.26
|
||||
media-fonts/liberation-fonts
|
||||
media-libs/alsa-lib
|
||||
media-libs/mesa[gbm(+)]
|
||||
net-misc/curl
|
||||
net-print/cups
|
||||
sys-apps/dbus
|
||||
sys-libs/glibc
|
||||
sys-libs/libcap
|
||||
x11-libs/cairo
|
||||
x11-libs/gdk-pixbuf:2
|
||||
|| (
|
||||
x11-libs/gtk+:3[X]
|
||||
gui-libs/gtk:4[X]
|
||||
)
|
||||
x11-libs/libdrm
|
||||
>=x11-libs/libX11-1.5.0
|
||||
x11-libs/libXcomposite
|
||||
x11-libs/libXdamage
|
||||
x11-libs/libXext
|
||||
x11-libs/libXfixes
|
||||
x11-libs/libXrandr
|
||||
x11-libs/libxcb
|
||||
x11-libs/libxkbcommon
|
||||
x11-libs/libxshmfence
|
||||
x11-libs/pango
|
||||
x11-misc/xdg-utils
|
||||
qt6? ( dev-qt/qtbase:6[gui,widgets] )
|
||||
selinux? ( sec-policy/selinux-chromium )
|
||||
"
|
||||
|
||||
QA_PREBUILT="*"
|
||||
QA_DESKTOP_FILE="usr/share/applications/google-chrome.*\\.desktop"
|
||||
CHROME_HOME="opt/google/chrome${PN#google-chrome}"
|
||||
|
||||
pkg_nofetch() {
|
||||
eerror "Please wait 24 hours and sync your tree before reporting a bug for google-chrome fetch failures."
|
||||
}
|
||||
|
||||
pkg_pretend() {
|
||||
# Protect against people using autounmask overzealously
|
||||
use amd64 || die "google-chrome only works on amd64"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
chromium_suid_sandbox_check_kernel_config
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
:
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dodir /
|
||||
cd "${ED}" || die
|
||||
unpacker
|
||||
|
||||
mv usr/share/doc/${MY_PN} usr/share/doc/${PF} || die
|
||||
|
||||
# Since M141 Google Chrome comes with its own bundled cron
|
||||
# scripts which invoke `apt` directly. Useless on Gentoo!
|
||||
rm -r etc/cron.daily || die "Failed to remove cron scripts"
|
||||
rm -r "${CHROME_HOME}"/cron || die "Failed to remove cron scripts"
|
||||
|
||||
gzip -d usr/share/doc/${PF}/changelog.gz || die
|
||||
gzip -d usr/share/man/man1/${MY_PN}.1.gz || die
|
||||
if [[ -L usr/share/man/man1/google-chrome.1.gz ]]; then
|
||||
rm usr/share/man/man1/google-chrome.1.gz || die
|
||||
dosym ${MY_PN}.1 usr/share/man/man1/google-chrome.1
|
||||
fi
|
||||
|
||||
pushd "${CHROME_HOME}/locales" > /dev/null || die
|
||||
chromium_remove_language_paks
|
||||
popd > /dev/null || die
|
||||
|
||||
rm "${CHROME_HOME}/libqt5_shim.so" || die
|
||||
if ! use qt6; then
|
||||
rm "${CHROME_HOME}/libqt6_shim.so" || die
|
||||
fi
|
||||
|
||||
local suffix=
|
||||
[[ ${PN} == google-chrome-beta ]] && suffix=_beta
|
||||
[[ ${PN} == google-chrome-unstable ]] && suffix=_dev
|
||||
|
||||
local size
|
||||
for size in 16 24 32 48 64 128 256 ; do
|
||||
newicon -s ${size} "${CHROME_HOME}/product_logo_${size}${suffix}.png" ${PN}.png
|
||||
done
|
||||
|
||||
pax-mark m "${CHROME_HOME}/chrome"
|
||||
}
|
||||
@@ -2,3 +2,4 @@ DIST google-chrome-stable_141.0.7390.107-1_amd64.deb 120556940 BLAKE2B 30075afc3
|
||||
DIST google-chrome-stable_142.0.7444.175-1_amd64.deb 117885136 BLAKE2B 35a125f731147ba38759e83f820425568f1c029730f484633317269228be1f8e26ebae28f13e61cc37e26b5af19443e749d79e6cffa135f0e45812ca1c0628fd SHA512 d046e1e59787330e8e13360cecd827dc9e2dd55712ca3b39306e860b2e5ff85c6d25135f120ba2fe6985e929add560e19971036bacb6b4b5dad5ba14adb36ce7
|
||||
DIST google-chrome-stable_143.0.7499.169-1_amd64.deb 117840328 BLAKE2B ba4cffacff5c002cd8dba3fa8c8e105ebfdcf04884186de0a60cfaa6861662a615c9dd9738cd312ce48ddaee1f62bca2137ee7c872da3aa82ef7a4c44d65b800 SHA512 0c3f3cb76be5c2ffb72f97937b0f7a4079cf04088a00e7debe1bed3325d5e6e6d7a6d60b2fb9a34d389ace8340781aad4221c94c7bae7520eecff25532918254
|
||||
DIST google-chrome-stable_144.0.7559.132-1_amd64.deb 118945608 BLAKE2B 768718c87f7d1bdc3567ab830d312787da9c97fc7985f49ed17aa6d7b1fdf1edf3103b598ed8cf31dbaac0109bb1faf4a93e2b60d9c1bb478916d43b8745973d SHA512 5e0b5b9e16471fc1da53e971f485d70c3ddec8a1d6ec0b0438adfb07eaa0771589c3702c4aeb3cde3b07f886dfc255223affe19a3820b722dc51a24216434205
|
||||
DIST google-chrome-stable_145.0.7632.67-1_amd64.deb 121060256 BLAKE2B 751a1f408476a6780e0f6b56fceb532055e51d1fab446c074745bfbdbaf216e9009f771111ca369544808bbb5744658b4af89c55aac77c490dd48a9bf14dd473 SHA512 2f78e5ee53f28732d3c862a16bb73f6938f7c817e64ea2ed519cf7b5a428e5b1f4c525abd01a08d202e0b449b84e96e74ba6dc6d05ffa362e06e6de6677aca3e
|
||||
|
||||
129
www-client/google-chrome/google-chrome-145.0.7632.67.ebuild
Normal file
129
www-client/google-chrome/google-chrome-145.0.7632.67.ebuild
Normal file
@@ -0,0 +1,129 @@
|
||||
# Copyright 2011-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
CHROMIUM_LANGS="af am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu he
|
||||
hi hr hu id it ja kn ko lt lv ml mr ms nb nl pl pt-BR pt-PT ro ru sk sl sr
|
||||
sv sw ta te th tr uk ur vi zh-CN zh-TW"
|
||||
|
||||
inherit chromium-2 desktop pax-utils unpacker xdg
|
||||
|
||||
DESCRIPTION="The web browser from Google"
|
||||
HOMEPAGE="https://www.google.com/chrome/"
|
||||
|
||||
if [[ ${PN} == google-chrome ]]; then
|
||||
MY_PN=${PN}-stable
|
||||
else
|
||||
MY_PN=${PN}
|
||||
fi
|
||||
|
||||
MY_P="${MY_PN}_${PV}-1"
|
||||
SRC_URI="https://dl.google.com/linux/chrome/deb/pool/main/g/${MY_PN}/${MY_P}_amd64.deb"
|
||||
S=${WORKDIR}
|
||||
|
||||
LICENSE="google-chrome"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64"
|
||||
|
||||
IUSE="qt6 selinux"
|
||||
|
||||
RESTRICT="bindist mirror strip"
|
||||
|
||||
RDEPEND="
|
||||
>=app-accessibility/at-spi2-core-2.46.0:2
|
||||
app-misc/ca-certificates
|
||||
dev-libs/expat
|
||||
dev-libs/glib:2
|
||||
dev-libs/nspr
|
||||
>=dev-libs/nss-3.26
|
||||
media-fonts/liberation-fonts
|
||||
media-libs/alsa-lib
|
||||
media-libs/mesa[gbm(+)]
|
||||
net-misc/curl
|
||||
net-print/cups
|
||||
sys-apps/dbus
|
||||
sys-libs/glibc
|
||||
sys-libs/libcap
|
||||
x11-libs/cairo
|
||||
x11-libs/gdk-pixbuf:2
|
||||
|| (
|
||||
x11-libs/gtk+:3[X]
|
||||
gui-libs/gtk:4[X]
|
||||
)
|
||||
x11-libs/libdrm
|
||||
>=x11-libs/libX11-1.5.0
|
||||
x11-libs/libXcomposite
|
||||
x11-libs/libXdamage
|
||||
x11-libs/libXext
|
||||
x11-libs/libXfixes
|
||||
x11-libs/libXrandr
|
||||
x11-libs/libxcb
|
||||
x11-libs/libxkbcommon
|
||||
x11-libs/libxshmfence
|
||||
x11-libs/pango
|
||||
x11-misc/xdg-utils
|
||||
qt6? ( dev-qt/qtbase:6[gui,widgets] )
|
||||
selinux? ( sec-policy/selinux-chromium )
|
||||
"
|
||||
|
||||
QA_PREBUILT="*"
|
||||
QA_DESKTOP_FILE="usr/share/applications/google-chrome.*\\.desktop"
|
||||
CHROME_HOME="opt/google/chrome${PN#google-chrome}"
|
||||
|
||||
pkg_nofetch() {
|
||||
eerror "Please wait 24 hours and sync your tree before reporting a bug for google-chrome fetch failures."
|
||||
}
|
||||
|
||||
pkg_pretend() {
|
||||
# Protect against people using autounmask overzealously
|
||||
use amd64 || die "google-chrome only works on amd64"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
chromium_suid_sandbox_check_kernel_config
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
:
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dodir /
|
||||
cd "${ED}" || die
|
||||
unpacker
|
||||
|
||||
mv usr/share/doc/${MY_PN} usr/share/doc/${PF} || die
|
||||
|
||||
# Since M141 Google Chrome comes with its own bundled cron
|
||||
# scripts which invoke `apt` directly. Useless on Gentoo!
|
||||
rm -r etc/cron.daily || die "Failed to remove cron scripts"
|
||||
rm -r "${CHROME_HOME}"/cron || die "Failed to remove cron scripts"
|
||||
|
||||
gzip -d usr/share/doc/${PF}/changelog.gz || die
|
||||
gzip -d usr/share/man/man1/${MY_PN}.1.gz || die
|
||||
if [[ -L usr/share/man/man1/google-chrome.1.gz ]]; then
|
||||
rm usr/share/man/man1/google-chrome.1.gz || die
|
||||
dosym ${MY_PN}.1 usr/share/man/man1/google-chrome.1
|
||||
fi
|
||||
|
||||
pushd "${CHROME_HOME}/locales" > /dev/null || die
|
||||
chromium_remove_language_paks
|
||||
popd > /dev/null || die
|
||||
|
||||
rm "${CHROME_HOME}/libqt5_shim.so" || die
|
||||
if ! use qt6; then
|
||||
rm "${CHROME_HOME}/libqt6_shim.so" || die
|
||||
fi
|
||||
|
||||
local suffix=
|
||||
[[ ${PN} == google-chrome-beta ]] && suffix=_beta
|
||||
[[ ${PN} == google-chrome-unstable ]] && suffix=_dev
|
||||
|
||||
local size
|
||||
for size in 16 24 32 48 64 128 256 ; do
|
||||
newicon -s ${size} "${CHROME_HOME}/product_logo_${size}${suffix}.png" ${PN}.png
|
||||
done
|
||||
|
||||
pax-mark m "${CHROME_HOME}/chrome"
|
||||
}
|
||||
@@ -1,3 +1,3 @@
|
||||
DIST microsoft-edge-beta_145.0.3800.22-1_amd64.deb 180270942 BLAKE2B 8f2772ffacd3fbf8755b13eeaed9266531062af69ec007114665e9b8f817ea1be81a2117f8833631ff13def803143eaaa76679f558d13ba277cce6b26614ff12 SHA512 008bd702014bddaec084b83d67e5433e2eac71751f34f571fb2c86d4aea2ff65dad839cb06463519ef77b5e98f3e8708a366659d3180e71060b62d92755c8689
|
||||
DIST microsoft-edge-beta_145.0.3800.36-1_amd64.deb 180388774 BLAKE2B 34a591ae8f0a84ebcea77f1dd5b60816787bc881163dd2f9d925cc483bfcb69de141ead421158b3355142e9e695e6ba75e521e14aebc30320973cfcde8b77866 SHA512 43446f46fcff31c5ff7b2024b5cb46d2c3560de19e2e48a929ffa4bcda8514c0ae963557a8241553abcc327cc25c8f9184ea36570d5b1ec9486c9a230d44ee6c
|
||||
DIST microsoft-edge-beta_145.0.3800.47-1_amd64.deb 180668874 BLAKE2B 460124cf09c6a562249bc25bab2b866876d04198f2bac59d769b2c357d75482b5189727a6b9403eb782cb323bebcc0df6cd03c135373034b4ecaba14d97f3904 SHA512 080c38016868fce3e2d294bb54a985910a33a2ebacdbcc2461f2c0379fd98d4fd7e8be3965be977cead51c399dd9481a89bce1361e95e2523a4a853976a78390
|
||||
DIST microsoft-edge-beta_145.0.3800.53-1_amd64.deb 180680402 BLAKE2B 5a9afdf3cf8b326ebea03575530e6b6abb7b074e2551964878b57fb4b3596317b101ae70e12ed1d09d6784d20083e29a9af71309b30de596e06af5f1fbdc919e SHA512 41891a66f7c86630acbf90e47580cb31ea4605145b13bfedc89b42e134b0035e41a9b526d9719a1e4f4dd08ac37dccc2c9c4ef17e755dbb81ebe893726f7bf05
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
DIST microsoft-edge-dev_145.0.3800.10-1_amd64.deb 180216166 BLAKE2B 94f3b5166ff7b10a540356fb0b1571849ac7e8f7cba5b05d5beaadcecc6ea7df6055e22285b7b017f5862ad240fc899a47e7972c782fd6753dcd9e9ca635b373 SHA512 8feef6a4964316c67d4574213242642a6f6c4c83b5490001b29fcbc28b12b76cf5b8ac64c85b00e38885049d94ac677498c451b772a11e91aea9775664b1c2ff
|
||||
DIST microsoft-edge-dev_146.0.3818.0-1_amd64.deb 180627834 BLAKE2B d533a6089af6bb8dff48ab5fd6595e91dd226e0d023ecaa7c2f7f9754c18403c37c6612a7fbd6252fd1afd5bede37459a68d2887fc76583b7ef2737c5d194b53 SHA512 0984907adb576f46d2d120d30932ab675380e6eb6b09edc7696145bc85fa4ba5235e8d05a2327e6973fba0cb8a27b8beec829426777e70f884e95300c2f3ec8b
|
||||
DIST microsoft-edge-dev_146.0.3829.2-1_amd64.deb 181019794 BLAKE2B 21d4fd40a394e107f78e74a96d19e209a4fc898133cb0e2f74d44232a154bb70e0bd4b34a3ec03fd0768892a1682be1a8eda457620f3ad12217ac6d03f77cea6 SHA512 b9dc7bc6d8bea73807fc311aed13ee88e356cb71662d60ccf2a44a3f24fa5315c8358f58ce986ad62531ddbae0149c303844e9d95146df439e9c311b554161dc
|
||||
DIST microsoft-edge-dev_146.0.3844.0-1_amd64.deb 186125406 BLAKE2B 31241ae4c1c13256e9775a7eaeea556d7bad6eccf05a7b25c2c051b7fdf8e279d0749c0b309a34d2998ee46e91281b1c043b75a44f69a54c2fbc6a8f95a7ef00 SHA512 486a687011e41359850a9c5a9e47be910d4fd4d29a7c2468c719b9cee54ab1c4976b8a490e9cfbb2f604f7098e0fc6e8ddeeee0dcfde2d3ef6cabff3e789e0ba
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
DIST opera-developer_128.0.5783.0_amd64.deb 131785212 BLAKE2B e97f6f7684235be76458d29852e1a23872b0ba076053be8a4e9717ac5e514edd19b4ada74d3807fafc68d1cec0fbfe57c0cceac0835098d13d1642340bc867f8 SHA512 4a48661b02d3ea022b633f1e74e9a35d721b23f78b4ef2334cfc44d9ab951f473c72e4bdbc84526abe9e7eb9e7b99442411cad3e92af582aea4568170b2686ce
|
||||
DIST opera-developer_128.0.5790.0_amd64.deb 131672680 BLAKE2B c2f715fd12b6c00f5dc4a1aba1743d036877a7669b592d054f8714b7a209d4efd635e74f4996f5e47dc4a1693cbea9d26a50f5090f0052028096ad909477e856 SHA512 bcde1d19360e9b187e6a8b21efbb45d8154af7a6a15ec93a2f7cb50c04ab05152ff0c684373927ffdd18346f9873e29b3ca494b7259761b4e5761e238e72a283
|
||||
DIST opera-developer_128.0.5799.0_amd64.deb 132034616 BLAKE2B dda9c1af21804d47ae12df2f8c9920323ea0a00a72532846a4acdfad0a3ea2298ce4a928bb5040dc3ac4784b4d02d7b292873263b4014023d433c0bdefb10a35 SHA512 affda40f1b57b7c119ab437bc2490204d072b82138782a6d634e9ede41bd4267cb1ed712ab0d43052b6b9f03021c8ffb60d9899accb2ce3894c60f7e5b10c1e3
|
||||
DIST opera-developer_128.0.5806.0_amd64.deb 132335972 BLAKE2B bb935feed66625a2d4e8e73f354668fbf81c5ac4cbaf244e0abe93805d45529135c3c9049e08d7c87b23526c97c189467c6faeb031fa25fc51fea6746faa2e2e SHA512 e733abaaace5baf07c11e3cdfc501b6b20b48c305cd981dc72bbe48d4bcc7565f450f6c8d5b457e6a60f7fabbe11c8c74e33e8e3430f7a8ee219d94d8d5c11f9
|
||||
|
||||
@@ -1 +1 @@
|
||||
DIST opera-stable_127.0.5778.14_amd64.deb 131854360 BLAKE2B b41cf4b172c4bacf24261fc4792b1f9ccce0b271752360a0130fbaea77b865e867aefa77339666e9a9b61bf2485c59bb88e48e13695194a48c000353874d4606 SHA512 ed742c9b66de7be6f84af304624611bc697045cb17158acd819f850cc6cf2691bee92d028a708ccc59ee691b6ed2f2c0fc9ee882367f1a69264ab228189266bc
|
||||
DIST opera-stable_127.0.5778.47_amd64.deb 131892816 BLAKE2B 3d135bdf936c615aeac57172b38ac65163d353ca200ed01b82455ec87b074a3e45f17418a7c823357bdbc4263f1ab3977ba42426447a6ed64596c848e79d693a SHA512 8c561fbc29902a2a3e6eab06256f85a4bf3275d7ab43df07fc9b5e80fddb21e325cb08a019ea47ff06de006aa8b5c9d1d2ffb2698f33aa2426db83e3bee06ba7
|
||||
|
||||
@@ -31,7 +31,7 @@ fi
|
||||
# Commit ref from `strings libffmpeg.so | grep -F "FFmpeg version"` matches this Chromium version
|
||||
# or use Chromicler to handle bumps.
|
||||
# Does not _need_ to be updated for every new version of Opera, only when it breaks.
|
||||
CHROMIUM_VERSION="142"
|
||||
CHROMIUM_VERSION="143"
|
||||
SRC_URI="${SRC_URI_BASE[*]/%//${PV}/linux/${MY_PN}_${PV}_amd64.deb}"
|
||||
S=${WORKDIR}
|
||||
|
||||
@@ -2,8 +2,10 @@ DIST google-chrome-beta_142.0.7444.34-1_amd64.deb 117502860 BLAKE2B 129f909409cf
|
||||
DIST google-chrome-beta_143.0.7499.40-1_amd64.deb 117949484 BLAKE2B 9d61a2a0fea90cc3d1e5e233d3b179c5b6b410b6a06df418bea3a5b64b56dd187c09c707856254021eb32c9209da72998c7d3dac73ec3954a00700f63a172904 SHA512 0745c8f78cd5e694ab201ab154dad4dbe958580ba6cb6519c1f545b6ddd705c8baf60d4fc202ccaf234ad41feecff6897531b5913a81483a9e9de04d58bca478
|
||||
DIST google-chrome-beta_144.0.7559.31-1_amd64.deb 118815912 BLAKE2B 92f6dff1da3e18e097b60ed2826f903abb0901a2f6ea37b3859ab9eb1a3b66f35d8eeea77f63a48c05535fde493815cefd5b695e72b42b31fcd6f18c5a0382ee SHA512 0ef8115594bc850111a876ca4f85a995b23b75fd581c26efe8ac807ee9f3bc77e15f3c24fc6423565fd8326c139e3065d1080d247304b99848e3a4f0d8087c3e
|
||||
DIST google-chrome-beta_145.0.7632.45-1_amd64.deb 121087192 BLAKE2B 3b5f44ac08414f9aa4194a628c722c7cd0035b76c448beb511389136e4574961696e1c094b6e576557f576b4bb1e004394220bf8d2cbf55d3402cd3c6ecd8835 SHA512 38bff481636fa32c9e6fe20826cbcc71b6445d7afb18770c977e20569aac427398ceb1f919e77e6e6371c42a02cd21adf39e4ae9f097ac2fa3fdcb9a503bd716
|
||||
DIST google-chrome-beta_146.0.7680.0-1_amd64.deb 127612020 BLAKE2B 1a5ab43ae07295f9a4efee498c0dc34fa90623c78baa182bdb2e335843ab1a1c00bba93e91317640a772d788293996ba374602defff3fd0d677021d6656e4006 SHA512 421b9e193aa5ae51d87ea64e93dd9eebdc58e050c6fff3bf05e7189ec840f12e74d1abd726f66accbc8d8ee246b5ed0152c3bf0a0d26337fc20e07a3546c01ea
|
||||
DIST google-chrome-stable_141.0.7390.107-1_amd64.deb 120556940 BLAKE2B 30075afc39ba771aa9d40cc366efd4d52296cdc269dfef0f5e8ee457181622ef00e614417c62b894b792d58c381d56f77ee3c92e2d8e6efed6f698074dd38488 SHA512 d5ae65f08224a64151c4348ecc8459a50e8ae2d00b0688a5216be2c9faad44962309a1c57bd091b7974a35b6cd8ea8a51c2213c2a9e4c09898ab2938d01f00ae
|
||||
DIST google-chrome-stable_142.0.7444.175-1_amd64.deb 117885136 BLAKE2B 35a125f731147ba38759e83f820425568f1c029730f484633317269228be1f8e26ebae28f13e61cc37e26b5af19443e749d79e6cffa135f0e45812ca1c0628fd SHA512 d046e1e59787330e8e13360cecd827dc9e2dd55712ca3b39306e860b2e5ff85c6d25135f120ba2fe6985e929add560e19971036bacb6b4b5dad5ba14adb36ce7
|
||||
DIST google-chrome-stable_143.0.7499.169-1_amd64.deb 117840328 BLAKE2B ba4cffacff5c002cd8dba3fa8c8e105ebfdcf04884186de0a60cfaa6861662a615c9dd9738cd312ce48ddaee1f62bca2137ee7c872da3aa82ef7a4c44d65b800 SHA512 0c3f3cb76be5c2ffb72f97937b0f7a4079cf04088a00e7debe1bed3325d5e6e6d7a6d60b2fb9a34d389ace8340781aad4221c94c7bae7520eecff25532918254
|
||||
DIST google-chrome-stable_144.0.7559.132-1_amd64.deb 118945608 BLAKE2B 768718c87f7d1bdc3567ab830d312787da9c97fc7985f49ed17aa6d7b1fdf1edf3103b598ed8cf31dbaac0109bb1faf4a93e2b60d9c1bb478916d43b8745973d SHA512 5e0b5b9e16471fc1da53e971f485d70c3ddec8a1d6ec0b0438adfb07eaa0771589c3702c4aeb3cde3b07f886dfc255223affe19a3820b722dc51a24216434205
|
||||
DIST google-chrome-stable_145.0.7632.67-1_amd64.deb 121060256 BLAKE2B 751a1f408476a6780e0f6b56fceb532055e51d1fab446c074745bfbdbaf216e9009f771111ca369544808bbb5744658b4af89c55aac77c490dd48a9bf14dd473 SHA512 2f78e5ee53f28732d3c862a16bb73f6938f7c817e64ea2ed519cf7b5a428e5b1f4c525abd01a08d202e0b449b84e96e74ba6dc6d05ffa362e06e6de6677aca3e
|
||||
DIST google-chrome-unstable_146.0.7670.2-1_amd64.deb 126378580 BLAKE2B df0f2f0f4e0860550135945a0beabbecddeae133d31bc32be98669f5da8b69079cecd56aef07ece7d1c922134ff657157209d55bd73a29e3f2029887858ccbb2 SHA512 56964030b1b72c21297ddac75aa39586f580655506ea8ceb69249820b808e4a701fcd3d92579ce6b41db59739929c056579966bb009efc91197b0b34795fa9f2
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
# Copyright 2012-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit unpacker
|
||||
|
||||
DESCRIPTION="Binary plugins from Google Chrome for use in Chromium"
|
||||
HOMEPAGE="https://www.google.com/chrome/"
|
||||
|
||||
case ${PV} in
|
||||
*_alpha*)
|
||||
SLOT="unstable"
|
||||
CHROMEDIR="opt/google/chrome-${SLOT}"
|
||||
MY_PV=${PV%_alpha}-1
|
||||
;;
|
||||
*_beta*)
|
||||
SLOT="beta"
|
||||
CHROMEDIR="opt/google/chrome-${SLOT}"
|
||||
MY_PV=${PV%_beta}-1
|
||||
;;
|
||||
*)
|
||||
SLOT="stable"
|
||||
CHROMEDIR="opt/google/chrome"
|
||||
MY_PV=${PV}-1
|
||||
;;
|
||||
esac
|
||||
|
||||
MY_PN="google-chrome-${SLOT}"
|
||||
MY_P="${MY_PN}_${MY_PV}"
|
||||
SRC_URI="https://dl.google.com/linux/chrome/deb/pool/main/g/${MY_PN}/${MY_P}_amd64.deb"
|
||||
S="${WORKDIR}/${CHROMEDIR}"
|
||||
|
||||
LICENSE="google-chrome"
|
||||
KEYWORDS="amd64"
|
||||
RESTRICT="bindist mirror strip"
|
||||
|
||||
RDEPEND="
|
||||
dev-libs/glib:2
|
||||
dev-libs/nspr
|
||||
dev-libs/nss
|
||||
sys-libs/glibc
|
||||
"
|
||||
|
||||
for x in 0 beta stable unstable; do
|
||||
if [[ ${SLOT} != ${x} ]]; then
|
||||
RDEPEND+=" !${CATEGORY}/${PN}:${x}"
|
||||
fi
|
||||
done
|
||||
|
||||
QA_PREBUILT="*"
|
||||
|
||||
pkg_nofetch() {
|
||||
eerror "Please wait 24 hours and sync your portage tree before reporting fetch failures."
|
||||
}
|
||||
|
||||
src_install() {
|
||||
insinto "/usr/$(get_libdir)/chromium-browser"
|
||||
doins -r WidevineCdm
|
||||
}
|
||||
@@ -0,0 +1,60 @@
|
||||
# Copyright 2012-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit unpacker
|
||||
|
||||
DESCRIPTION="Binary plugins from Google Chrome for use in Chromium"
|
||||
HOMEPAGE="https://www.google.com/chrome/"
|
||||
|
||||
case ${PV} in
|
||||
*_alpha*)
|
||||
SLOT="unstable"
|
||||
CHROMEDIR="opt/google/chrome-${SLOT}"
|
||||
MY_PV=${PV%_alpha}-1
|
||||
;;
|
||||
*_beta*)
|
||||
SLOT="beta"
|
||||
CHROMEDIR="opt/google/chrome-${SLOT}"
|
||||
MY_PV=${PV%_beta}-1
|
||||
;;
|
||||
*)
|
||||
SLOT="stable"
|
||||
CHROMEDIR="opt/google/chrome"
|
||||
MY_PV=${PV}-1
|
||||
;;
|
||||
esac
|
||||
|
||||
MY_PN="google-chrome-${SLOT}"
|
||||
MY_P="${MY_PN}_${MY_PV}"
|
||||
SRC_URI="https://dl.google.com/linux/chrome/deb/pool/main/g/${MY_PN}/${MY_P}_amd64.deb"
|
||||
S="${WORKDIR}/${CHROMEDIR}"
|
||||
|
||||
LICENSE="google-chrome"
|
||||
KEYWORDS="~amd64"
|
||||
RESTRICT="bindist mirror strip"
|
||||
|
||||
RDEPEND="
|
||||
dev-libs/glib:2
|
||||
dev-libs/nspr
|
||||
dev-libs/nss
|
||||
sys-libs/glibc
|
||||
"
|
||||
|
||||
for x in 0 beta stable unstable; do
|
||||
if [[ ${SLOT} != ${x} ]]; then
|
||||
RDEPEND+=" !${CATEGORY}/${PN}:${x}"
|
||||
fi
|
||||
done
|
||||
|
||||
QA_PREBUILT="*"
|
||||
|
||||
pkg_nofetch() {
|
||||
eerror "Please wait 24 hours and sync your portage tree before reporting fetch failures."
|
||||
}
|
||||
|
||||
src_install() {
|
||||
insinto "/usr/$(get_libdir)/chromium-browser"
|
||||
doins -r WidevineCdm
|
||||
}
|
||||
Reference in New Issue
Block a user