commit: e4df290649b330f7e497fe185eb6faa31febac4f
Author: Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Tue Feb 24 20:01:57 2026 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Tue Feb 24 20:07:42 2026 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e4df2906
mail-client/thunderbird: add 140.8.0
- rebase glibc-2.43 patch for tb,
- rebase the tb-specific patch to remove non-existing .gitmodules (etc)
directories from cargo checksum files,
- sync changes from firefox:esr.
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
mail-client/thunderbird/Manifest | 66 ++
mail-client/thunderbird/thunderbird-140.8.0.ebuild | 1166 ++++++++++++++++++++
2 files changed, 1232 insertions(+)
diff --git a/mail-client/thunderbird/Manifest b/mail-client/thunderbird/Manifest
index 906f933e395b..5fca70401055 100644
--- a/mail-client/thunderbird/Manifest
+++ b/mail-client/thunderbird/Manifest
@@ -1,5 +1,6 @@
DIST firefox-139-loong-patches-02.tar.xz 3096 BLAKE2B
2e9c0f3dac780c808a13f70fe3808df9976898360b55113def97bf3594893166e0647c70ebc389b2d14fa2c2453fc1dd68aba20d92178670ef97d70c34205e1c
SHA512
e1244007290e2e15d14cf519e3ade6a4da06abe41c416de60569a11396609661cb62fb5b592e763cc079406699dc33d6a34851f71068f4d09bdf34021b035a59
DIST firefox-140esr-patches-05.tar.xz 124432 BLAKE2B
9281214dcf3da5d2e288112a99dc1fbee44ee93c4b83e30d73e8383805bd9c8ad9b1918d11351398cd963fdc30ec3cb50d7f6b5c9905d7c1303d21fdef440fbe
SHA512
70551bb7eea2a50bbd30418438a78a8ace07467fe852b7655c24373c651f816df89fceeb98b6fa6c7d95944b0c5deef76b89b3e742795a8ac04259f02bd25c10
+DIST firefox-140esr-patches-07t.tar.xz 157300 BLAKE2B
e522b4a7ddfee044112834fce2e9e1d025d31f0e5a2847de1379f69423c532231bab774c1e5dfe9ff63a3ec798a7b8811790e8b70d510f9b45411893bc0dfa9f
SHA512
6b8bcca3079927311fbe7b3fb4d5092f451070bdb620b33efcb009bf69a7ccae34a484856c59e870805697c7ad3c6ffbb97057cf450fa4e25641b11bf360f72b
DIST firefox-147-patches-02t.tar.xz 47564 BLAKE2B
44c18affb9539278d6e8259bb1c39ca03e2f09f4a29d3051ab1aec3f34c1e5f7dc134fdc2878dbd0c3bcb9373e3d792fd93252e77692e7cfa6aa96a9a1d0bfa0
SHA512
a47bb9967734914f7005846ff1c47600aac4ea217c7bc65f8f6e9501aced696a3666f59c600942be674f22e611112836b1f29ad17504fb78e21dcff0dc10ac62
DIST thunderbird-140.7.2esr-af.xpi 316218 BLAKE2B
e05621d27f36d4044b3b0cd354aeb5696ef8b8db4c7698f36c69d5c5272efa8be15dfe7fcf55a8e19d7e7bb5c17934d71745a3c73e74194892b85e38cc98678e
SHA512
cbd5df4b393925697d1757f52d5c7b9361f2b03d2ed02d577840fddf78209b6167bda37a7720ef5f52e6cf5c6e5d178f93de6935f4f9c9c202b5756ce89fd43a
DIST thunderbird-140.7.2esr-ar.xpi 436197 BLAKE2B
adbb1c4206437757b413b9796177c4855746bc5279466dc7c401787d498557965ada0d8dd66e6151c97cefbb1285d0bb8244a28881548cf2c2a98cf954f06eeb
SHA512
b6d92d0584cfe71bc7c0f5504df5892b30bf5f4d1d32fd29e747274b12c60fc82a775a52f4e8e1ad8bd11819082eb8aca84c06247dccbb9c4347ee173fb958d0
@@ -66,6 +67,71 @@ DIST thunderbird-140.7.2esr-vi.xpi 518884 BLAKE2B
046abbb23a4f0ecb23a693b1842efa
DIST thunderbird-140.7.2esr-zh-CN.xpi 507839 BLAKE2B
7a32d22632c722f2a9f268e2650a4751918d59515673389dad23c0c4ab02ff12b559987cf74f96f7b3f4f0a50346002beb50e1ae8d8b29c4de7ada64fc558e50
SHA512
f5d197567092fd05479f9c0af42d0ed92e6ecccc2885577082e800163baee9262257c95d2a15a528ea90157e8410fa5c2e76e507c41515b8e720e0df677cf28b
DIST thunderbird-140.7.2esr-zh-TW.xpi 511432 BLAKE2B
43764d979777ee1beeb4a4a00caabbb21b314533899818b92268f48b239007826a3cb454a0e81a6fc2b9479bb9e8c2203b5442b8fec578f7abfd4c97a8e16232
SHA512
4ef6688bb2393508a34dd569af2569d4f9faffca92bae5e2bec0978d576a8a9b7733620467115aa42a5767f77ae0ee06b1d55775256fb4324a0d0a62b82eb2cf
DIST thunderbird-140.7.2esr.source.tar.xz 758933224 BLAKE2B
880918c63e4c6750d8dcfc0f3f1cf9628c58c99392552809319a635c3581987b916a186776a85398b038a25769c65a3a8ca71d307c0b509090893106840f2edc
SHA512
513bcaa496f987d0f3906aeb6fe3ea651331470646b0c58479c91bb2c8eb52e389bc8aa646437a03b611ab78bda1df7252545960ffe38086d1fc462e65421819
+DIST thunderbird-140.8.0esr-af.xpi 316221 BLAKE2B
4deef8e5dacb4b9182d99419cc152e07bc2dcae8e8ad651c6cf60e8cce6d7933b03914ee7200aa6e7bb20f20ac51ea866609772fd0ed37725450bf7f934bd63c
SHA512
65812713c774ad829bc9b970b876e17292248c8331b9a91a435a1b45be09b7c59e4185ed046e4307135c4d0de4ae07e86276135cf2ba1ccd298135c564be1e93
+DIST thunderbird-140.8.0esr-ar.xpi 436196 BLAKE2B
6d65a41a7752cca8e0ecf140283275cb483fa34a8909725381be15b0e8b90b3f7760be389dbcaec093a56ada2587808887ac34736ebbb1ad9349354b96fd2c51
SHA512
f11522528c6f44fbd3d0f09a69006ffda4b46344a756e710f76daa8389404d5c547a3789fb930bc93b01abe025d53ac4f76c1a08bbd280baf53555f610150679
+DIST thunderbird-140.8.0esr-ast.xpi 340598 BLAKE2B
be09eb0d4c2cb683cfa61decc88c2dc1dce14b3e31d62e140580741bf3f230afb4f171b467896e16f4ccf7d0166ccbd49b52a7ab648ac7bff419802e904f3f25
SHA512
ddeb8f4f758139414161660b82d2baac9de67fa11a25e30977fb9f84a093f7f2efb756f36dcba2e34d0929227595e1f6a9407acf24324e9e74080f8c9f6a5eed
+DIST thunderbird-140.8.0esr-be.xpi 521575 BLAKE2B
5b79247074d305ca4dbf86a0dd6e0a5b036a940c27e1da9c8ffa06dfbbcd4c14d67446d5d747d60a730f73d9347a81f9c59444ed366a6952fe646115254f4cad
SHA512
98c982cfe844179bb76db968d3cde9a315b5a2c76e4ce25e6dac092ff95f2cea4a29cbaf2a6b62ff4d67a7a2de07b408dfa92c9b9752265a4e840ba5fed070c2
+DIST thunderbird-140.8.0esr-bg.xpi 539807 BLAKE2B
2ce95d1bff2a3efd0b2c8d9d770dcfd5cf15b0516bf37f24392dc0c5aad185ee903e68f0cf0896774e5413af8a5553efc0bfbb5663d84716c549dfa9c4538e13
SHA512
b1642083c4815728838e4b003ebb8ca7513897dd03e7e798e53c3e8f3dabb746da91b2a5c85a4616f6214252d99beb1fd8ef4921c25ae7625e85142c4fec6060
+DIST thunderbird-140.8.0esr-br.xpi 402750 BLAKE2B
19277d7a1963fe0604db7cd5d95e6bed65c65d6c7b78504fd4c1a69d307928079d7e57b2fbd0981999712b374f4946417650ccdb751fb683e777f6555838de40
SHA512
c44710040e01bcb83e4878cf33442aafa0f985903d5d35824ad81c507f241f0ea3bb12d71f6c8ef96a14be3d2e551094937d7eafec457422b91965dfaf99be84
+DIST thunderbird-140.8.0esr-ca.xpi 440588 BLAKE2B
68d4580ef1dea7e04447387f8c7f5b5172d89f503fd561891c41a1c64844926bc50cb2137cd1f359e6cfd20c687c9c14216ccba2428b140f5980ce5559b2c93f
SHA512
6fbc4f5c3df2f26401de54715b0472b14855d8b5a1e77bb845c50a6c1551550f5e509527517a29125747daa69b0c5c1a463f4c5e77390eb72e7387a2d5ef0afe
+DIST thunderbird-140.8.0esr-cak.xpi 418023 BLAKE2B
262b41ba70d2bb2031246e47f29b85305557815d568ca48c22e239018a8d530abc2f274473e254428efd08f47227226c1bb5d85d1736b8bf726327e1bbbcc70d
SHA512
d9321e14d751bcf929bbf7fc1d8e109442dc60296466c213d87ddb7eb27662e5bc6a922ee857387f51b5f3dc10e0ef323c1c0cb57d659d94da7d6d781424e685
+DIST thunderbird-140.8.0esr-cs.xpi 519557 BLAKE2B
2b29f02d017876636a28a2f46662a265d82cf5eb96b282f2925e094818615e65ed6413a7418eeb6b2c783b8ad4dff82fe6be77821345b0682b63c28aab40b475
SHA512
44b3b5e13ca5917291ea527062fd14ab531d4fb20201b70976b5fada22b85433a183ee0bfefc4efd1658d04154d867774913828dc483678b4351009bd36eac8f
+DIST thunderbird-140.8.0esr-cy.xpi 487652 BLAKE2B
6163371b1150078a22fca7f51340db8e30eb8e78f66d8cad0f8d5408a02e1b5c7f3bbb537a8978638a82e6d7a6618cc23f610788bb0ccdd13be1e4fa6180267b
SHA512
f04ddd3815ace59afed44ec438b775f382b46b13552f9c0867b6f8db9c23329bc64c53dc1661add3a038da8dc182f8ec4a8b334a77207b8f0e130df03ad6a615
+DIST thunderbird-140.8.0esr-da.xpi 476626 BLAKE2B
6bb6bbd67d201b4d58daa9910b2bd4d4d94150c322bb4d8c5e3e020312e4567ff31d3e9e05877e9c41d45dabef8b9cbdb5f013d5bb3cca6d4b95466b4bf05c32
SHA512
5f8f41325e85fe0aa401d207f5f83cc9dedde69d09a150d53ec48077be678cb807f000b9010f0fa5bda514a5eadde6ba0e75105f29b095bc3d37c929caae82b4
+DIST thunderbird-140.8.0esr-de.xpi 504710 BLAKE2B
c63f8f0322d7307af30543d310899d380dbbde50e29a46716e30154b95e8209d5ab6b801d4f0804a8a191dedb7b24980b4f061eed822e50df6d27d8ad96327c9
SHA512
1be6fcd6cb995cb0b95d0d106ecb699b396c85921171f6914649761446d5b3cc24774aca6423b23eac72cfeb77ebae73d99961e6145d8e1fa01b33da09cb3398
+DIST thunderbird-140.8.0esr-dsb.xpi 517789 BLAKE2B
71cc64ac3918148e4ba693a7299086845c94c9179a3a111ada7e87c499dcf4270b338314d2fede476d4fddaafa61006b8624f155055fed9bde5a532f2cf6c9b1
SHA512
2d1559cc3cb401326bbc58cac1e0d140c6803ab511a882caf4efa91ce733f92ce0fbd7b8212b03ee12eebb00256c1d6ea2ad3f3da971859b5a625d1138adfe7b
+DIST thunderbird-140.8.0esr-el.xpi 609031 BLAKE2B
8e2303c8da5f07fbccf5857fd7b5a8e5a6ca16634696fe1c376c899c696455466052216f7326a915f2387cd7cf497f9938c66e467ad271e706d0b6111a6772f2
SHA512
28b6289cced75dfbde4303e6db9a20c8eda2281985f4643b830f86625b48f8cc4741582b94ca77488303ecb282c49c45b7a7042010f73bae39b0f97f52d273f5
+DIST thunderbird-140.8.0esr-en-CA.xpi 452241 BLAKE2B
d06c5ecda6006a8f598b508e0222e3b592dca3694cfbb66277e870aa0887d278868f1766e2e5e379fa63ea5af3da5f0fd4700fedcde43383f98f3579cfdd3816
SHA512
cba37df21819a2ce7bf09c0bad105164dde228cabfa73bb97268bb533bcae2eb3bbca80071cde016875e7c7b581242d003a1aedb1c63fcffc80b61a4d6bb8f36
+DIST thunderbird-140.8.0esr-en-GB.xpi 452070 BLAKE2B
dc3839865d3d6507df6ee08d3df0bbc06bec41a99a0dc33a46c633432ead570d5961d61171b8449c0dae5228636cdb04c70678fcdbf169a6ba555976e774e41e
SHA512
37c9659a74f9a5d1b9f3f594b81bfe2c600b56a611e105f1ac273e20e5575bc69e596e790db1e9abf342927e803ff43d81ae4a7c64ec24d7d2a1db8a3cbf2e50
+DIST thunderbird-140.8.0esr-es-AR.xpi 495272 BLAKE2B
8f9ec6c2e704b528cfdb227ecaf41b0595dcf61feb348803305ffd00dd88806458f5877b503a97456fda4600709ed327b94cbfadbea51608f9d0c7aab71e0c9d
SHA512
bd53f0d75b4b9ba20d318774f17fb37ac8eeb79554485d535b5b1e18de3ac9088118d80a50f9be508296cd690df1136eac237baacbe2b2a0941a439b303dd23e
+DIST thunderbird-140.8.0esr-es-ES.xpi 497284 BLAKE2B
2c71454a336353dba53e578f199383d5a3191b1a8dd6d61504b91d4f6a72438c70c26445cff42472a5a353a8be6a4c018d95498bfb025ca15111000ddf90f63e
SHA512
21660852551897311a1d0c16b62b0f9c4d15f517265ac9fd28c76394eb4dc28102699dd9a8def8a7ce27ab01b0da12953cdd32389428721bd5bf8144dd84da17
+DIST thunderbird-140.8.0esr-es-MX.xpi 490827 BLAKE2B
9acbf5bf9c3717d83444f877396f2458afd767ad729aac5ad69fd28fa123355c6d4582209f42194692255edc04e5f16dafc9f6342f0c1544c8878a2c0be7109b
SHA512
9eb28d46033cb2a667f2109eeaa3bcf6d75688f36edf9d2cb952350a636e4dc29eb20624247b7f1d4d9de7c353b42b36d8ba91efefe6c9959df8bc9ba44830a3
+DIST thunderbird-140.8.0esr-et.xpi 443621 BLAKE2B
8deacc9c23339c866c893c7ed27e6f87b69fddcf7f3772b5883502227456df300d3f0190ba3fd847aade629dee10e121abab68d82f2e357e3818bbbf30bbf539
SHA512
7dde0220d294a52e56ca9bca4786c9ad4e9672d02dd6127da39632b7b416593c6f3c7e6f02249ec0989c3ee933459008ac7419a58bc14cf04cb0ef9ad7f24b38
+DIST thunderbird-140.8.0esr-eu.xpi 473925 BLAKE2B
82458f30c95347de839681e6581abea8c4fa6ee79d191fc72ae51417531c0f32e5c05fac785235d705867931b74f1628be1729d1e505a8d4f9592c0aaab6c3e7
SHA512
19acc4e8205c16a4cd9b3dbafbfb1ca99606ce1b4ff9b763a8581bd5b9904e1323e4990c070a7940740e24986f553d21713a56462c91a6bbc5da896f1f6a6da4
+DIST thunderbird-140.8.0esr-fi.xpi 475620 BLAKE2B
fe10b4151705bf4835e9e9091e3a789c1fda72d360fc7107eb08cabaf370cbd0d5ad2d94639d131549986997074f1ec47da12e53bfb8f07a4fbd944bd282b587
SHA512
8e143192aa5fb5c271aa638a6bb0031851bf673fb075b8ecc47c59b89c52aa9e5a2ca097ab405c022a51c3ae39c282b1695c2589165b6b7e97a11eb1c04772d3
+DIST thunderbird-140.8.0esr-fr.xpi 508321 BLAKE2B
7d1181ace78da9a075427264efa389a101a3da86df0821e13dae5ef25e8a9a484a5b7d853f77a7ebd05764bf9e755ba034a6ede56b8e8a455dab69c8edc2b685
SHA512
bd5a20ec80e9d1ed4330c4fb5ade0f7d384f142b61f518bb73f8a4b2f7394222e255747fbf35aff38f02e4e7b653ae662ac3653b8f4a42eaaf762b59f849d210
+DIST thunderbird-140.8.0esr-fy-NL.xpi 490685 BLAKE2B
c88b6a47defac4c411519af5fb53ace9fdcf699e19c5c967e28a533fd7842d3995f91ef4c9a32417f152d44475cd38b5a1f0c5f9527f930a28c115bd6bfd8bd8
SHA512
2ed07edc9cf83f076a1e84325bf5c6caf3847ca2a485ba9d3d951b3bcff132e99bfaaf59de19a55e5ae54fe9aa42414368adbc173fa3458884d4635bb2301dce
+DIST thunderbird-140.8.0esr-ga-IE.xpi 376748 BLAKE2B
0f5561720f81443a44a460f9dd1cc4725a170cd2b0ab5b1c15c10c96d7ecd71f3dacd1b1a345ee1074f0078e957dda8c8d43beae717882a372d4244b650cab96
SHA512
f7da255109250fd15b11d8904e5b0ea927421f7b8842d1541b687a2252557bdbf6d77237166feaea4b05b8b0dae249fd060db77a6281b687876af8160251be0b
+DIST thunderbird-140.8.0esr-gd.xpi 461960 BLAKE2B
08d4f9bae37c43c6094e673b611cf61b722aee076b2d61838a3a93557459ed360480142043ae2bdccf35a4684b3b93543840d46cdedc42602a9c121f12489067
SHA512
ae7cf502b08981f55c294fdee4d4b216b5a81bcfb2eda364aff6193e921ec965f0be81c90c8558e53e71a2a9a953e296704613cf9bf81d8d56d3e73440ed5a36
+DIST thunderbird-140.8.0esr-gl.xpi 489348 BLAKE2B
b0913c171d19533843f356b85b2d149e1c73c827e732452ccab68620aa0a2ab4df27c40a10821ef39aa059d931ff4cfbd289d2178e216af14cc45fce885b57fa
SHA512
ca89225d4995c78faf639cc54502fc09ff011150f8978031b57d9ee293d1367c20ec0559933daafe3a37354da56d86e3809e7176abb728521f8a34dcd84162e1
+DIST thunderbird-140.8.0esr-he.xpi 443787 BLAKE2B
bdb8d01640216e7311466c43243963339c05ac1fc8eb45bfa570bf7a48af2f19006b4181c6a371d0c9717b0defc75abf9cfd4997e43898cbddcea214700ca2c8
SHA512
e9a43d79cb2e7aa6e21de27e97b8813f9eac55d01b658001f49506e2686f1e697bb7a4b668dac35d7d65f50564b77011a8b039501abe81123c552a66f49ee077
+DIST thunderbird-140.8.0esr-hr.xpi 470664 BLAKE2B
ed93a047f38c19af43161cbc79b5ab1e2c15d548547f62868c11aa509e795be3bd9bbef883691064f861f5c78b045ead59ee8001272afd3fc531a5323545ee44
SHA512
290adf0db9ed2ba0e4d8fbc51d11b4f1d1f907341333cb1a240ee0e2f811be3231808211c762386276c0ebda2160e4a6e1b06f5cf2512d5da3562a6dcb4e4c60
+DIST thunderbird-140.8.0esr-hsb.xpi 514952 BLAKE2B
b79296a3dfd62f598615ce956536624a3624ed51dc3922a5ea5ca99e257369f71259b208d9c439d30b73b17ebc2203a8619a575755e702047192bcccc61dc88b
SHA512
cbf49347b07d2a54ff261c904530adabca77e5c53fb6fc7d6b8b4c60501cf8f2115ff340c3a7585116438a5ab5911b693f22a553ce702f437414c54a98a4ba04
+DIST thunderbird-140.8.0esr-hu.xpi 517545 BLAKE2B
2f91a94e62ab8c8c052e70bf373a2110b805c87dc5b298ea0e68deebcd2c693f4a8a999a356a1f80086ebe24fd0d980dd590aa9dafd059955225c7727fe3e3a7
SHA512
d1eb71b8f3c3769bb306c149a8c600ae303925241acb731884bec9b2691edd3acf371a318bb3bfc77b052560249d0262b629f08dbd4f9ae44eaa4b946d789e4a
+DIST thunderbird-140.8.0esr-id.xpi 467006 BLAKE2B
637d57e5de4d90596e0791a73a89cce453ebfd0f72b40e866ca1d75b6e602de4ce8831fd3f61219e295f6d4a03b3fcbebbd16a77ee2944c5fff863686a347e84
SHA512
723e0aad0aac20d4b1f0769f9902f46e8fd7c8856fd5dc3daf9f3af2a837ec9082f131165e5740022589f8981190973f890747e5600970c140b0867ae69d2f65
+DIST thunderbird-140.8.0esr-is.xpi 482740 BLAKE2B
2020c3a9fbd87a0f5ca83b054744caddc2c2cc69d01ca8a7e7f73d2ae8e731d18eef488cec508f24c6d6391edb570625af5ff3b98400f4b829c55788b96d99ff
SHA512
a6ada307c5f26f2e89ee68846c33d2380017ed552f66bc570f2750c9e4b2c3f68ab087d08d0d02b7a3c059f68654bb71df126fe8cb0238aa738b3cee0e0c9642
+DIST thunderbird-140.8.0esr-it.xpi 488505 BLAKE2B
f9f318adca56f66caa02363968618c8fecf8277d25705be8d40c4f7db8b9d302258dff088a6a1244e6fa3c999e82fb52dc4dd3509f90ebf79e1269dd99a48af2
SHA512
08c7bddfbf7848e336b17a3aa004910a963016689beee0ea8fd2c9e1d3af920f0c01429e2e36b654cea74db92b608eab374888f701bf8cfbc34a5793b6cc1175
+DIST thunderbird-140.8.0esr-ja.xpi 539195 BLAKE2B
0bf5e72d49fca3eed7bf20a53a0653f083d18bf7489a1df33086c711ad8933919e26902b976ca4a725c459961c7d1f79406a658e102f049f4cffdda0c5c1b25f
SHA512
5d760540372934017bf4e71dad5eec946f03f8f7f6a76b8edfb8802c407e33356fba908983f507190379d2de5d2ed982ca47383dfa7f136744b17f332902730e
+DIST thunderbird-140.8.0esr-ka.xpi 554766 BLAKE2B
dd13ea1d460c628c9385696fcc32fb938b9327ca6b2d8808debbf99e00a235ddaf4cf9a7907888042abf6a8ea74a7faa56aee79c3eafea8189923e2d1a3e5e76
SHA512
dc914222151315af807b81188a08d4435ab0db1e91f7c3f2ee8cca84ad3f552be0f9847e1be466d428bb4b7dae6af488821b0fab6ad81137078fca02fcf255d2
+DIST thunderbird-140.8.0esr-kab.xpi 470499 BLAKE2B
b6e9f3d0f3078100408a92064e9bf981d13e7ceb2943de2bd3b0cbef34daf7ee2219dc926fdd9dd75844eee6d7eae2b3dc92ace9561260a2ba919dc1ea9df46e
SHA512
8993896b66a26859b756be69dd5d18dda9b2152c0ae363a41c5ded26c0100fc897f9bf4876f03a84bc45c847a72b0b4fd3b00cc56dae7440f1df5815e17fb9c9
+DIST thunderbird-140.8.0esr-kk.xpi 573882 BLAKE2B
ff0d3ab111741179b42f96c25d5b2bf1d64c20d59b1c97a6afcf5c5411f97fe3250aa2c9f105c2008d6b21754ddb7073e4efb3e84eaf5af379fa3a035cadf75e
SHA512
dc90dd56af35ba588d766aae61ca5d5a80fbeadc258fcc8d070e394bc574f52ab995863c53ca4d28550649bc5bfc8dc9ee2770d9d5949907889cc156125362ff
+DIST thunderbird-140.8.0esr-ko.xpi 515592 BLAKE2B
166f4e206bc3301f531a199d49b03efd82fb0b85ee5f10f2dd6b46669180d375f5969e82dd6c0f5481138309951593bff0ade414dcf5c5ec09d41007b768f98f
SHA512
59f11498fddc33f464117ea91029fd1af74cb44da332ade746891c4d61fa14ceb436aa6ef6eefc17dec19a5b1433cbccfe6cdeb6e3c5e71a720049788fc5cc26
+DIST thunderbird-140.8.0esr-lt.xpi 453438 BLAKE2B
d5014500a9162ef85b4c2eb20fd2c1fc1cf03e69a5364cade586001c4a29ec867fd785c27d10edad6819cefa69d3cff302e2db3939bbf778142f6ef17ff0bf96
SHA512
aba8056d349f41c40f5baf24cd25ae342d389b106682a8c0b72f4c77d7e1b4528e344e1050e47aa9d69a1ee00d234792d5239328ddca4b78a678ca3a8c318919
+DIST thunderbird-140.8.0esr-lv.xpi 392815 BLAKE2B
f7bdc8d928d28d8c72c2d12bb22ef1bc5b56d8d0505080f6915ef3cd8849c9763e87f34c967f8466e4f2d444f491a47fa715cd82ad653542a23c1b49b890ff8e
SHA512
63f517b19bbecc70ab785b9b0c7dcde270a0a3ad035531f004e586de38be919e88a468c90c3e0e012dfe8d00884b4c493912de7837dba096e431fc3f990638bc
+DIST thunderbird-140.8.0esr-ms.xpi 352181 BLAKE2B
17dcd2a6cdcfc6430fcd1e238ea990c79fa7adcd22e59af1445962b06499f8defcc3a2ddee9790e8d0b3d7cfc3c6bd7addeaf7949e4ac29019f226d33483bc7a
SHA512
529aca412b6a383e00dc54850c9da5b7f16ab5a1071f828a5cbfd490009d0197c2723ef81d582dcff30873562e4498bf41a0f0b9b8d4bb87099a0872dc38a416
+DIST thunderbird-140.8.0esr-nb-NO.xpi 476138 BLAKE2B
c699c17def062fa3deb1bca435fad716907f97928f51e4d1b1b3de4c30d6c488ab8314f9145d3b647e8323892b2b41309ad45642df9d255676042feb2e6017e0
SHA512
28884459006c4e9e4b35c6251f9969109221e9523ff935c43b70b7464092b044ca342fa40b88b1843a095771f645ac0ca077d573b5d851566515d1de64ee68c1
+DIST thunderbird-140.8.0esr-nl.xpi 482123 BLAKE2B
f17d9bfddf6c5102dc14d9ec4e354814f057c0c3a789f28f296dcad8cc1fb254bbc13c7a478368c15d226534dd597726c2d7210b490a7b02f1378f783d649c71
SHA512
88dcbc183a3f4bdde62f92504571970d7536a917fb1327fb2a640e790bd4cbb755ae53f175560475ffc6d2dff50e55a8924e54d6946d754ec6efc8b73ec527bb
+DIST thunderbird-140.8.0esr-nn-NO.xpi 479761 BLAKE2B
70523c7948478e377e16ac7a2651e51e157af0fe6b2255452a43e46bab2079b4ccf36ed0768d1761605e27535df733dd0b93789dc52d63c1ecdeadfa675a5a13
SHA512
fd2be3c29e62b353d64d43bbff5a6e3e9dfa67265630adfba9ab7e271ec2256dcec3f993c7b0b49991956d9a6909c664a455402f1880c86c3cf71d85f50dbdb3
+DIST thunderbird-140.8.0esr-pa-IN.xpi 435425 BLAKE2B
e9f7b1ae94cf131c0084211e23bc47576d7d282e2ada9597d2cfc5671bc9a3991fa307d2916cb4cf93d8e4f5e7549e9bb30fbd48d4090da764333a7c5d2ceb5a
SHA512
1a818e1422204e82ce1cfd278b420244d640abd2e3287008e8bf9aa130afb4bd0d70c1aad56fe8a867d52a83e8f73b003dbe5504f6f20d7368cf9cd851ed8580
+DIST thunderbird-140.8.0esr-pl.xpi 515610 BLAKE2B
5721217ad436f3cb49c0962cbed67c5a1230bd08979ca3b3cbdee09806643e8ca6b494797fbfa2950f5de1532989da399a32005cdc53fea0b83319a6a65ed108
SHA512
9c690820a0aafa33edff82164b487ef8f160fad6d24abce40c5f6ee5fc67eafbf4d1e189ee1967802b2854bef55076c326cbc4571a9886cf35a3d5619067fbbe
+DIST thunderbird-140.8.0esr-pt-BR.xpi 490167 BLAKE2B
268f9726c0bbfab4b49937ab1b0bec7a60a3849662fb44abd378077cb512c693125131d3afff01573020f487bd576c334cf40394c679c74f2b7b084b39e956df
SHA512
a24a29db9769de87e27f3b1fb19d77782c750bad06b35a9bc70e0cfabc01e4c17229517f6a05ba518e6fd14bdadb527468d1676696b2991b6d0294d3c3305811
+DIST thunderbird-140.8.0esr-pt-PT.xpi 492526 BLAKE2B
36fdd86c098fd5a9b4f1b3a3a6c81920c839c5f080fbaafd5f2a92a9b085985db2de18df161bada59ceb491abe2d34df0b9a508c6c73ee9529adbf98fdbfad93
SHA512
6ec332de063acae1380286f0e3a4a310e20b654d7fe5ab37117f7e44307f2cae14b7227a4b39c8d150e3298eb6a856e15be718697c6bed49ce541e1ee822f57e
+DIST thunderbird-140.8.0esr-rm.xpi 487886 BLAKE2B
229f94269840138ae30a071c0190b7194a9d35871c43dcb5c309d37c3805a2cbc86ec19195a7142b1f35f68f40b6d10db7c628e4a863835c10284a64c3c406ee
SHA512
b3df1ba63afb8d3d775203280375e508d44cd67c13242704ade43764939621111a26de714dce88567527f71e2b0d709d7820e69dfc79834737d6d479abc06a0a
+DIST thunderbird-140.8.0esr-ro.xpi 501096 BLAKE2B
4fc0d245446c2de2e12e83db283c06f6e0f2cc3d731e84bcefb0ae4aefcbeb6a70df56209abf66569e960e5a759afc316dc1dce155b5e949a1bc4e23db428931
SHA512
1c67e1aeece066601fee93024543c3abe7f8e0b77558d182bd79e5474bdb30e1abc3ae885f1f7cc5c68ed80c99142488a73ba57f005be8e9ae0145bda24b0b31
+DIST thunderbird-140.8.0esr-ru.xpi 593289 BLAKE2B
6c4bcf6e758fd220572cbb38f136e81f56e3da0ce91401175aae526e0dbc3873d751997f0dcdaf717040a7068ba788227d32dd52cb2399a67ee22a131721e271
SHA512
57c77b85282781ef344361964df002794955fc81d3229c8b462e6db9980159c991651f29f654f83f7b443727efcb611c8c85d3f400ae7e85e643c2338b60c054
+DIST thunderbird-140.8.0esr-sk.xpi 519390 BLAKE2B
382915883b081a5d8eca89139f8870f53406cb185cd3e5164f36d8cb8ca1add4444610c3d9df67b664707795402cc16ee6fd5ee3d9fde1ced264528105d27383
SHA512
d19ec5319ba5546d6f504419d1e1290deac211e0e293fe76edab6f55b0b8ade89f6262d7e9152def478799c9c0fc99c8d877d8ad71ff01adaa1aee2d1821c6fa
+DIST thunderbird-140.8.0esr-sl.xpi 485962 BLAKE2B
5726090018abb80e225f0e46888c78741d19d3a86a0ff6364ee89cdade4c7e4f17a629b73b6148448227670a9df4376cfed484a2d9d7332b71c246795740a56e
SHA512
35892d8824f5e5d1ed071b63854f266352b174c980d4f0f0da0b9b5b8b19d88de9e8b89dd102eb5222695788ea2cd5e8764b3ce16f64d202f8ca6217dae58351
+DIST thunderbird-140.8.0esr-sq.xpi 506270 BLAKE2B
99d1ea8eddea129222e43689b3cdd1c1bc38bb22f420ddd9d7255b98b1ddb6f845bc0c5fab75d7888b0cbe767ad36b20f2500b022e3b39a9fb56e29bccdd9922
SHA512
2a9dfed38bc84fae8c329b59c2e30df81c66109189f6a358a8ea65af574881d0496a7d241487ce6cf8871c6f39a5eb6416b10b57df94cf88f3935c208f32d907
+DIST thunderbird-140.8.0esr-sr.xpi 495992 BLAKE2B
7c0eb5ea011df2a8226690b447c33788678b75e14cdaec449e2ece2ee131eef7b61d3f80df569c5e4cd72281f89cc98696009f5daaf7f1487c499f3f6df2264b
SHA512
9d6d0abccb4edda373bfc38d09bdd319a7956cdb20bdc1dece98e4b724bb92079b985e682e7bc46536384fae1b5754d9d178e980b02dee53b7d153fb3024a9e2
+DIST thunderbird-140.8.0esr-sv-SE.xpi 484421 BLAKE2B
e036f1207ef023f6ca26abf73dc9f4b05e46fae4dbbade684d5ce536974b9140a9eeebfebd81faeb908679ac8cc2dcf9e5427df28b9d65415174b9c58e5187ca
SHA512
fa4250f335afd00cdcd7189757df43f3dc4db7b36491e2fe19366d0f2aba08e023da323371a2804ced24fc5f35d7b33a45ce22f8dcf90b84f820bce035dbf24a
+DIST thunderbird-140.8.0esr-th.xpi 569104 BLAKE2B
c4311ffdcc8f5b9ae364d9501d0cd3b109344a5ea0106f6245c9c98868c1cad2ce3da256b047f8802e1b6257b4f11d238b093ce364718612f9d3fd8f84966bea
SHA512
79fa68477635533be7accff3625b8a9d1f4575ed8539db0aaabff60fb02f636a155e13ceca9f53b984e645a1e2c9d62db116481c21de65bd9747036a81e72cb5
+DIST thunderbird-140.8.0esr-tr.xpi 496189 BLAKE2B
31a209f7276b0529b75aed4612fc9c4cecca70caf54894d30d25a0226e80c751eb9e3a6c3b2e3bc91f952d2f1551c921a80d29b937ceea0c546d823a49d73aad
SHA512
7b86c3f3994e780bfa42f43c50dc5daf343ab8fa318a18e48e06a5f66927fe2c6ed04ce8b029e52f1b532080404629d106b64c15c9d05ab0a85862db6e9bce49
+DIST thunderbird-140.8.0esr-uk.xpi 582154 BLAKE2B
44a859e1a639d61854d9cc1b5a26bea3e4a285bce3e17f21336363cde80285f656ab11e0f1e145a3bea5d115502510f19258b76fad5222422a0a6e057ffd0c63
SHA512
4b99cf9209d4b556931a8f719fa269f026ea71dfa8b61814a74726a30cb3dcc097472b43310f7c163b3219fdc3c91b51d9a6b32c2b8725fe908cbf9d880511a4
+DIST thunderbird-140.8.0esr-uz.xpi 355270 BLAKE2B
9e2e52dabf50465a5602be7058b4bdc3d2acb4d134f05b41eb1ed5cbe0c7544c24b2d36e728c870e9cce8952d22302888b9aa1bacd938a577722cd6c1e7829f8
SHA512
352595c79aee55c1e3a12f4cc0dccc9a299685ace854e15229d2831db9764f3af74582a1feee66a379b0e9c6170a36db5078d5996f395f12a9bbd290af2b5bca
+DIST thunderbird-140.8.0esr-vi.xpi 518885 BLAKE2B
f69c595897f71dbf33c82db827897b501ab0bfc23a5b3eebcdd2603823d6604c2f44a90bbffaaeb6368c8c3b540763b2f08ff3cfacdfc6e69fcae1fa8c18aa00
SHA512
402e2ffe27e4fc3525999070141df1e4c31fe0aab4f5097ce69da8bd59b8ae3d7dbe93ccd7bab787540d23c29460b7f3a25e63a4cd2d9e1cc3ae6718a4d8e1ea
+DIST thunderbird-140.8.0esr-zh-CN.xpi 507847 BLAKE2B
1352d2a83adb62bdf20d6461d3f997b36d50706a9ff786ea288d77f1238ae90146897d723c0d5f0cb74326e32369d28600e927f00a011ed21d566aca0dcf4946
SHA512
d07702d5e75f2edf08d6a1f8229a183933c1e027844e4e7b01f6879a4bb59676fa5e704e110a46dd35710c4548e914b3ff7f4f19022a01cf172fe5df2f11b042
+DIST thunderbird-140.8.0esr-zh-TW.xpi 511432 BLAKE2B
14b02f1d91580fab0d147e877f16ac7c39a5958503d87397051a57f60136e94f788f22773767e209b7ad5b030fb0d33f8dcab1cc1b8b18f2b8c1c94e800db4c9
SHA512
7949114147e470d5bba7e16c42001710bba2f128aafd6d0cfe4d329464f580f47122749619806fe9e23a6d388239123502912c010856534441bcb2c3b45cfeb1
+DIST thunderbird-140.8.0esr.source.tar.xz 758833112 BLAKE2B
9cf14d3c300edb1f5166e3ec44472d89ad38d65db358d61b648c974a5e7ae51df0343e9cfc14dbfd5f12dd192a4eaae0861956c5dd1210f4731603d1fe53c37a
SHA512
cc9337a87c7c3b8abea2a87b2c494be102e96ca72b3af0969609802640f2d58e7c1c2b0a2ccd1028588578b7115cb0133b404b62652fd537a95b6821ce8f5fe0
DIST thunderbird-147.0.2-af.xpi 312139 BLAKE2B
8cfe583bd0e55686d3a77517318aaa46d2b4038cc7eeee9480c96e775a5eeda6dc3c97736210763930fd9ca28896dab0100a770e1b4213381a26d2866a1270d5
SHA512
bf7a22ad64e2fd2479411f14f1e8f81330a200db87e5d7e3eb4475ffc001fe0ac51515aa9c50172d974f53ef2210a3fcc2493755bf642cfb6aa9106ccb9d4c59
DIST thunderbird-147.0.2-ar.xpi 434055 BLAKE2B
b8d9a4cfa2c13c1a940e14cff780a52cc4db60a9b856ccdf2348e90a07785fc6eec4ac9c399aaa14f6f29e7d8046d4ff8f9693327dbf5843a80bfe1ec8d0a031
SHA512
e1f24efa472c31693ba4dd9de7ce81eaadad6759a8699a235b32ec73fbe05a86a20b0c4043b82ee74ad5ea5dee63481da0c59fc1eaa76595a80049732b3fa2c9
DIST thunderbird-147.0.2-ast.xpi 336206 BLAKE2B
4a72da9cb6087969f2ddca2a060db6f7e0b6ecc5e3508f49ffb566fa260045ea527f3d938e33c68551abe29b8c779fce50346f415f1b1eef8d5ec539dde957a9
SHA512
c6857c61c1ab2bf72c55ba6f967e53eb0b5a2af524f2c4eece806ca689ac6f451a49e2978a3b268d46f669d4205527532cb75de8abb78386b8c160831d25db8b
diff --git a/mail-client/thunderbird/thunderbird-140.8.0.ebuild
b/mail-client/thunderbird/thunderbird-140.8.0.ebuild
new file mode 100644
index 000000000000..ffcae10dd166
--- /dev/null
+++ b/mail-client/thunderbird/thunderbird-140.8.0.ebuild
@@ -0,0 +1,1166 @@
+# Copyright 1999-2026 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+FIREFOX_PATCHSET="firefox-140esr-patches-07t.tar.xz"
+FIREFOX_LOONG_PATCHSET="firefox-139-loong-patches-02.tar.xz"
+
+LLVM_COMPAT=( 19 20 21 )
+
+PYTHON_COMPAT=( python3_{11..14} )
+PYTHON_REQ_USE="ncurses,sqlite,ssl"
+
+RUST_MIN_VER="1.82.0"
+RUST_NEEDS_LLVM=1
+
+WANT_AUTOCONF="2.1"
+
+VIRTUALX_REQUIRED="manual"
+
+# Thunderbird will have separate release and esr channels, matching Firefox's
rapid and esr.
+MOZ_ESR=yes
+
+MOZ_PV=${PV}
+MOZ_PV_SUFFIX=
+if [[ ${PV} =~ (_(alpha|beta|rc).*)$ ]] ; then
+ MOZ_PV_SUFFIX=${BASH_REMATCH[1]}
+
+ # Convert the ebuild version to the upstream Mozilla version
+ MOZ_PV="${MOZ_PV/_alpha/a}" # Handle alpha for SRC_URI
+ MOZ_PV="${MOZ_PV/_beta/b}" # Handle beta for SRC_URI
+ MOZ_PV="${MOZ_PV%%_rc*}" # Handle rc for SRC_URI
+fi
+
+if [[ -n ${MOZ_ESR} ]] ; then
+ # ESR releases have slightly different version numbers
+ MOZ_PV="${MOZ_PV}esr"
+fi
+
+MOZ_PN="${PN%-bin}"
+MOZ_P="${MOZ_PN}-${MOZ_PV}"
+MOZ_PV_DISTFILES="${MOZ_PV}${MOZ_PV_SUFFIX}"
+MOZ_P_DISTFILES="${MOZ_PN}-${MOZ_PV_DISTFILES}"
+
+inherit check-reqs desktop eapi9-ver flag-o-matic gnome2-utils linux-info
llvm-r1 \
+ multiprocessing optfeature pax-utils python-any-r1 rust toolchain-funcs
virtualx xdg
+
+DESCRIPTION="Thunderbird Mail Client"
+HOMEPAGE="https://www.thunderbird.net/"
+
+MOZ_SRC_BASE_URI="https://archive.mozilla.org/pub/${MOZ_PN}/releases/${MOZ_PV}"
+
+if [[ ${PV} == *_rc* ]] ; then
+
MOZ_SRC_BASE_URI="https://archive.mozilla.org/pub/${MOZ_PN}/candidates/${MOZ_PV}-candidates/build${PV##*_rc}"
+fi
+
+PATCH_URIS=(
+ https://dev.gentoo.org/~juippis/mozilla/patchsets/${FIREFOX_PATCHSET}
+)
+
+SRC_URI="${MOZ_SRC_BASE_URI}/source/${MOZ_P}.source.tar.xz ->
${MOZ_P_DISTFILES}.source.tar.xz
+ ${PATCH_URIS[@]}
+ loong? (
+
https://dev.gentoo.org/~xen0n/distfiles/www-client/${MOZ_PN}/${FIREFOX_LOONG_PATCHSET}
+ )"
+S="${WORKDIR}/${PN}-${PV%_*}"
+
+if [[ -n ${MOZ_ESR} ]] ; then
+ SLOT="0/esr"
+else
+ SLOT="0/stable"
+fi
+
+LICENSE="MPL-2.0 GPL-2 LGPL-2.1"
+KEYWORDS="~amd64 ~arm64 ~loong ~ppc64 ~x86"
+
+IUSE="+clang debug eme-free hardened hwaccel jack libproxy pgo pulseaudio
selinux sndio"
+IUSE+=" +system-av1 +system-harfbuzz +system-icu +system-jpeg +system-libevent
+system-libvpx"
+IUSE+=" system-pipewire system-png +system-webp wayland wifi +X"
+
+# Thunderbird-only USE flags.
+IUSE+=" +system-librnp"
+
+REQUIRED_USE="|| ( X wayland )
+ debug? ( !system-av1 )"
+
+TB_ONLY_DEPEND="selinux? ( sec-policy/selinux-thunderbird )
+ !system-librnp? ( dev-libs/jsoncpp )
+ system-librnp? ( >=dev-util/librnp-0.17.1 )"
+BDEPEND="${PYTHON_DEPS}
+ $(llvm_gen_dep '
+ llvm-core/clang:${LLVM_SLOT}
+ llvm-core/llvm:${LLVM_SLOT}
+ clang? (
+ llvm-core/lld:${LLVM_SLOT}
+ pgo? (
llvm-runtimes/compiler-rt-sanitizers:${LLVM_SLOT}[profile] )
+ )
+ ')
+ app-alternatives/awk
+ app-arch/unzip
+ app-arch/zip
+ >=dev-util/cbindgen-0.27.0
+ net-libs/nodejs
+ virtual/pkgconfig
+ amd64? ( >=dev-lang/nasm-2.14 )
+ x86? ( >=dev-lang/nasm-2.14 )
+ pgo? (
+ X? (
+ sys-devel/gettext
+ x11-base/xorg-server[xvfb]
+ x11-apps/xhost
+ )
+ !X? (
+ gui-wm/tinywl
+ x11-misc/xkeyboard-config
+ )
+ )"
+COMMON_DEPEND="${TB_ONLY_DEPEND}
+ >=app-accessibility/at-spi2-core-2.46.0:2
+ dev-libs/glib:2
+ dev-libs/libffi:=
+ >=dev-libs/nss-3.112.3
+ >=dev-libs/nspr-4.36
+ media-libs/alsa-lib
+ media-libs/fontconfig
+ media-libs/freetype
+ media-libs/mesa
+ media-video/ffmpeg
+ sys-apps/dbus
+ virtual/zlib:=
+ virtual/freedesktop-icon-theme
+ x11-libs/cairo
+ x11-libs/gdk-pixbuf:2
+ x11-libs/libdrm
+ x11-libs/pango
+ x11-libs/pixman
+ jack? ( virtual/jack )
+ pulseaudio? (
+ || (
+ media-libs/libpulse
+ >=media-sound/apulse-0.1.12-r4[sdk]
+ )
+ )
+ libproxy? ( net-libs/libproxy )
+ selinux? ( sec-policy/selinux-mozilla )
+ sndio? ( >=media-sound/sndio-1.8.0-r1 )
+ system-av1? (
+ >=media-libs/dav1d-1.0.0:=
+ >=media-libs/libaom-1.0.0:=
+ )
+ system-harfbuzz? (
+ >=media-gfx/graphite2-1.3.13
+ >=media-libs/harfbuzz-2.8.1:0=
+ )
+ system-icu? ( >=dev-libs/icu-76.1:= )
+ system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1:= )
+ system-libevent? ( >=dev-libs/libevent-2.1.12:0=[threads(+)] )
+ system-libvpx? ( >=media-libs/libvpx-1.8.2:0=[postproc] )
+ system-pipewire? ( >=media-video/pipewire-1.4.7-r2:= )
+ system-png? ( >=media-libs/libpng-1.6.45:0=[apng] )
+ system-webp? ( >=media-libs/libwebp-1.1.0:0= )
+ wayland? (
+ >=media-libs/libepoxy-1.5.10-r1
+ x11-libs/gtk+:3[wayland]
+ )
+ wifi? (
+ kernel_linux? (
+ || (
+ net-misc/networkmanager
+ net-misc/connman[networkmanager]
+ )
+ )
+ )
+ X? (
+ virtual/opengl
+ x11-libs/cairo[X]
+ x11-libs/gtk+:3[X]
+ x11-libs/libX11
+ x11-libs/libXcomposite
+ x11-libs/libXdamage
+ x11-libs/libXext
+ x11-libs/libXfixes
+ x11-libs/libXrandr
+ x11-libs/libxcb:=
+ )"
+RDEPEND="${COMMON_DEPEND}
+ jack? ( virtual/jack )"
+DEPEND="${COMMON_DEPEND}
+ X? (
+ x11-base/xorg-proto
+ x11-libs/libICE
+ x11-libs/libSM
+ )"
+
+llvm_check_deps() {
+ if ! has_version -b "llvm-core/clang:${LLVM_SLOT}" ; then
+ einfo "llvm-core/clang:${LLVM_SLOT} is missing! Cannot use LLVM
slot ${LLVM_SLOT} ..." >&2
+ return 1
+ fi
+
+ if use clang && ! tc-ld-is-mold ; then
+ if ! has_version -b "llvm-core/lld:${LLVM_SLOT}" ; then
+ einfo "llvm-core/lld:${LLVM_SLOT} is missing! Cannot
use LLVM slot ${LLVM_SLOT} ..." >&2
+ return 1
+ fi
+ fi
+
+ if use pgo ; then
+ if ! has_version -b
"=llvm-runtimes/compiler-rt-sanitizers-${LLVM_SLOT}*[profile]" ; then
+ einfo
"=llvm-runtimes/compiler-rt-sanitizers-${LLVM_SLOT}*[profile] is missing!" >&2
+ einfo "Cannot use LLVM slot ${LLVM_SLOT} ..." >&2
+ return 1
+ fi
+ fi
+
+ einfo "Using LLVM slot ${LLVM_SLOT} to build" >&2
+}
+
+MOZ_LANGS=(
+ af ar ast be bg br ca cak cs cy da de dsb
+ el en-CA en-GB en-US es-AR es-ES es-MX et eu
+ fi fr fy-NL ga-IE gd gl he hr hsb hu
+ id is it ja ka kab kk ko lt lv ms nb-NO nl nn-NO
+ pa-IN pl pt-BR pt-PT rm ro ru
+ sk sl sq sr sv-SE th tr uk uz vi zh-CN zh-TW
+)
+
+mozilla_set_globals() {
+ # https://bugs.gentoo.org/587334
+ local MOZ_TOO_REGIONALIZED_FOR_L10N=(
+ fy-NL ga-IE gu-IN hi-IN hy-AM nb-NO ne-NP nn-NO pa-IN sv-SE
+ )
+
+ local lang xflag
+ for lang in "${MOZ_LANGS[@]}" ; do
+ # en and en_US are handled internally
+ if [[ ${lang} == en ]] || [[ ${lang} == en-US ]] ; then
+ continue
+ fi
+
+ # strip region subtag if $lang is in the list
+ if has ${lang} "${MOZ_TOO_REGIONALIZED_FOR_L10N[@]}" ; then
+ xflag=${lang%%-*}
+ else
+ xflag=${lang}
+ fi
+
+ SRC_URI+=" l10n_${xflag/[_@]/-}? ("
+ SRC_URI+=" ${MOZ_SRC_BASE_URI}/linux-x86_64/xpi/${lang}.xpi ->
${MOZ_P_DISTFILES}-${lang}.xpi"
+ SRC_URI+=" )"
+ IUSE+=" l10n_${xflag/[_@]/-}"
+ done
+}
+mozilla_set_globals
+
+moz_clear_vendor_checksums() {
+ debug-print-function ${FUNCNAME} "$@"
+
+ if [[ ${#} -ne 1 ]] ; then
+ die "${FUNCNAME} requires exact one argument"
+ fi
+
+ einfo "Clearing cargo checksums for ${1} ..."
+
+ sed -i \
+ -e 's/\("files":{\)[^}]*/\1/' \
+ "${S}"/third_party/rust/${1}/.cargo-checksum.json || die
+}
+
+moz_install_xpi() {
+ debug-print-function ${FUNCNAME} "$@"
+
+ if [[ ${#} -lt 2 ]] ; then
+ die "${FUNCNAME} requires at least two arguments"
+ fi
+
+ local DESTDIR=${1}
+ shift
+
+ insinto "${DESTDIR}"
+
+ local emid xpi_file xpi_tmp_dir
+ for xpi_file in "${@}" ; do
+ emid=
+ xpi_tmp_dir=$(mktemp -d --tmpdir="${T}")
+
+ # Unpack XPI
+ unzip -qq "${xpi_file}" -d "${xpi_tmp_dir}" || die
+
+ # Determine extension ID
+ if [[ -f "${xpi_tmp_dir}/install.rdf" ]] ; then
+ emid=$(sed -n -e '/install-manifest/,$ { /em:id/!d;
s/.*[\">]\([^\"<>]*\)[\"<].*/\1/; p; q }' "${xpi_tmp_dir}/install.rdf")
+ [[ -z "${emid}" ]] && die "failed to determine
extension id from install.rdf"
+ elif [[ -f "${xpi_tmp_dir}/manifest.json" ]] ; then
+ emid=$(sed -n -e 's/.*"id": "\([^"]*\)".*/\1/p'
"${xpi_tmp_dir}/manifest.json")
+ [[ -z "${emid}" ]] && die "failed to determine
extension id from manifest.json"
+ else
+ die "failed to determine extension id"
+ fi
+
+ einfo "Installing ${emid}.xpi into ${ED}${DESTDIR} ..."
+ newins "${xpi_file}" "${emid}.xpi"
+ done
+}
+
+mozconfig_add_options_ac() {
+ debug-print-function ${FUNCNAME} "$@"
+
+ if [[ ${#} -lt 2 ]] ; then
+ die "${FUNCNAME} requires at least two arguments"
+ fi
+
+ local reason=${1}
+ shift
+
+ local option
+ for option in ${@} ; do
+ echo "ac_add_options ${option} # ${reason}" >>${MOZCONFIG}
+ done
+}
+
+mozconfig_add_options_mk() {
+ debug-print-function ${FUNCNAME} "$@"
+
+ if [[ ${#} -lt 2 ]] ; then
+ die "${FUNCNAME} requires at least two arguments"
+ fi
+
+ local reason=${1}
+ shift
+
+ local option
+ for option in ${@} ; do
+ echo "mk_add_options ${option} # ${reason}" >>${MOZCONFIG}
+ done
+}
+
+mozconfig_use_enable() {
+ debug-print-function ${FUNCNAME} "$@"
+
+ if [[ ${#} -lt 1 ]] ; then
+ die "${FUNCNAME} requires at least one arguments"
+ fi
+
+ local flag=$(use_enable "${@}")
+ mozconfig_add_options_ac "$(use ${1} && echo +${1} || echo -${1})"
"${flag}"
+}
+
+mozconfig_use_with() {
+ debug-print-function ${FUNCNAME} "$@"
+
+ if [[ ${#} -lt 1 ]] ; then
+ die "${FUNCNAME} requires at least one arguments"
+ fi
+
+ local flag=$(use_with "${@}")
+ mozconfig_add_options_ac "$(use ${1} && echo +${1} || echo -${1})"
"${flag}"
+}
+
+virtwl() {
+ debug-print-function ${FUNCNAME} "$@"
+
+ [[ $# -lt 1 ]] && die "${FUNCNAME} needs at least one argument"
+ [[ -n $XDG_RUNTIME_DIR ]] || die "${FUNCNAME} needs XDG_RUNTIME_DIR to
be set; try xdg_environment_reset"
+ tinywl -h >/dev/null || die 'tinywl -h failed'
+
+ local VIRTWL VIRTWL_PID
+ coproc VIRTWL { WLR_BACKENDS=headless exec tinywl -s 'echo
$WAYLAND_DISPLAY; read _; kill $PPID'; }
+ local -x WAYLAND_DISPLAY
+ read WAYLAND_DISPLAY <&${VIRTWL[0]}
+
+ debug-print "${FUNCNAME}: $@"
+ "$@"
+ local r=$?
+
+ [[ -n $VIRTWL_PID ]] || die "tinywl exited unexpectedly"
+ exec {VIRTWL[0]}<&- {VIRTWL[1]}>&-
+ return $r
+}
+
+pkg_pretend() {
+ if [[ ${MERGE_TYPE} != binary ]] ; then
+ # Ensure we have enough disk space to compile
+ if use pgo || use debug ; then
+ CHECKREQS_DISK_BUILD="14300M"
+ elif tc-is-lto ; then
+ CHECKREQS_DISK_BUILD="10600M"
+ else
+ CHECKREQS_DISK_BUILD="7400M"
+ fi
+
+ check-reqs_pkg_pretend
+ fi
+}
+
+pkg_setup() {
+
+ # Get LTO from environment; export after this phase for use in
src_configure (etc)
+ use_lto=no
+
+ if [[ ${MERGE_TYPE} != binary ]] ; then
+
+ if tc-is-lto; then
+ use_lto=yes
+ # LTO is handled via configure
+ filter-lto
+ fi
+
+ if use pgo ; then
+ if ! has userpriv ${FEATURES} ; then
+ eerror "Building ${PN} with USE=pgo and
FEATURES=-userpriv is not supported!"
+ fi
+ fi
+
+ if [[ ${use_lto} = yes ]] ; then
+ # -Werror=lto-type-mismatch -Werror=odr are going to
fail with GCC,
+ # bmo#1516758, bgo#942288
+ filter-flags -Werror=lto-type-mismatch -Werror=odr
+ fi
+
+ if use pgo || use debug ; then
+ CHECKREQS_DISK_BUILD="14300M"
+ elif [[ ${use_lto} == "yes" ]] ; then
+ CHECKREQS_DISK_BUILD="10600M"
+ else
+ CHECKREQS_DISK_BUILD="7400M"
+ fi
+
+ check-reqs_pkg_setup
+ llvm-r1_pkg_setup
+ rust_pkg_setup
+ python-any-r1_pkg_setup
+
+ # Avoid PGO profiling problems due to enviroment leakage
+ # These should *always* be cleaned up anyway
+ unset \
+ DBUS_SESSION_BUS_ADDRESS \
+ DISPLAY \
+ ORBIT_SOCKETDIR \
+ SESSION_MANAGER \
+ XAUTHORITY \
+ XDG_CACHE_HOME \
+ XDG_SESSION_COOKIE
+
+ # Build system is using /proc/self/oom_score_adj, bug #604394
+ addpredict /proc/self/oom_score_adj
+
+ if use pgo ; then
+ # Update 105.0: "/proc/self/oom_score_adj" isn't enough
anymore with pgo, but not sure
+ # whether that's due to better OOM handling by Firefox
(bmo#1771712), or portage
+ # (PORTAGE_SCHEDULING_POLICY) update...
+ addpredict /proc
+
+ # Clear tons of conditions, since PGO is
hardware-dependant.
+ addpredict /dev
+ fi
+
+ if ! mountpoint -q /dev/shm ; then
+ # If /dev/shm is not available, configure is known to
fail with
+ # a traceback report referencing
/usr/lib/pythonN.N/multiprocessing/synchronize.py
+ ewarn "/dev/shm is not mounted -- expect build
failures!"
+ fi
+
+ # Google API keys (see
http://www.chromium.org/developers/how-tos/api-keys)
+ # Note: These are for Gentoo Linux use ONLY. For your own
distribution, please
+ # get your own set of keys.
+ if [[ -z "${MOZ_API_KEY_GOOGLE+set}" ]] ; then
+
MOZ_API_KEY_GOOGLE="AIzaSyDEAOvatFogGaPi0eTgsV_ZlEzx0ObmepsMzfAc"
+ fi
+
+ if [[ -z "${MOZ_API_KEY_LOCATION+set}" ]] ; then
+
MOZ_API_KEY_LOCATION="AIzaSyB2h2OuRgGaPicUgy5N-5hsZqiPW6sH3n_rptiQ"
+ fi
+
+ # Mozilla API keys (see
https://location.services.mozilla.com/api)
+ # Note: These are for Gentoo Linux use ONLY. For your own
distribution, please
+ # get your own set of keys.
+ if [[ -z "${MOZ_API_KEY_MOZILLA+set}" ]] ; then
+
MOZ_API_KEY_MOZILLA="edb3d487-3a84-46m0ap1e3-9dfd-92b5efaaa005"
+ fi
+
+ # Ensure we use C locale when building, bug #746215
+ export LC_ALL=C
+ fi
+
+ export use_lto
+}
+
+src_unpack() {
+ local _lp_dir="${WORKDIR}/language_packs"
+ local _src_file
+
+ if [[ ! -d "${_lp_dir}" ]] ; then
+ mkdir "${_lp_dir}" || die
+ fi
+
+ for _src_file in ${A} ; do
+ if [[ ${_src_file} == *.xpi ]]; then
+ cp "${DISTDIR}/${_src_file}" "${_lp_dir}" || die
"Failed to copy '${_src_file}' to '${_lp_dir}'!"
+ else
+ unpack ${_src_file}
+ fi
+ done
+}
+
+src_prepare() {
+ if [[ ${use_lto} == "yes" ]]; then
+ rm -v
"${WORKDIR}"/firefox-patches/*-LTO-Only-enable-LTO-*.patch || die
+ fi
+
+ # Workaround for bgo#915651 on musl
+ if use elibc_glibc ; then
+ rm -v
"${WORKDIR}"/firefox-patches/*bgo-748849-RUST_TARGET_override.patch || die
+ fi
+
+ eapply "${WORKDIR}/firefox-patches"
+ use loong && eapply "${WORKDIR}/firefox-loong-patches"
+
+ # ICU's subslot change should trigger rebuild on Firefox if it is
updated 77->78.
+ if use system-icu && has_version ">=dev-libs/icu-78.1" ; then
+ eapply "${FILESDIR}/firefox-146.0.1-icu78.patch" # bgo#967261
+ fi
+
+ # Allow user to apply any additional patches without modifing ebuild
+ eapply_user
+
+ # Make cargo respect MAKEOPTS
+ export CARGO_BUILD_JOBS="$(makeopts_jobs)"
+
+ # Workaround for bgo#915651
+ if ! use elibc_glibc ; then
+ if use amd64 ; then
+ export RUST_TARGET="x86_64-unknown-linux-musl"
+ elif use x86 ; then
+ export RUST_TARGET="i686-unknown-linux-musl"
+ elif use arm64 ; then
+ export RUST_TARGET="aarch64-unknown-linux-musl"
+ elif use loong; then
+ # Only the LP64D ABI of LoongArch64 is actively
supported among
+ # the wider Linux ecosystem, so the assumption is safe.
+ export RUST_TARGET="loongarch64-unknown-linux-musl"
+ elif use ppc64 ; then
+ export RUST_TARGET="powerpc64le-unknown-linux-musl"
+ elif use riscv ; then
+ # We can pretty safely rule out any 32-bit riscvs, but
64-bit riscvs also have tons of
+ # different ABIs available.
riscv64gc-unknown-linux-musl seems to be the best working
+ # guess right now though.
+ elog "riscv detected, forcing a riscv64 target for now."
+ export RUST_TARGET="riscv64gc-unknown-linux-musl"
+ else
+ die "Unknown musl chost, please post a new bug with
your rustc -vV along with emerge --info"
+ fi
+ fi
+
+ # Make LTO respect MAKEOPTS
+ sed -i -e "s/multiprocessing.cpu_count()/$(makeopts_jobs)/" \
+ "${S}"/build/moz.configure/lto-pgo.configure || die "Failed
sedding multiprocessing.cpu_count"
+
+ sed -i -e "s/multiprocessing.cpu_count()/$(makeopts_jobs)/" \
+ "${S}"/third_party/chromium/build/toolchain/get_cpu_count.py ||
die "Failed sedding multiprocessing.cpu_count"
+
+ sed -i -e "s/multiprocessing.cpu_count()/$(makeopts_jobs)/" \
+ "${S}"/third_party/python/gyp/pylib/gyp/input.py || die "Failed
sedding multiprocessing.cpu_count"
+
+ # sed-in toolchain prefix
+ sed -i \
+ -e "s/objdump/${CHOST}-objdump/" \
+ "${S}"/python/mozbuild/mozbuild/configure/check_debug_ranges.py
|| die "sed failed to set toolchain prefix"
+
+ sed -i \
+ -e 's/ccache_stats = None/return None/' \
+ "${S}"/python/mozbuild/mozbuild/controller/building.py || die
"sed failed to disable ccache stats call"
+
+ einfo "Removing pre-built binaries ..."
+
+ find "${S}"/third_party -type f \( -name '*.so' -o -name '*.o' \)
-print -delete || die
+
+ # Clear checksums from cargo crates we've manually patched.
+ # moz_clear_vendor_checksums xyz
+ # glslopt: bgo#969412, bgo#969871
+ moz_clear_vendor_checksums glslopt
+ # TB-specific
+ sed -i \
+ -e 's/\("files":{\)[^}]*/\1/' \
+ "${S}"/comm/third_party/rust/glslopt/.cargo-checksum.json || die
+
+ # Create build dir
+ BUILD_DIR="${WORKDIR}/${PN}_build"
+ mkdir -p "${BUILD_DIR}" || die
+
+ # Write API keys to disk
+ echo -n "${MOZ_API_KEY_GOOGLE//gGaPi/}" > "${S}"/api-google.key || die
+ echo -n "${MOZ_API_KEY_LOCATION//gGaPi/}" > "${S}"/api-location.key ||
die
+ echo -n "${MOZ_API_KEY_MOZILLA//m0ap1/}" > "${S}"/api-mozilla.key || die
+
+ xdg_environment_reset
+}
+
+src_configure() {
+ # Show flags set at the beginning
+ einfo "Current BINDGEN_CFLAGS:\t${BINDGEN_CFLAGS:-no value set}"
+ einfo "Current CFLAGS:\t\t${CFLAGS:-no value set}"
+ einfo "Current CXXFLAGS:\t\t${CXXFLAGS:-no value set}"
+ einfo "Current LDFLAGS:\t\t${LDFLAGS:-no value set}"
+ einfo "Current RUSTFLAGS:\t\t${RUSTFLAGS:-no value set}"
+
+ local have_switched_compiler=
+ if use clang; then
+ # Force clang
+ einfo "Enforcing the use of clang due to USE=clang ..."
+
+ local version_clang=$(clang --version 2>/dev/null | grep -F --
'clang version' | awk '{ print $3 }')
+ [[ -n ${version_clang} ]] && version_clang=$(ver_cut 1
"${version_clang}")
+ [[ -z ${version_clang} ]] && die "Failed to read clang version!"
+
+ if tc-is-gcc; then
+ have_switched_compiler=yes
+ fi
+
+ AR=llvm-ar
+ CC=${CHOST}-clang-${version_clang}
+ CXX=${CHOST}-clang++-${version_clang}
+ NM=llvm-nm
+ RANLIB=llvm-ranlib
+ elif ! use clang && ! tc-is-gcc ; then
+ # Force gcc
+ have_switched_compiler=yes
+ einfo "Enforcing the use of gcc due to USE=-clang ..."
+ AR=gcc-ar
+ CC=${CHOST}-gcc
+ CXX=${CHOST}-g++
+ NM=gcc-nm
+ RANLIB=gcc-ranlib
+ fi
+
+ if [[ -n "${have_switched_compiler}" ]] ; then
+ # Because we switched active compiler we have to ensure
+ # that no unsupported flags are set
+ strip-unsupported-flags
+ fi
+
+ # Ensure we use correct toolchain,
+ # AS is used in a non-standard way by upstream, #bmo1654031
+ export HOST_CC="$(tc-getBUILD_CC)"
+ export HOST_CXX="$(tc-getBUILD_CXX)"
+ export AS="$(tc-getCC) -c"
+
+ # Configuration tests expect llvm-readelf output, bug 913130
+ READELF="llvm-readelf"
+
+ tc-export CC CXX LD AR AS NM OBJDUMP RANLIB READELF PKG_CONFIG
+
+ # Pass the correct toolchain paths through cbindgen
+ if tc-is-cross-compiler ; then
+ export BINDGEN_CFLAGS="${SYSROOT:+--sysroot=${ESYSROOT}}
--target=${CHOST} ${BINDGEN_CFLAGS-}"
+ fi
+
+ # Set MOZILLA_FIVE_HOME
+ export MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
+
+ # python/mach/mach/mixin/process.py fails to detect SHELL
+ export SHELL="${EPREFIX}/bin/bash"
+
+ # Set state path
+ export MOZBUILD_STATE_PATH="${BUILD_DIR}"
+
+ # Set MOZCONFIG
+ export MOZCONFIG="${S}/.mozconfig"
+
+ # Initialize MOZCONFIG
+ mozconfig_add_options_ac '' --enable-application=comm/mail
+ mozconfig_add_options_ac '' --enable-project=comm/mail
+
+ # Set Gentoo defaults
+ mozconfig_add_options_ac 'Gentoo default' \
+ --allow-addon-sideload \
+ --disable-cargo-incremental \
+ --disable-crashreporter \
+ --disable-disk-remnant-avoidance \
+ --disable-geckodriver \
+ --disable-install-strip \
+ --disable-legacy-profile-creation \
+ --disable-parental-controls \
+ --disable-strip \
+ --disable-tests \
+ --disable-updater \
+ --disable-valgrind \
+ --disable-wmf \
+ --enable-dbus \
+ --enable-js-shell \
+ --enable-negotiateauth \
+ --enable-new-pass-manager \
+ --enable-official-branding \
+ --enable-packed-relative-relocs \
+ --enable-release \
+ --enable-system-policies \
+ --host="${CBUILD:-${CHOST}}" \
+ --libdir="${EPREFIX}/usr/$(get_libdir)" \
+ --prefix="${EPREFIX}/usr" \
+ --target="${CHOST}" \
+ --without-ccache \
+ --without-wasm-sandboxed-libraries \
+ --with-intl-api \
+ --with-libclang-path="$(llvm-config --libdir)" \
+ --with-system-ffi \
+ --with-system-gbm \
+ --with-system-libdrm \
+ --with-system-nspr \
+ --with-system-nss \
+ --with-system-pixman \
+ --with-system-zlib \
+ --with-toolchain-prefix="${CHOST}-" \
+ --with-unsigned-addon-scopes=app,system
+
+ # Set update channel
+ local update_channel=release
+ [[ -n ${MOZ_ESR} ]] && update_channel=esr
+ mozconfig_add_options_ac '' --enable-update-channel=${update_channel}
+
+ # Whitelist to allow unkeyworded arches to build with
"--disable-rust-simd" by default.
+ if use amd64 || use arm64 || use loong ; then
+ mozconfig_add_options_ac '' --enable-rust-simd
+ fi
+
+ # For future keywording: This is currently (97.0) only supported on:
+ # amd64, arm, arm64 & x86.
+ # Might want to flip the logic around if Firefox is to support more
arches.
+ # bug 833001, bug 903411#c8
+ if use loong || use ppc64 || use riscv ; then
+ mozconfig_add_options_ac '' --disable-sandbox
+ else
+ mozconfig_add_options_ac '' --enable-sandbox
+ fi
+
+ # riscv-related options, bgo#947337, bgo#947338
+ if use riscv ; then
+ mozconfig_add_options_ac 'Disable JIT for RISC-V 64'
--disable-jit
+ mozconfig_add_options_ac 'Disable webrtc for RISC-V'
--disable-webrtc
+ fi
+
+ if [[ -s "${S}/api-google.key" ]] ; then
+ local key_origin="Gentoo default"
+ if [[ $(cat "${S}/api-google.key" | md5sum | awk '{ print $1
}') != 709560c02f94b41f9ad2c49207be6c54 ]] ; then
+ key_origin="User value"
+ fi
+
+ mozconfig_add_options_ac "${key_origin}" \
+
--with-google-safebrowsing-api-keyfile="${S}/api-google.key"
+ else
+ einfo "Building without Google API key ..."
+ fi
+
+ if [[ -s "${S}/api-location.key" ]] ; then
+ local key_origin="Gentoo default"
+ if [[ $(cat "${S}/api-location.key" | md5sum | awk '{ print $1
}') != ffb7895e35dedf832eb1c5d420ac7420 ]] ; then
+ key_origin="User value"
+ fi
+
+ mozconfig_add_options_ac "${key_origin}" \
+
--with-google-location-service-api-keyfile="${S}/api-location.key"
+ else
+ einfo "Building without Location API key ..."
+ fi
+
+ if [[ -s "${S}/api-mozilla.key" ]] ; then
+ local key_origin="Gentoo default"
+ if [[ $(cat "${S}/api-mozilla.key" | md5sum | awk '{ print $1
}') != 3927726e9442a8e8fa0e46ccc39caa27 ]] ; then
+ key_origin="User value"
+ fi
+
+ mozconfig_add_options_ac "${key_origin}" \
+ --with-mozilla-api-keyfile="${S}/api-mozilla.key"
+ else
+ einfo "Building without Mozilla API key ..."
+ fi
+
+ mozconfig_use_with system-av1
+ mozconfig_use_with system-harfbuzz
+ mozconfig_use_with system-harfbuzz system-graphite2
+ mozconfig_use_with system-icu
+ mozconfig_use_with system-jpeg
+ mozconfig_use_with system-libevent
+ mozconfig_use_with system-libvpx
+ mozconfig_use_with system-pipewire
+ mozconfig_use_with system-png
+ mozconfig_use_with system-webp
+
+ if use system-librnp; then
+ mozconfig_add_options_ac "+system-librnp"
--enable-compile-environment
+ mozconfig_use_with system-librnp
+ else
+ # This controls the backend of the bundled librnp. Choices are
"botan" and "openssl".
+ # RNP Upstream recommends to use botan. In Gentoo it's
preferred to use system-librnp.
+ mozconfig_add_options_ac "+bundled librnp backend = botan"
--with-librnp-backend="botan"
+ fi
+
+ mozconfig_use_enable libproxy
+
+ use eme-free && mozconfig_add_options_ac '+eme-free' --disable-eme
+
+ if use hardened ; then
+ mozconfig_add_options_ac "+hardened" --enable-hardening
+ append-ldflags "-Wl,-z,relro -Wl,-z,now"
+
+ # Increase the FORTIFY_SOURCE value, #910071.
+ sed -i -e '/-D_FORTIFY_SOURCE=/s:2:3:'
"${S}"/build/moz.configure/toolchain.configure || die
+ fi
+
+ local myaudiobackends=""
+ use jack && myaudiobackends+="jack,"
+ use sndio && myaudiobackends+="sndio,"
+ use pulseaudio && myaudiobackends+="pulseaudio,"
+ ! use pulseaudio && myaudiobackends+="alsa,"
+
+ mozconfig_add_options_ac '--enable-audio-backends'
--enable-audio-backends="${myaudiobackends::-1}"
+
+ mozconfig_use_enable wifi necko-wifi
+
+ if use X && use wayland ; then
+ mozconfig_add_options_ac '+x11+wayland'
--enable-default-toolkit=cairo-gtk3-x11-wayland
+ elif ! use X && use wayland ; then
+ mozconfig_add_options_ac '+wayland'
--enable-default-toolkit=cairo-gtk3-wayland-only
+ else
+ mozconfig_add_options_ac '+x11'
--enable-default-toolkit=cairo-gtk3-x11-only
+ fi
+
+ if [[ ${use_lto} == "yes" ]] ; then
+ if use clang ; then
+ # Upstream only supports lld or mold when using clang.
+ if tc-ld-is-mold ; then
+ # mold expects the -flto line from *FLAGS
configuration, bgo#923119
+ append-ldflags "-flto=thin"
+ mozconfig_add_options_ac "using ld=mold due to
system selection" --enable-linker=mold
+ else
+ mozconfig_add_options_ac "forcing ld=lld due to
USE=clang and USE=lto" --enable-linker=lld
+ fi
+
+ mozconfig_add_options_ac '+lto' --enable-lto=cross
+
+ else
+ # ThinLTO is currently broken, see bmo#1644409.
+ # mold does not support gcc+lto combination.
+ mozconfig_add_options_ac '+lto' --enable-lto=full
+ mozconfig_add_options_ac "linker is set to bfd"
--enable-linker=bfd
+ fi
+
+ else
+ # Avoid auto-magic on linker
+ if use clang ; then
+ # lld is upstream's default
+ if tc-ld-is-mold ; then
+ mozconfig_add_options_ac "using ld=mold due to
system selection" --enable-linker=mold
+ else
+ mozconfig_add_options_ac "forcing ld=lld due to
USE=clang" --enable-linker=lld
+ fi
+
+ else
+ if tc-ld-is-mold ; then
+ mozconfig_add_options_ac "using ld=mold due to
system selection" --enable-linker=mold
+ else
+ mozconfig_add_options_ac "linker is set to bfd
due to USE=-clang" --enable-linker=bfd
+ fi
+ fi
+ fi
+
+ if use pgo ; then
+ mozconfig_add_options_ac '+pgo' MOZ_PGO=1
+
+ if use clang ; then
+ # Used in build/pgo/profileserver.py
+ export LLVM_PROFDATA="llvm-profdata"
+ fi
+ fi
+
+ mozconfig_use_enable debug
+ if use debug ; then
+ mozconfig_add_options_ac '+debug' --disable-optimize
+ mozconfig_add_options_ac '+debug' --enable-jemalloc
+ mozconfig_add_options_ac '+debug' --enable-real-time-tracing
+ else
+ mozconfig_add_options_ac 'Gentoo defaults'
--disable-real-time-tracing
+
+ if is-flag '-g*' ; then
+ if use clang ; then
+ mozconfig_add_options_ac 'from CFLAGS'
--enable-debug-symbols=$(get-flag '-g*')
+ else
+ mozconfig_add_options_ac 'from CFLAGS'
--enable-debug-symbols
+ fi
+ else
+ mozconfig_add_options_ac 'Gentoo default'
--disable-debug-symbols
+ fi
+
+ if is-flag '-O0' ; then
+ mozconfig_add_options_ac "from CFLAGS"
--enable-optimize=-O0
+ elif is-flag '-O4' ; then
+ mozconfig_add_options_ac "from CFLAGS"
--enable-optimize=-O4
+ elif is-flag '-O3' ; then
+ mozconfig_add_options_ac "from CFLAGS"
--enable-optimize=-O3
+ elif is-flag '-O1' ; then
+ mozconfig_add_options_ac "from CFLAGS"
--enable-optimize=-O1
+ elif is-flag '-Os' ; then
+ mozconfig_add_options_ac "from CFLAGS"
--enable-optimize=-Os
+ else
+ mozconfig_add_options_ac "Gentoo default"
--enable-optimize=-O2
+ fi
+ fi
+
+ # Debug flag was handled via configure
+ filter-flags '-g*'
+
+ # Optimization flag was handled via configure
+ filter-flags '-O*'
+
+ # elf-hack
+ # Filter "-z,pack-relative-relocs" and let the build system handle it
instead.
+ if use amd64 || use x86 ; then
+ filter-flags "-z,pack-relative-relocs"
+
+ if tc-ld-is-mold ; then
+ # relr-elf-hack is currently broken with mold,
bgo#916259
+ mozconfig_add_options_ac 'disable elf-hack with mold
linker' --disable-elf-hack
+ else
+ mozconfig_add_options_ac 'relr elf-hack'
--enable-elf-hack=relr
+ fi
+ elif use loong || use ppc64 || use riscv ; then
+ # '--disable-elf-hack' is not recognized on loong/ppc64/riscv,
+ # see bgo #917049, #930046
+ :;
+ else
+ mozconfig_add_options_ac 'disable elf-hack on non-supported
arches' --disable-elf-hack
+ fi
+
+ if ! use elibc_glibc; then
+ mozconfig_add_options_ac '!elibc_glibc' --disable-jemalloc
+ fi
+
+ # System-av1 fix
+ use system-av1 && append-ldflags "-Wl,--undefined-version"
+
+ # Make revdep-rebuild.sh happy; Also required for musl
+ append-ldflags -Wl,-rpath="${MOZILLA_FIVE_HOME}",--enable-new-dtags
+
+ # Pass $MAKEOPTS to build system
+ export MOZ_MAKE_FLAGS="${MAKEOPTS}"
+
+ # Use system's Python environment
+ export PIP_NETWORK_INSTALL_RESTRICTED_VIRTUALENVS=mach
+
+ export MACH_BUILD_PYTHON_NATIVE_PACKAGE_SOURCE="none"
+
+ # Disable notification when build system has finished
+ export MOZ_NOSPAM=1
+
+ # Portage sets XARGS environment variable to "xargs -r" by default which
+ # breaks build system's check_prog() function which doesn't support
arguments
+ mozconfig_add_options_ac 'Gentoo default'
"XARGS=${EPREFIX}/usr/bin/xargs"
+
+ # Set build dir
+ mozconfig_add_options_mk 'Gentoo default' "MOZ_OBJDIR=${BUILD_DIR}"
+
+ # Show flags we will use
+ einfo "Build BINDGEN_CFLAGS:\t${BINDGEN_CFLAGS:-no value set}"
+ einfo "Build CFLAGS:\t\t${CFLAGS:-no value set}"
+ einfo "Build CXXFLAGS:\t\t${CXXFLAGS:-no value set}"
+ einfo "Build LDFLAGS:\t\t${LDFLAGS:-no value set}"
+ einfo "Build RUSTFLAGS:\t\t${RUSTFLAGS:-no value set}"
+
+ # Handle EXTRA_CONF and show summary
+ local ac opt hash reason
+
+ # Apply EXTRA_ECONF entries to $MOZCONFIG
+ if [[ -n ${EXTRA_ECONF} ]] ; then
+ IFS=\! read -a ac <<<${EXTRA_ECONF// --/\!}
+ for opt in "${ac[@]}"; do
+ mozconfig_add_options_ac "EXTRA_ECONF" --${opt#--}
+ done
+ fi
+
+ echo
+ echo "=========================================================="
+ echo "Building ${PF} with the following configuration"
+ grep ^ac_add_options "${MOZCONFIG}" | while read ac opt hash reason; do
+ [[ -z ${hash} || ${hash} == \# ]] \
+ || die "error reading mozconfig: ${ac} ${opt} ${hash}
${reason}"
+ printf " %-30s %s\n" "${opt}" "${reason:-mozilla.org
default}"
+ done
+ echo "=========================================================="
+ echo
+
+ ./mach configure || die
+}
+
+src_compile() {
+ local virtx_cmd=
+
+ if [[ ${use_lto} == "yes" ]] && tc-ld-is-mold ; then
+ # increase ulimit with mold+lto, bugs #892641, #907485
+ if ! ulimit -n 16384 1>/dev/null 2>&1 ; then
+ ewarn "Unable to modify ulimits - building with
mold+lto might fail due to low ulimit -n resources."
+ ewarn "Please see bugs #892641 & #907485."
+ else
+ ulimit -n 16384
+ fi
+ fi
+
+ if use pgo; then
+ # Reset and cleanup environment variables used by GNOME/XDG
+ gnome2_environment_reset
+
+ addpredict /root
+
+ if ! use X; then
+ virtx_cmd=virtwl
+ else
+ virtx_cmd=virtx
+ fi
+ fi
+
+ if ! use X; then
+ local -x GDK_BACKEND=wayland
+ else
+ local -x GDK_BACKEND=x11
+ fi
+
+ ${virtx_cmd} ./mach build --verbose || die
+}
+
+src_install() {
+ # xpcshell is getting called during install
+ pax-mark m \
+ "${BUILD_DIR}"/dist/bin/xpcshell \
+ "${BUILD_DIR}"/dist/bin/${PN} \
+ "${BUILD_DIR}"/dist/bin/plugin-container
+
+ DESTDIR="${D}" ./mach install || die
+
+ # Upstream cannot ship symlink but we can (bmo#658850)
+ rm "${ED}${MOZILLA_FIVE_HOME}/${PN}-bin" || die
+ dosym ${PN} ${MOZILLA_FIVE_HOME}/${PN}-bin
+
+ # Don't install llvm-symbolizer from llvm-core/llvm package
+ if [[ -f "${ED}${MOZILLA_FIVE_HOME}/llvm-symbolizer" ]] ; then
+ rm -v "${ED}${MOZILLA_FIVE_HOME}/llvm-symbolizer" || die
+ fi
+
+ # Install policy (currently only used to disable application updates)
+ insinto "${MOZILLA_FIVE_HOME}/distribution"
+ newins "${FILESDIR}"/distribution.ini distribution.ini
+ newins "${FILESDIR}"/disable-auto-update.policy.json policies.json
+
+ # Install system-wide preferences
+ local PREFS_DIR="${MOZILLA_FIVE_HOME}/defaults/pref"
+ insinto "${PREFS_DIR}"
+ newins "${FILESDIR}"/gentoo-default-prefs-r1.js gentoo-prefs.js
+
+ local GENTOO_PREFS="${ED}${PREFS_DIR}/gentoo-prefs.js"
+
+ # Force hwaccel prefs if USE=hwaccel is enabled
+ if use hwaccel ; then
+ cat "${FILESDIR}"/gentoo-hwaccel-prefs.js \
+ >>"${GENTOO_PREFS}" \
+ || die "failed to add prefs to force hardware-accelerated
rendering to all-gentoo.js"
+
+ if use wayland; then
+ cat >>"${GENTOO_PREFS}" <<-EOF || die "failed to set
hwaccel wayland prefs"
+ pref("gfx.x11-egl.force-enabled", false);
+ EOF
+ else
+ cat >>"${GENTOO_PREFS}" <<-EOF || die "failed to set
hwaccel x11 prefs"
+ pref("gfx.x11-egl.force-enabled", true);
+ EOF
+ fi
+ fi
+
+ # Set dictionary path to use system hunspell
+ cat >>"${GENTOO_PREFS}" <<-EOF || die "failed to set
spellchecker.dictionary_path pref"
+ pref("spellchecker.dictionary_path",
"${EPREFIX}/usr/share/myspell");
+ EOF
+
+ # Force the graphite pref if USE=system-harfbuzz is enabled, since the
pref cannot disable it
+ if use system-harfbuzz ; then
+ cat >>"${GENTOO_PREFS}" <<-EOF || die "failed to set
gfx.font_rendering.graphite.enabled pref"
+ sticky_pref("gfx.font_rendering.graphite.enabled", true);
+ EOF
+ fi
+
+ # Install language packs
+ local langpacks=( $(find "${WORKDIR}/language_packs" -type f -name
'*.xpi') )
+ if [[ -n "${langpacks}" ]] ; then
+ moz_install_xpi "${MOZILLA_FIVE_HOME}/distribution/extensions"
"${langpacks[@]}"
+ fi
+
+ # Install icons
+ local icon_srcdir="${S}/comm/mail/branding/thunderbird"
+ local icon_symbolic_file="${icon_srcdir}/TB-symbolic.svg"
+
+ insinto /usr/share/icons/hicolor/symbolic/apps
+ newins "${icon_symbolic_file}" ${PN}-symbolic.svg
+
+ local icon size
+ for icon in "${icon_srcdir}"/default*.png ; do
+ size=${icon%.png}
+ size=${size##*/default}
+
+ if [[ ${size} -eq 48 ]] ; then
+ newicon "${icon}" ${PN}.png
+ fi
+
+ newicon -s ${size} "${icon}" ${PN}.png
+ done
+
+ # Install menu
+ local app_name="Mozilla ${MOZ_PN^}"
+ local desktop_file="${FILESDIR}/icon/${PN}-r2.desktop"
+ local exec_command="${PN}"
+ local icon="${PN}"
+ local use_wayland="false"
+
+ if [[ -n ${MOZ_ESR} ]] ; then
+ local desktop_filename="${PN}-esr.desktop"
+ else
+ local desktop_filename="${PN}.desktop"
+ fi
+
+ if use wayland ; then
+ use_wayland="true"
+ fi
+
+ cp "${desktop_file}" "${WORKDIR}/${PN}.desktop-template" || die
+
+ sed -i \
+ -e "s:@NAME@:${app_name}:" \
+ -e "s:@EXEC@:${exec_command}:" \
+ -e "s:@ICON@:${icon}:" \
+ "${WORKDIR}/${PN}.desktop-template" || die
+
+ newmenu "${WORKDIR}/${PN}.desktop-template" "${desktop_filename}"
+
+ rm "${WORKDIR}/${PN}.desktop-template" || die
+
+ # Install wrapper script
+ [[ -f "${ED}/usr/bin/${PN}" ]] && rm "${ED}/usr/bin/${PN}"
+ newbin "${FILESDIR}/${PN}-r1.sh" ${PN}
+
+ # Update wrapper
+ sed -i \
+ -e "s:@PREFIX@:${EPREFIX}/usr:" \
+ -e "s:@DEFAULT_WAYLAND@:${use_wayland}:" \
+ "${ED}/usr/bin/${PN}" || die
+}
+
+pkg_postinst() {
+ xdg_pkg_postinst
+
+ if ver_replacing -lt 136.0 ; then
+ elog "In this version of Thunderbird, upstream introduced an
in-app notification"
+ elog "system. Setting pref 'mail.inappnotifications.enabled' to
false and nullifying"
+ elog "'mail.inappnotifications.url' may help you avoid these
messages, if you don't"
+ elog "wish to receive them."
+ fi
+
+ optfeature_header "Optional programs for extra features:"
+ optfeature "desktop notifications" x11-libs/libnotify
+ optfeature "encrypted chat support" net-libs/libotr
+ optfeature "fallback mouse cursor theme e.g. on WMs"
gnome-base/gsettings-desktop-schemas
+}