diff options
Diffstat (limited to 'net-libs/nodejs')
-rw-r--r-- | net-libs/nodejs/Manifest | 21 | ||||
-rw-r--r-- | net-libs/nodejs/files/nodejs-12.22.1-v8_icu69.patch | 85 | ||||
-rw-r--r-- | net-libs/nodejs/files/nodejs-14.16.1-v8_icu69.patch | 84 | ||||
-rw-r--r-- | net-libs/nodejs/files/nodejs-16.0.0-v8_lto.patch | 39 | ||||
-rw-r--r-- | net-libs/nodejs/metadata.xml | 1 | ||||
-rw-r--r-- | net-libs/nodejs/nodejs-12.22.1-r1.ebuild | 228 | ||||
-rw-r--r-- | net-libs/nodejs/nodejs-12.22.1.ebuild (renamed from net-libs/nodejs/nodejs-12.21.0.ebuild) | 2 | ||||
-rw-r--r-- | net-libs/nodejs/nodejs-14.16.1-r1.ebuild | 220 | ||||
-rw-r--r-- | net-libs/nodejs/nodejs-14.16.1.ebuild (renamed from net-libs/nodejs/nodejs-14.16.0.ebuild) | 2 | ||||
-rw-r--r-- | net-libs/nodejs/nodejs-16.0.0-r1.ebuild (renamed from net-libs/nodejs/nodejs-15.11.0.ebuild) | 18 | ||||
-rw-r--r-- | net-libs/nodejs/nodejs-99999999.ebuild | 3 |
11 files changed, 691 insertions, 12 deletions
diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest index b3e2e9a2339d..71a8c380db37 100644 --- a/net-libs/nodejs/Manifest +++ b/net-libs/nodejs/Manifest @@ -1,15 +1,20 @@ AUX nodejs-10.3.0-global-npm-config.patch 819 BLAKE2B 5e40738091bd1f3f18d4cfb2b3a0b94c87c2a570967aec9d418544c182f2e93f28d2dbe564980a975856ca31ab8c115b28fb9374701889cbebe3bba73d4ac83a SHA512 abe27eab0beb3444186fb3c4ce3c67fbc05b684a606f8f8bc4a5bae570fd8fd988f1ad5d65c442842fb6c7b069dc6e3f82577ba6becb1d934ae1039dac074e03 AUX nodejs-12.20.1-fix_ppc64_crashes.patch 1788 BLAKE2B 48a5c5343b654fe57f021644c063b98db32bc634dc1ac5ef4ef9fbc3a1988ae3c7ae51ca989715154f5167ce985b742806de667bf6126bcf535f0ebae448b5ce SHA512 804347c985e59c9e3852af4c3d807ebaff95f1afe88a6ec5785baef51ba6ab9b3257d202fdddc5daa982fd06324a8f828f7d8dca8f99e071c52decea6cb00b83 +AUX nodejs-12.22.1-v8_icu69.patch 2923 BLAKE2B 0e4da87a091dde4f84a980d43223f8d085b50e4cb16fac66d0a275a2257f8b61e1a2996e8a4a469f282c1a7ab622d9b9183b1801818af3ca40051fb4661e8f12 SHA512 e30ecb75b3fdf33cf9efa74250e4b91ab9ebfb81cce4d6f926c6a04cc20bf8222f68b2af4eecbbcd77fa5bc922b8a62be8fe8d918e309baccc09dafa40029e10 AUX nodejs-13.2.0-paxmarking.patch 2710 BLAKE2B 9e63761ce7160434f7f9e5ef76ffd4d0fd61deb24cacd9ac4736bcc74145090d730c6b1d0a60cf9c815a08f22c7925e0719dae835a0ede0b65bb8af53418e016 SHA512 e5aae8fd9758fc1dbfc77f9dbfb62b90941a4b2e9e06a6d70f47aa6462d120e61a1774ba8526b2033161195040326d1b5ad643a816552154ff69a8e2548b3d70 AUX nodejs-13.8.0-paxmarking.patch 4209 BLAKE2B 35a100bc24b638beb35e021a79c1687f8ddefdadbcf08e41d2f860451f7ec6fe8011afdf0198e8f973df7a0fcedd2f66bd3bcf7389be06c27e265822103fc79e SHA512 10d6206e80e7583ba5cd0977d6e067935dc51c00e3c16246dd4f34720a025d1a7b1a794ab7cd0e6a14d4b6d07438735da8230e2fb849f31e05a3372628d42f23 AUX nodejs-14.15.0-fix_ppc64_crashes.patch 1633 BLAKE2B cded0eba081ff80f02ebc019d976503cc30ed8fd9974951d9c8b9dd659db7f17e54f30d59ec171711cfeeda16d43ed49d8b0fc1574c07014d5266c578de02814 SHA512 14b9b0a5963deafb972f455867831ecb349ffd5af229467c1e985c9a6c4f0f4f0faf905a51e50b8a6bf130040dde45407b37ab6d7ad6b1ecb9ef8209d9585396 +AUX nodejs-14.16.1-v8_icu69.patch 2938 BLAKE2B d69206f4903c63df7bf1882bc9d41510a30d2c8bac8141ac08b949578b17e842761edeb10295b95b7aed96cf1ca38c6bdb3bc4b83d8fe2b795a39d50d779f883 SHA512 55933a40c9ca46b2a00a9d6ba6a2b5f08ce0b85692b602b38b05c323c46778f267c8ac5f960661165b4221c8ea84f92bd5957773b9a5e6ff49277a258df3e380 AUX nodejs-15.2.0-global-npm-config.patch 582 BLAKE2B ee05b2b54a0d2f0b7d6d2a1215321315a9a7f2a7b83544fbc4c7c08920d82eccf2ea45530b24aba734b27d82457cd7cf2ef8f780f309f4411ab973738fa3cbfd SHA512 e5dff5f8007716e2c3d6ea5829b2ed42ff9e458b751d06772c51b77a36b188f167c1d637a74ae7cf5c2b97c28436213f02374b0dbef5440607ce4e1c3e586e86 +AUX nodejs-16.0.0-v8_lto.patch 1332 BLAKE2B 75807eecfca7275afdde465ad20d558822e06488ecfc9d22a0e57826abafb3f3b66f77484fcdc078142ba7293d627a25d7d3ccdfecc7610cb076f919900c794c SHA512 26e4e1a64356800de20609543ddbac2e5adad04faf28962cbbfcb6499e3a9d38e391f945353ac3f5e9f997dfb666aa3260b0296e55317f9aa2c8c3f4bd894003 AUX nodejs-99999999-llhttp.patch 506 BLAKE2B eea449910b97dfc320247f20bf20467f6c5bfe46f7acc95761270928b3413ffaa04ee948d8dece9a8ba47288804144c75ebda1009af17169b36bcd5b39aa0c33 SHA512 13cdbaf73696b4feef1fec48ac43f6a6d80f59096a81308c746655e2cffa0b0ef78850facff103f27062fd25192d8abd7bc200b36bd25df7bd4b800f80da0c5c -DIST node-v12.21.0.tar.xz 23650552 BLAKE2B 532eef3e77d78aa1b6f30ebdc1dee88ed95280c86e44db525ce369cb1c2d9707a30a1a4ec2d8e699f7c1a14ada036fc4d62d0f0c7fa017e72768662768bbbf18 SHA512 48df48a12657e3a2366cd80a1a7040365b7a90053676230f1f93f253a1fcdafc5bc1df5b5ec5c13f616277b5feb7e7653cd145ab9c23222bf7702d7cd1fa74eb -DIST node-v14.16.0.tar.xz 33301140 BLAKE2B faf380e8f02ea2e6084601fece1e9d3119aeabcebc844fd22a79c18e27cf54f0cd470971cc5a86277a226e59950f511e1173828565bdda1c1f06c52b144cba6f SHA512 ac6f7408df35e2bae8bcad3f461d8e260a2762c77f78d737b0339a592724ff1a98ba171a95e44366e731accfb3208e7cfd6d3edd0f646ddc26a01cfbdbbb655b -DIST node-v15.11.0.tar.xz 33285300 BLAKE2B 50f38e46faa7a7c206bf6f82827643c4f6c06ed3e1bc8a12f06badc024b88e801e749524123134146547e7af3403110db11a5d1717a2a91c0ccd875ef91de457 SHA512 e6c7d6fb2f7008d911a63c120cf7f82fb78eff2b57a934f57e6c8294be3b16f0ab982b828989772f04199e609d2dc0c90067ec517ec1e27991f1275e0ced204a -EBUILD nodejs-12.21.0.ebuild 6349 BLAKE2B 08f6f25f315071349f666e05b1f72bc84c5cb0051c1bb57ee9c0d0dd6d4c788d9dbddece7f50499a093cb163ccf3ed31f3775bef8d62e7316c5acfca9d2ee77a SHA512 b97e404361cb96d7052f0af64143840404f129d700fd1d00c0dfccfd0ab14b33ad1a804fc5df0f73baaa62b4d7065afc4cfdd8100329e27ab91fe4bdcf718f77 -EBUILD nodejs-14.16.0.ebuild 6046 BLAKE2B 33b0f4ceee6472129bebeb1db5d9f2f73028e5695eec5f92a877f63b1a33e41f80c8d119774dd0f002032e3a28debdc2a2040109165b9c39bd2a716925a38d4a SHA512 1c598f9699aaa8750455aa38717f005e3ff2284a8cc801a56e4a789c96f298503d7db9ff258c526dfcb0b4986c9f60a900671e25e35b999bd4a71325bed70e4e -EBUILD nodejs-15.11.0.ebuild 5676 BLAKE2B aee7588049a09db4823eca4588623562e7b0f812f41f03681be5372579ed8eab9bdc38ce2c353e40de9c7fa6da05068be289d6319c1757b1cbfbb361b71c8d02 SHA512 9bbab3ef03347a9530079d12c221ce785770349f155e056a8ea39eba42c48f9cce2ab1315fd8ca9532f0cee354c2192c5072cc29cfb43bd77229f80a205d74f7 -EBUILD nodejs-99999999.ebuild 5810 BLAKE2B 09269b4cc4195a868bb354481ae05dd3c6e8e87f0cb9ce5c4d29ac109f089356b9e8cda637e6811c4d54b3ef8c3d4612524b5d31ad64544acb44337dbaa0b027 SHA512 564ba9370405160da4596f6719b35ceb056c4ca4622c22f8a4ec592494496e73f18dcfb68f1dddfe04f989aaa2465c46118d15c811363b7eb21a75a6444c79a9 -MISC metadata.xml 940 BLAKE2B c1a7dbc678f50529afe12abaa96e87bd065d1bdb88e6ca4d7d58373b282a5d6c6920e43623ce71bc83affb54cc323e6d24df8841dce8001e1cb598dd96b0d4a4 SHA512 87c823b94b22026cbf333671f6d28928de66c5aee29fbe0d9773c4c35415ffc3f7e31559530cfda4f4f2a0a9dcb4964e0c3304c002182c4c17de785e842c0fee +DIST node-v12.22.1.tar.xz 23650180 BLAKE2B 90b0a8ab3842483fea0c776e0245e63539a986c18f55abd8c7cd22ec399ccde22fa5b008d3e07c0f07713b5a45a1ee2a0bc370c04408800db2ee59cd92fcb5be SHA512 eaead633611bda04ab9be200aeddf3b4004b8104e9c6af246023b8008003dd3a7103e1508ea690443e59c6591521b04a2d71c7344343f2a20d1c935ef51c66a0 +DIST node-v14.16.1.tar.xz 33297064 BLAKE2B 0927434c63cd248e90a4002b50c7a0fd68a5527a4cd7424b451840ddf0c403ba452979b195e598cc3b323e24233248a74a1274519ce8cd3a2f4e71dc7a8f3dcb SHA512 d4f5fbab69592ae555613b2186090b85a458d2211b6035989aee2617bfd0f6768ca767ec45ce12756a9c452d00af7237edee3b1ae526049e9fcd01f8f67680c0 +DIST node-v16.0.0.tar.xz 33784448 BLAKE2B 3286cf6522074cb7b17dce8fce642204777fef26fd4bdb904fdef638061913a1eccda13b8e2f170906dd9098500c8fae7eaea7275e41bf97ea6d9fdd644b215c SHA512 6b976a8959079751bfdece15614a6286088d9145fc4db4ae048aca2ede4b7e38e86e91b1722be51eb4c934749a144a745e425ccf118bed9848c30ff254de2557 +EBUILD nodejs-12.22.1-r1.ebuild 6502 BLAKE2B db0d5b6d59a5ccd8ba664fb2ae26556974645bee3fcf3f80ae939191a6edc2b0de57534f07e53c1b22660a93419085813043285dd0a8b20c035361bdfbe554fb SHA512 f5ea68dc5d4af6eb21c1919c2babc9eb811a69fd8ab28d74d23791b366becf7e6dfaef2b46ecbada92ca8f8213263ceb7cf7faf532551cf71510041cedabd255 +EBUILD nodejs-12.22.1.ebuild 6412 BLAKE2B 7e5671b07a93b739c8b3a84730f0a873dc18c6746fe25a112ef8efc6bcc44c5c68a4df3eb16cea05cbe0ef786857a4b417c463ae3469d3d09c1d1bb1ae5e1725 SHA512 b38fef7e77ac63f589d52b4836483aaa36ec36597f130e83334b3a59a9bc7e7c98fa3d2ada868472db556240b355ebf4415b656823adc60b5f1965a010e97a4a +EBUILD nodejs-14.16.1-r1.ebuild 6350 BLAKE2B 59f5551677f92602d6b3436dd0a4fca69c46482d5cf374957c1305ebdde0d1047f70f7360fba4670d52149fa1ad0c460b31bdbf34c4424b1f6b5279aed69b4f2 SHA512 1b10ad0e445953c3c258d4e16e4211ba40a229ea49808070c26bbcc53c4f3cc29dae2eb89e8ec8c1dec95a3443cd505f79e99702d2bbcf1ba4797963e58b7d5b +EBUILD nodejs-14.16.1.ebuild 6109 BLAKE2B 55b923b81044645154639c0768f2905b612dcea70e703451bc5bb0868f17c7c635017ab9d390cff31c2903e0b0226e5c5c0a5323d73eecb3ea730ca7ace83cc7 SHA512 017c31360f866ea46b435dcf1ba84cb8075bcdf3925da51e1c81a0b3f0a73e3b4f31b0192ea6efa890e64eb9d3ccf548fc57f17bb44f5c20c5cdf0736b287eb3 +EBUILD nodejs-16.0.0-r1.ebuild 5972 BLAKE2B dad7e624c9dee18f61b4d3a3d04655906e9365d0060c61c3761bb346add4187a4ea3c10d2c08b9486fe7d9d1530b1c359474c60a5db4126f1284c240e48f8f18 SHA512 e0c7e5f2003b667c163efa8b8e5512e0e45357b02c09acd450a3d1f09da0be6a70232a170ea2a0c290c47b35ecfc4c3d4fbf11d29426293b8fd3f6391e8bc245 +EBUILD nodejs-99999999.ebuild 5829 BLAKE2B c6c38b692df78a6292fda7f651ab9be5502f202d4c69831c4ae639b873e7d5b846899f245e88bb49bcbfe154750e6512dab01223e57c3188dae61112696b0a65 SHA512 ecc304e439c60d1f7f64e448e81eb12675fda7f8471b0a6341711c435509de81c90eb170c63a4c2b9f4cc5fcbd8fc604c40d6affa41d827f4f5ec46f474f0ae9 +MISC metadata.xml 1000 BLAKE2B 4785dba31037ad28281266047c8e59cd1d3e0e723128831f3aebc0436727b41c283284a450b5c619868e0317d3bc61e239a85e0d47773e9867f2606d5dd59047 SHA512 6556cf00ea009b394a56de614226b8cf0e04e868f47d827dba1907b5d89b957d738e4529b6338126cff9ccbd573c4451e9c2d5d4f93e4e4dad376e88419ef489 diff --git a/net-libs/nodejs/files/nodejs-12.22.1-v8_icu69.patch b/net-libs/nodejs/files/nodejs-12.22.1-v8_icu69.patch new file mode 100644 index 000000000000..bd6d5c64b02d --- /dev/null +++ b/net-libs/nodejs/files/nodejs-12.22.1-v8_icu69.patch @@ -0,0 +1,85 @@ +Port of the Chromium commit 035c305ce7761f51328b45f1bd83e26aef267c9d to node-v12. +Original commit message follows. + +Author: Frank Tang <ftang@chromium.org> +AuthorDate: 2020-10-15 22:44:27 -0700 +Commit: Commit Bot <commit-bot@chromium.org> +CommitDate: 2020-10-20 02:08:13 +0000 +[Intl] call new ListFormatter::createInstance +The one we currently using is now marked as internal and to be removed +for 68. Migrating to the style which already avaiable in ICU 67-1. + +--- a/deps/v8/src/objects/js-list-format.cc ++++ b/deps/v8/src/objects/js-list-format.cc +@@ -29,46 +29,27 @@ + namespace internal { + + namespace { +-const char* kStandard = "standard"; +-const char* kOr = "or"; +-const char* kUnit = "unit"; +-const char* kStandardShort = "standard-short"; +-const char* kOrShort = "or-short"; +-const char* kUnitShort = "unit-short"; +-const char* kStandardNarrow = "standard-narrow"; +-const char* kOrNarrow = "or-narrow"; +-const char* kUnitNarrow = "unit-narrow"; + +-const char* GetIcuStyleString(JSListFormat::Style style, +- JSListFormat::Type type) { ++UListFormatterWidth GetIcuWidth(JSListFormat::Style style) { ++ switch (style) { ++ case JSListFormat::Style::LONG: ++ return ULISTFMT_WIDTH_WIDE; ++ case JSListFormat::Style::SHORT: ++ return ULISTFMT_WIDTH_SHORT; ++ case JSListFormat::Style::NARROW: ++ return ULISTFMT_WIDTH_NARROW; ++ } ++ UNREACHABLE(); ++} ++ ++UListFormatterType GetIcuType(JSListFormat::Type type) { + switch (type) { + case JSListFormat::Type::CONJUNCTION: +- switch (style) { +- case JSListFormat::Style::LONG: +- return kStandard; +- case JSListFormat::Style::SHORT: +- return kStandardShort; +- case JSListFormat::Style::NARROW: +- return kStandardNarrow; +- } ++ return ULISTFMT_TYPE_AND; + case JSListFormat::Type::DISJUNCTION: +- switch (style) { +- case JSListFormat::Style::LONG: +- return kOr; +- case JSListFormat::Style::SHORT: +- return kOrShort; +- case JSListFormat::Style::NARROW: +- return kOrNarrow; +- } ++ return ULISTFMT_TYPE_OR; + case JSListFormat::Type::UNIT: +- switch (style) { +- case JSListFormat::Style::LONG: +- return kUnit; +- case JSListFormat::Style::SHORT: +- return kUnitShort; +- case JSListFormat::Style::NARROW: +- return kUnitNarrow; +- } ++ return ULISTFMT_TYPE_UNITS; + } + UNREACHABLE(); + } +@@ -170,7 +151,7 @@ + icu::Locale icu_locale = r.icu_locale; + UErrorCode status = U_ZERO_ERROR; + icu::ListFormatter* formatter = icu::ListFormatter::createInstance( +- icu_locale, GetIcuStyleString(style_enum, type_enum), status); ++ icu_locale, GetIcuType(type_enum), GetIcuWidth(style_enum), status); + if (U_FAILURE(status)) { + delete formatter; + FATAL("Failed to create ICU list formatter, are ICU data files missing?"); diff --git a/net-libs/nodejs/files/nodejs-14.16.1-v8_icu69.patch b/net-libs/nodejs/files/nodejs-14.16.1-v8_icu69.patch new file mode 100644 index 000000000000..d1e204f0c5d4 --- /dev/null +++ b/net-libs/nodejs/files/nodejs-14.16.1-v8_icu69.patch @@ -0,0 +1,84 @@ +Port of the Chromium commit 035c305ce7761f51328b45f1bd83e26aef267c9d to node-v14. +Original commit message follows. + +Author: Frank Tang <ftang@chromium.org> +AuthorDate: 2020-10-15 22:44:27 -0700 +Commit: Commit Bot <commit-bot@chromium.org> +CommitDate: 2020-10-20 02:08:13 +0000 +[Intl] call new ListFormatter::createInstance +The one we currently using is now marked as internal and to be removed +for 68. Migrating to the style which already avaiable in ICU 67-1. + +--- a/deps/v8/src/objects/js-list-format.cc ++++ b/deps/v8/src/objects/js-list-format.cc +@@ -29,46 +29,26 @@ + namespace internal { + + namespace { +-const char* kStandard = "standard"; +-const char* kOr = "or"; +-const char* kUnit = "unit"; +-const char* kStandardShort = "standard-short"; +-const char* kOrShort = "or-short"; +-const char* kUnitShort = "unit-short"; +-const char* kStandardNarrow = "standard-narrow"; +-const char* kOrNarrow = "or-narrow"; +-const char* kUnitNarrow = "unit-narrow"; ++UListFormatterWidth GetIcuWidth(JSListFormat::Style style) { ++ switch (style) { ++ case JSListFormat::Style::LONG: ++ return ULISTFMT_WIDTH_WIDE; ++ case JSListFormat::Style::SHORT: ++ return ULISTFMT_WIDTH_SHORT; ++ case JSListFormat::Style::NARROW: ++ return ULISTFMT_WIDTH_NARROW; ++ } ++ UNREACHABLE(); ++} + +-const char* GetIcuStyleString(JSListFormat::Style style, +- JSListFormat::Type type) { ++UListFormatterType GetIcuType(JSListFormat::Type type) { + switch (type) { + case JSListFormat::Type::CONJUNCTION: +- switch (style) { +- case JSListFormat::Style::LONG: +- return kStandard; +- case JSListFormat::Style::SHORT: +- return kStandardShort; +- case JSListFormat::Style::NARROW: +- return kStandardNarrow; +- } ++ return ULISTFMT_TYPE_AND; + case JSListFormat::Type::DISJUNCTION: +- switch (style) { +- case JSListFormat::Style::LONG: +- return kOr; +- case JSListFormat::Style::SHORT: +- return kOrShort; +- case JSListFormat::Style::NARROW: +- return kOrNarrow; +- } ++ return ULISTFMT_TYPE_OR; + case JSListFormat::Type::UNIT: +- switch (style) { +- case JSListFormat::Style::LONG: +- return kUnit; +- case JSListFormat::Style::SHORT: +- return kUnitShort; +- case JSListFormat::Style::NARROW: +- return kUnitNarrow; +- } ++ return ULISTFMT_TYPE_UNITS; + } + UNREACHABLE(); + } +@@ -143,7 +123,7 @@ + icu::Locale icu_locale = r.icu_locale; + UErrorCode status = U_ZERO_ERROR; + icu::ListFormatter* formatter = icu::ListFormatter::createInstance( +- icu_locale, GetIcuStyleString(style_enum, type_enum), status); ++ icu_locale, GetIcuType(type_enum), GetIcuWidth(style_enum), status); + if (U_FAILURE(status) || formatter == nullptr) { + delete formatter; + THROW_NEW_ERROR(isolate, NewRangeError(MessageTemplate::kIcuError), diff --git a/net-libs/nodejs/files/nodejs-16.0.0-v8_lto.patch b/net-libs/nodejs/files/nodejs-16.0.0-v8_lto.patch new file mode 100644 index 000000000000..a3e4acb02c3a --- /dev/null +++ b/net-libs/nodejs/files/nodejs-16.0.0-v8_lto.patch @@ -0,0 +1,39 @@ +From ea694e2b138d2f991989e09fc0e964fec3587b5f Mon Sep 17 00:00:00 2001 +From: Jesse Chan <jc@linux.com> +Date: Thu, 22 Apr 2021 19:41:09 +0800 +Subject: [PATCH] tools: disable LTO for "v8_cppgc_shared" target + +"PushAllRegistersAndIterateStack" is implemented in assembly and +called from "stack.cc" via 'extern "C"'. [1] + +However, LTO does not work well with symbol usage from assembly. [2] + +This change workarounds the issue by disabling LTO for the target. + +With GCC 10 and "./configure --enable-lto", compilation succeeds +after this change. + +[1] v8/v8@c10863153 +[2] https://gcc.gnu.org/wiki/LinkTimeOptimizationFAQ#Symbol_usage_from_assembly_language + +Refs: #35957 +Refs: #38335 +Signed-off-by: Jesse Chan <jc@linux.com> +--- + tools/v8_gypfiles/v8.gyp | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/tools/v8_gypfiles/v8.gyp b/tools/v8_gypfiles/v8.gyp +index ccb5984f47d..377e12d1fdc 100644 +--- a/tools/v8_gypfiles/v8.gyp ++++ b/tools/v8_gypfiles/v8.gyp +@@ -1378,6 +1378,9 @@ + '<(V8_ROOT)/src/heap/base/worklist.h', + ], + 'conditions': [ ++ ['enable_lto=="true"', { ++ 'cflags_cc': [ '-fno-lto' ], ++ }], + ['clang or OS!="win"', { + 'conditions': [ + ['_toolset == "host" and host_arch == "x64" or _toolset == "target" and target_arch=="x64"', { diff --git a/net-libs/nodejs/metadata.xml b/net-libs/nodejs/metadata.xml index db1b9aefa8e0..15befbfa251b 100644 --- a/net-libs/nodejs/metadata.xml +++ b/net-libs/nodejs/metadata.xml @@ -12,6 +12,7 @@ </maintainer> <use> <flag name="inspector">Enable V8 inspector</flag> + <flag name="lto">Build with link-time optimisation</flag> <flag name="npm">Enable NPM package manager</flag> <flag name="pax_kernel">Enable building under a PaX enabled kernel</flag> <flag name="snapshot">Enable snapshot creation for faster startup</flag> diff --git a/net-libs/nodejs/nodejs-12.22.1-r1.ebuild b/net-libs/nodejs/nodejs-12.22.1-r1.ebuild new file mode 100644 index 000000000000..aa8392c1ff25 --- /dev/null +++ b/net-libs/nodejs/nodejs-12.22.1-r1.ebuild @@ -0,0 +1,228 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{7..9} ) +PYTHON_REQ_USE="threads(+)" + +inherit bash-completion-r1 flag-o-matic pax-utils python-any-r1 toolchain-funcs xdg-utils + +DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine" +HOMEPAGE="https://nodejs.org/" +SRC_URI=" + https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz +" + +LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT" +SLOT="0/$(ver_cut 1)" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos" +IUSE="cpu_flags_x86_sse2 debug doc icu inspector lto +npm +snapshot +ssl +system-ssl systemtap test" +REQUIRED_USE=" + inspector? ( icu ssl ) + npm? ( ssl ) + system-ssl? ( ssl ) +" + +RDEPEND=" + >=app-arch/brotli-1.0.9 + >=dev-libs/libuv-1.39.0:= + >=net-dns/c-ares-1.16.0 + >=net-libs/http-parser-2.9.3:= + >=net-libs/nghttp2-1.40.0 + sys-libs/zlib + icu? ( >=dev-libs/icu-64.2:= ) + system-ssl? ( >=dev-libs/openssl-1.1.1:0= ) +" +BDEPEND=" + ${PYTHON_DEPS} + sys-apps/coreutils + virtual/pkgconfig + systemtap? ( dev-util/systemtap ) + test? ( net-misc/curl ) +" +DEPEND=" + ${RDEPEND} +" +PATCHES=( + "${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch + "${FILESDIR}"/${PN}-12.20.1-fix_ppc64_crashes.patch + "${FILESDIR}"/${PN}-12.22.1-v8_icu69.patch + "${FILESDIR}"/${PN}-99999999-llhttp.patch +) +RESTRICT="test" +S="${WORKDIR}/node-v${PV}" + +pkg_pretend() { + (use x86 && ! use cpu_flags_x86_sse2) && \ + die "Your CPU doesn't support the required SSE2 instruction." + + if [[ ${MERGE_TYPE} != "binary" ]]; then + if use lto; then + tc-is-gcc || die "${PN} only supports LTO for gcc" + fi + fi +} + +src_prepare() { + tc-export CC CXX PKG_CONFIG + export V=1 + export BUILDTYPE=Release + + # fix compilation on Darwin + # https://code.google.com/p/gyp/issues/detail?id=260 + sed -i -e "/append('-arch/d" tools/gyp/pylib/gyp/xcode_emulation.py || die + + # less verbose install output (stating the same as portage, basically) + sed -i -e "/print/d" tools/install.py || die + + # proper libdir, hat tip @ryanpcmcquen https://github.com/iojs/io.js/issues/504 + local LIBDIR=$(get_libdir) + sed -i -e "s|lib/|${LIBDIR}/|g" tools/install.py || die + sed -i -e "s/'lib'/'${LIBDIR}'/" deps/npm/lib/npm.js || die + + # Avoid writing a depfile, not useful + sed -i -e "/DEPFLAGS =/d" tools/gyp/pylib/gyp/generator/make.py || die + + sed -i -e "/'-O3'/d" common.gypi node.gypi || die + + # Avoid a test that I've only been able to reproduce from emerge. It doesnt + # seem sandbox related either (invoking it from a sandbox works fine). + # The issue is that no stdin handle is openened when asked for one. + # It doesn't really belong upstream , so it'll just be removed until someone + # with more gentoo-knowledge than me (jbergstroem) figures it out. + rm test/parallel/test-stdout-close-unref.js || die + + # debug builds. change install path, remove optimisations and override buildtype + if use debug; then + sed -i -e "s|out/Release/|out/Debug/|g" tools/install.py || die + BUILDTYPE=Debug + fi + + default +} + +src_configure() { + xdg_environment_reset + + # LTO compiler flags are handled by configure.py itself + filter-flags '-flto*' + + local myconf=( + --shared-brotli + --shared-cares + --shared-http-parser + --shared-libuv + --shared-nghttp2 + --shared-zlib + ) + use debug && myconf+=( --debug ) + use lto && myconf+=( --enable-lto ) + use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none ) + use inspector || myconf+=( --without-inspector ) + use npm || myconf+=( --without-npm ) + use snapshot || myconf+=( --without-node-snapshot ) + if use ssl; then + use system-ssl && myconf+=( --shared-openssl --openssl-use-def-ca-store ) + else + myconf+=( --without-ssl ) + fi + + local myarch="" + case ${ABI} in + amd64) myarch="x64";; + arm) myarch="arm";; + arm64) myarch="arm64";; + ppc64) myarch="ppc64";; + x32) myarch="x32";; + x86) myarch="ia32";; + *) myarch="${ABI}";; + esac + + GYP_DEFINES="linux_use_gold_flags=0 + linux_use_bundled_binutils=0 + linux_use_bundled_gold=0" \ + "${EPYTHON}" configure.py \ + --prefix="${EPREFIX}"/usr \ + --dest-cpu=${myarch} \ + $(use_with systemtap dtrace) \ + "${myconf[@]}" || die +} + +src_compile() { + emake -C out mksnapshot + pax-mark m "out/${BUILDTYPE}/mksnapshot" + emake -C out +} + +src_install() { + local LIBDIR="${ED}/usr/$(get_libdir)" + default + + pax-mark -m "${ED}"/usr/bin/node + + # set up a symlink structure that node-gyp expects.. + dodir /usr/include/node/deps/{v8,uv} + dosym . /usr/include/node/src + for var in deps/{uv,v8}/include; do + dosym ../.. /usr/include/node/${var} + done + + if use doc; then + docinto html + dodoc -r "${S}"/doc/* + fi + + if use npm; then + dodir /etc/npm + + # Install bash completion for `npm` + # We need to temporarily replace default config path since + # npm otherwise tries to write outside of the sandbox + local npm_config="usr/$(get_libdir)/node_modules/npm/lib/config/core.js" + sed -i -e "s|'/etc'|'${ED}/etc'|g" "${ED}/${npm_config}" || die + local tmp_npm_completion_file="$(TMPDIR="${T}" mktemp -t npm.XXXXXXXXXX)" + "${ED}/usr/bin/npm" completion > "${tmp_npm_completion_file}" + newbashcomp "${tmp_npm_completion_file}" npm + sed -i -e "s|'${ED}/etc'|'/etc'|g" "${ED}/${npm_config}" || die + + # Move man pages + doman "${LIBDIR}"/node_modules/npm/man/man{1,5,7}/* + + # Clean up + rm -f "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} + rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} + + local find_exp="-or -name" + local find_name=() + for match in "AUTHORS*" "CHANGELOG*" "CONTRIBUT*" "README*" \ + ".travis.yml" ".eslint*" ".wercker.yml" ".npmignore" \ + "*.md" "*.markdown" "*.bat" "*.cmd"; do + find_name+=( ${find_exp} "${match}" ) + done + + # Remove various development and/or inappropriate files and + # useless docs of dependend packages. + find "${LIBDIR}"/node_modules \ + \( -type d -name examples \) -or \( -type f \( \ + -iname "LICEN?E*" \ + "${find_name[@]}" \ + \) \) -exec rm -rf "{}" \; + fi + + mv "${ED}"/usr/share/doc/node "${ED}"/usr/share/doc/${PF} || die +} + +src_test() { + out/${BUILDTYPE}/cctest || die + "${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die +} + +pkg_postinst() { + elog "The global npm config lives in /etc/npm. This deviates slightly" + elog "from upstream which otherwise would have it live in /usr/etc/." + elog "" + elog "Protip: When using node-gyp to install native modules, you can" + elog "avoid having to download extras by doing the following:" + elog "$ node-gyp --nodedir /usr/include/node <command>" +} diff --git a/net-libs/nodejs/nodejs-12.21.0.ebuild b/net-libs/nodejs/nodejs-12.22.1.ebuild index ded3b9963372..3c19482c9e73 100644 --- a/net-libs/nodejs/nodejs-12.21.0.ebuild +++ b/net-libs/nodejs/nodejs-12.22.1.ebuild @@ -37,6 +37,7 @@ RDEPEND=" BDEPEND=" ${PYTHON_DEPS} sys-apps/coreutils + virtual/pkgconfig systemtap? ( dev-util/systemtap ) test? ( net-misc/curl ) " @@ -46,6 +47,7 @@ DEPEND=" PATCHES=( "${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch "${FILESDIR}"/${PN}-12.20.1-fix_ppc64_crashes.patch + "${FILESDIR}"/${PN}-12.22.1-v8_icu69.patch "${FILESDIR}"/${PN}-99999999-llhttp.patch ) RESTRICT="test" diff --git a/net-libs/nodejs/nodejs-14.16.1-r1.ebuild b/net-libs/nodejs/nodejs-14.16.1-r1.ebuild new file mode 100644 index 000000000000..02e8c08318b3 --- /dev/null +++ b/net-libs/nodejs/nodejs-14.16.1-r1.ebuild @@ -0,0 +1,220 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{7..9} ) +PYTHON_REQ_USE="threads(+)" + +inherit bash-completion-r1 flag-o-matic pax-utils python-any-r1 toolchain-funcs xdg-utils + +DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine" +HOMEPAGE="https://nodejs.org/" +SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz" + +LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT" +SLOT="0/$(ver_cut 1)" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos" + +IUSE="cpu_flags_x86_sse2 debug doc +icu inspector lto +npm pax_kernel +snapshot +ssl system-icu +system-ssl systemtap test" +REQUIRED_USE="inspector? ( icu ssl ) + npm? ( ssl ) + system-icu? ( icu ) + system-ssl? ( ssl )" + +# FIXME: test-fs-mkdir fails with "no such file or directory". Investigate. +RESTRICT="test" + +RDEPEND=">=app-arch/brotli-1.0.9 + >=dev-libs/libuv-1.40.0:= + >=net-dns/c-ares-1.16.1 + >=net-libs/nghttp2-1.41.0 + sys-libs/zlib + system-icu? ( >=dev-libs/icu-67:= ) + system-ssl? ( >=dev-libs/openssl-1.1.1:0= )" +BDEPEND="${PYTHON_DEPS} + sys-apps/coreutils + virtual/pkgconfig + systemtap? ( dev-util/systemtap ) + test? ( net-misc/curl ) + pax_kernel? ( sys-apps/elfix )" +DEPEND="${RDEPEND}" + +PATCHES=( + "${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch + "${FILESDIR}"/${PN}-14.15.0-fix_ppc64_crashes.patch + "${FILESDIR}"/${PN}-14.16.1-v8_icu69.patch +) + +S="${WORKDIR}/node-v${PV}" + +pkg_pretend() { + (use x86 && ! use cpu_flags_x86_sse2) && \ + die "Your CPU doesn't support the required SSE2 instruction." + + if [[ ${MERGE_TYPE} != "binary" ]]; then + if use lto; then + tc-is-gcc || die "${PN} only supports LTO for gcc" + fi + fi +} + +src_prepare() { + tc-export AR CC CXX PKG_CONFIG + export V=1 + export BUILDTYPE=Release + + # fix compilation on Darwin + # https://code.google.com/p/gyp/issues/detail?id=260 + sed -i -e "/append('-arch/d" tools/gyp/pylib/gyp/xcode_emulation.py || die + + # less verbose install output (stating the same as portage, basically) + sed -i -e "/print/d" tools/install.py || die + + # proper libdir, hat tip @ryanpcmcquen https://github.com/iojs/io.js/issues/504 + local LIBDIR=$(get_libdir) + sed -i -e "s|lib/|${LIBDIR}/|g" tools/install.py || die + sed -i -e "s/'lib'/'${LIBDIR}'/" deps/npm/lib/npm.js || die + + # Avoid writing a depfile, not useful + sed -i -e "/DEPFLAGS =/d" tools/gyp/pylib/gyp/generator/make.py || die + + sed -i -e "/'-O3'/d" common.gypi node.gypi || die + + # Avoid a test that I've only been able to reproduce from emerge. It doesnt + # seem sandbox related either (invoking it from a sandbox works fine). + # The issue is that no stdin handle is openened when asked for one. + # It doesn't really belong upstream , so it'll just be removed until someone + # with more gentoo-knowledge than me (jbergstroem) figures it out. + rm test/parallel/test-stdout-close-unref.js || die + + # debug builds. change install path, remove optimisations and override buildtype + if use debug; then + sed -i -e "s|out/Release/|out/Debug/|g" tools/install.py || die + BUILDTYPE=Debug + fi + + # We need to disable mprotect on two files when it builds Bug 694100. + use pax_kernel && PATCHES+=( "${FILESDIR}"/${PN}-13.8.0-paxmarking.patch ) + + default +} + +src_configure() { + xdg_environment_reset + + # LTO compiler flags are handled by configure.py itself + filter-flags '-flto*' + + local myconf=( + --shared-brotli + --shared-cares + --shared-libuv + --shared-nghttp2 + --shared-zlib + ) + use debug && myconf+=( --debug ) + use lto && myconf+=( --enable-lto ) + if use system-icu; then + myconf+=( --with-intl=system-icu ) + elif use icu; then + myconf+=( --with-intl=full-icu ) + else + myconf+=( --with-intl=none ) + fi + use inspector || myconf+=( --without-inspector ) + use npm || myconf+=( --without-npm ) + use snapshot || myconf+=( --without-node-snapshot ) + if use ssl; then + use system-ssl && myconf+=( --shared-openssl --openssl-use-def-ca-store ) + else + myconf+=( --without-ssl ) + fi + + local myarch="" + case ${ABI} in + amd64) myarch="x64";; + arm) myarch="arm";; + arm64) myarch="arm64";; + ppc64) myarch="ppc64";; + x32) myarch="x32";; + x86) myarch="ia32";; + *) myarch="${ABI}";; + esac + + GYP_DEFINES="linux_use_gold_flags=0 + linux_use_bundled_binutils=0 + linux_use_bundled_gold=0" \ + "${EPYTHON}" configure.py \ + --prefix="${EPREFIX}"/usr \ + --dest-cpu=${myarch} \ + $(use_with systemtap dtrace) \ + "${myconf[@]}" || die +} + +src_compile() { + emake -C out +} + +src_install() { + local LIBDIR="${ED}/usr/$(get_libdir)" + default + + pax-mark -m "${ED}"/usr/bin/node + + # set up a symlink structure that node-gyp expects.. + dodir /usr/include/node/deps/{v8,uv} + dosym . /usr/include/node/src + for var in deps/{uv,v8}/include; do + dosym ../.. /usr/include/node/${var} + done + + if use doc; then + docinto html + dodoc -r "${S}"/doc/* + fi + + if use npm; then + dodir /etc/npm + + # Install bash completion for `npm` + # We need to temporarily replace default config path since + # npm otherwise tries to write outside of the sandbox + local npm_config="usr/$(get_libdir)/node_modules/npm/lib/config/core.js" + sed -i -e "s|'/etc'|'${ED}/etc'|g" "${ED}/${npm_config}" || die + local tmp_npm_completion_file="$(TMPDIR="${T}" mktemp -t npm.XXXXXXXXXX)" + "${ED}/usr/bin/npm" completion > "${tmp_npm_completion_file}" + newbashcomp "${tmp_npm_completion_file}" npm + sed -i -e "s|'${ED}/etc'|'/etc'|g" "${ED}/${npm_config}" || die + + # Move man pages + doman "${LIBDIR}"/node_modules/npm/man/man{1,5,7}/* + + # Clean up + rm -f "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} + rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} + + local find_exp="-or -name" + local find_name=() + for match in "AUTHORS*" "CHANGELOG*" "CONTRIBUT*" "README*" \ + ".travis.yml" ".eslint*" ".wercker.yml" ".npmignore" \ + "*.md" "*.markdown" "*.bat" "*.cmd"; do + find_name+=( ${find_exp} "${match}" ) + done + + # Remove various development and/or inappropriate files and + # useless docs of dependend packages. + find "${LIBDIR}"/node_modules \ + \( -type d -name examples \) -or \( -type f \( \ + -iname "LICEN?E*" \ + "${find_name[@]}" \ + \) \) -exec rm -rf "{}" \; + fi + + mv "${ED}"/usr/share/doc/node "${ED}"/usr/share/doc/${PF} || die +} + +src_test() { + out/${BUILDTYPE}/cctest || die + "${EPYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die +} diff --git a/net-libs/nodejs/nodejs-14.16.0.ebuild b/net-libs/nodejs/nodejs-14.16.1.ebuild index b80ad78525a0..a8e2612d7c83 100644 --- a/net-libs/nodejs/nodejs-14.16.0.ebuild +++ b/net-libs/nodejs/nodejs-14.16.1.ebuild @@ -34,6 +34,7 @@ RDEPEND=">=app-arch/brotli-1.0.9 system-ssl? ( >=dev-libs/openssl-1.1.1:0= )" BDEPEND="${PYTHON_DEPS} sys-apps/coreutils + virtual/pkgconfig systemtap? ( dev-util/systemtap ) test? ( net-misc/curl ) pax_kernel? ( sys-apps/elfix )" @@ -42,6 +43,7 @@ DEPEND="${RDEPEND}" PATCHES=( "${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch "${FILESDIR}"/${PN}-14.15.0-fix_ppc64_crashes.patch + "${FILESDIR}"/${PN}-14.16.1-v8_icu69.patch ) S="${WORKDIR}/node-v${PV}" diff --git a/net-libs/nodejs/nodejs-15.11.0.ebuild b/net-libs/nodejs/nodejs-16.0.0-r1.ebuild index 4228e1c6eee2..e9e14a673451 100644 --- a/net-libs/nodejs/nodejs-15.11.0.ebuild +++ b/net-libs/nodejs/nodejs-16.0.0-r1.ebuild @@ -16,7 +16,7 @@ LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT" SLOT="0/$(ver_cut 1)" KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos" -IUSE="cpu_flags_x86_sse2 debug doc +icu inspector +npm pax_kernel +snapshot +ssl system-icu +system-ssl systemtap test" +IUSE="cpu_flags_x86_sse2 debug doc +icu inspector lto +npm pax_kernel +snapshot +ssl system-icu +system-ssl systemtap test" REQUIRED_USE="inspector? ( icu ssl ) npm? ( ssl ) system-icu? ( icu ) @@ -34,6 +34,7 @@ RDEPEND=">=app-arch/brotli-1.0.9 system-ssl? ( >=dev-libs/openssl-1.1.1:0= )" BDEPEND="${PYTHON_DEPS} sys-apps/coreutils + virtual/pkgconfig systemtap? ( dev-util/systemtap ) test? ( net-misc/curl ) pax_kernel? ( sys-apps/elfix )" @@ -41,6 +42,7 @@ DEPEND="${RDEPEND}" PATCHES=( "${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch + "${FILESDIR}"/${PN}-16.0.0-v8_lto.patch ) S="${WORKDIR}/node-v${PV}" @@ -48,6 +50,12 @@ S="${WORKDIR}/node-v${PV}" pkg_pretend() { (use x86 && ! use cpu_flags_x86_sse2) && \ die "Your CPU doesn't support the required SSE2 instruction." + + if [[ ${MERGE_TYPE} != "binary" ]]; then + if use lto; then + tc-is-gcc || die "${PN} only supports LTO for gcc" + fi + fi } src_prepare() { @@ -94,6 +102,9 @@ src_prepare() { src_configure() { xdg_environment_reset + # LTO compiler flags are handled by configure.py itself + filter-flags '-flto*' + local myconf=( --shared-brotli --shared-cares @@ -102,6 +113,7 @@ src_configure() { --shared-zlib ) use debug && myconf+=( --debug ) + use lto && myconf+=( --enable-lto ) if use system-icu; then myconf+=( --with-intl=system-icu ) elif use icu; then @@ -173,8 +185,8 @@ src_install() { doman "${LIBDIR}"/node_modules/npm/man/man{1,5,7}/* # Clean up - rm "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die - rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die + rm -f "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} + rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} local find_exp="-or -name" local find_name=() diff --git a/net-libs/nodejs/nodejs-99999999.ebuild b/net-libs/nodejs/nodejs-99999999.ebuild index 0ff4f3923029..110b22734b40 100644 --- a/net-libs/nodejs/nodejs-99999999.ebuild +++ b/net-libs/nodejs/nodejs-99999999.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -33,6 +33,7 @@ RDEPEND=" BDEPEND=" ${PYTHON_DEPS} sys-apps/coreutils + virtual/pkgconfig systemtap? ( dev-util/systemtap ) test? ( net-misc/curl ) pax_kernel? ( sys-apps/elfix ) |