public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2016-10-25  6:29 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2016-10-25  6:29 UTC (permalink / raw
  To: gentoo-commits

commit:     230a3c24fda0668418a596eedf9201495aa2492b
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Tue Oct 25 06:28:59 2016 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Tue Oct 25 06:28:59 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=230a3c24

net-libs/nodejs: Old.

Package-Manager: portage-2.3.2

 net-libs/nodejs/Manifest                  |  12 --
 net-libs/nodejs/files/nodejs-v8-3.5.patch |  11 --
 net-libs/nodejs/nodejs-0.12.7.ebuild      | 123 -------------------
 net-libs/nodejs/nodejs-4.4.0.ebuild       | 143 ----------------------
 net-libs/nodejs/nodejs-4.4.1.ebuild       | 143 ----------------------
 net-libs/nodejs/nodejs-4.4.7.ebuild       | 144 ----------------------
 net-libs/nodejs/nodejs-4.5.0.ebuild       | 144 ----------------------
 net-libs/nodejs/nodejs-5.10.1.ebuild      | 195 ------------------------------
 net-libs/nodejs/nodejs-5.11.0.ebuild      | 195 ------------------------------
 net-libs/nodejs/nodejs-5.9.1.ebuild       | 195 ------------------------------
 net-libs/nodejs/nodejs-6.5.0.ebuild       | 193 -----------------------------
 net-libs/nodejs/nodejs-6.6.0.ebuild       | 193 -----------------------------
 net-libs/nodejs/nodejs-6.7.0.ebuild       | 193 -----------------------------
 net-libs/nodejs/nodejs-6.8.1.ebuild       | 193 -----------------------------
 14 files changed, 2077 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index bca0c63..280c25f 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,19 +1,7 @@
 DIST node-v0.12.10.tar.gz 19572955 SHA256 edbd3710512ec7518a3de4cabf9bfee6d12f278eef2e4b53422c7b063f6b976d SHA512 d217f52dfedb5355df89b9c726f6bc68e53a713e6e005a66beefdbd20666b55770bab2eca6f39275aa1a64aca922a2a78808900ebaa4005eb21042a915413a7b WHIRLPOOL 4fe3e370cc645672590483e4b388a37a82fb04dfbbcf16a7a9cc2c1a47600e650ae5712133b205c3067180305a61e76fde9a7b78ad53d25f8f07b97e86271751
 DIST node-v0.12.6.tar.gz 19750717 SHA256 7a3b5ac351973a9dee8edbf0684bc8d0dea44b231e42274ffb008141ffa19ad2 SHA512 a7f1c88d8df0f65d986e283b859466a34459f8ebdd3232f4906f5ebd53c1a019a553eadcc50bcb5fe8252441c567692b9ada36e8b158ed818971cd927bf1b29f WHIRLPOOL 3677bee6016647282e877f4676fc3731ca49d9b5ccda6d99f8fc3f16e56fcf30072adb494539b9714d0b3afb657457a16fecab682ab62fd501e789f008255380
-DIST node-v0.12.7.tar.gz 20063992 SHA256 b23d64df051c9c969b0c583f802d5d71de342e53067127a5061415be7e12f39d SHA512 0c9cb7542530463e7703435c8d819949785c1c6497c6d98f9854ca615fe33a62f451833e856f0159b836a698b4dee5d165fa505bad5d474f664e1533090d8606 WHIRLPOOL 647391b8c49fda868c14bd4eb3089cac139f50e710ac6b141ea82e1013c4ff7d40cdb0e88d69604d06e3bd07775876c754211a2b099685cb7353ae5708812525
-DIST node-v4.4.0.tar.xz 13107524 SHA256 6ae44ae9a9cd1f102ca7f3ea09ca6223afe88fab4911f1bf21c9da2a1e795f1d SHA512 4bb1f660c5a80fffb3399c4465c311bd13c2f78e65fc9aaa7df96d3c2db5d3b3de3b4be9f50040065fa1889ad247a2949a84a6d9044301a636ebb8baf73edd4d WHIRLPOOL 50b126fc3a7b8b6be693334375b4704217b4e6f00e7e32404a17ebad512e3cc72434f00863a1e69bb85e01859054faac7bb5c2d25889b8ef131191a388528e0c
-DIST node-v4.4.1.tar.xz 13112424 SHA256 3a37c89a3ac965688f9e6557579993b73eee44195a5fd53fded03a667d3d6a0a SHA512 53b479085a6f43b5932c75729b21a3efa67534ce6c10445c2ba66492a0e3f12d8e5de8d75bd583239b68f3d5ac1b639d45fd43d631d8a5ef013e25bff0fdab22 WHIRLPOOL d9cee2193a0f94f17ab84722ffb9999f156014cbe0b83bd138d5404ec543a3398bb4d1b965940b19230cf069337dfb5e0159aae3e694137e09261133ae2e2fdd
 DIST node-v4.4.6.tar.xz 13211732 SHA256 0f6bbfbea525469c91932b1aac35e0810e6bcda96f1c720e42a433942ee66106 SHA512 b06219ab63de89eeb1268d677769cb17c8290555962b1cbfaafbede3d2dbefaafb455f32a611160fcfbf7400059fa79ec3f9c2f3287c8746669c05b42d7aaa7c WHIRLPOOL ffb1372193a72a2e1ae6e21c281a28e770443e36e5e349b48bf30e92b3f6f9d9ba901794eaf1f7c8eaf05c7365e1249bb210760fa26680ed13d1a6d8854c8ce8
-DIST node-v4.4.7.tar.xz 13231156 SHA256 1ef900b9cb3ffb617c433a3247a9d67ff36c9455cbc9c34175bee24bdbfdf731 SHA512 0b4df07057ad8661fec7a2194d608e37d9c4d50b3e023bcc8c3b40308af6925098c280ca4b0c96454ea4f03f556d6b92133a6e5d3d61036afc5dd89e18c95c9e WHIRLPOOL 3559240a51f77c64db5edd8d3436085f8a4164a25e442df90bdd4c4a81f06a863fe94c4bf26e7ad5b0c1bf6e1102b769fc18fa89ea76c548d84e4cfc9ee43d87
-DIST node-v4.5.0.tar.xz 13271372 SHA256 97b99d378c56802444208409568e2e66c46332897f06aead74d1ffbe733bd488 SHA512 3f4f826c5a6b7717b4fa000475a7f32d47f92ea6a7d83752139713dae5544ec6d4db39f3200b4162bbe262d85d8f697938d83fb96b83acc572d30cd7fc2c7127 WHIRLPOOL 7321132e887f21f83ed87455c2783d947acaa65e66915bd41b25451b49ebc584161695c96e990a54e0439a34089519a0d4ca03f1463c5b29f44fae0ee07dd46f
 DIST node-v4.6.0.tar.xz 13295184 SHA256 42910dbd34e49bfc40580e06753947c30d31101455a38e9f0343a23d67c0c694 SHA512 d3e79f7e361af888955f311818c0d0401a29fd99a86fa125924b3f7891f209f84f4f662dba071c9bdbb3d11a3b3097274d95bdc4a51143a2e816400ff71b041f WHIRLPOOL 011d1de801b87be413b7838e0b0ea216909bbe4a2d88a5045536d65d3b85cca64f9e94923859a65d8b6ed1fcbbf34a9463c7a8fc036ba1f0b902f8b4a07b83ac
 DIST node-v4.6.1.tar.xz 13295568 SHA256 fe2a85df8758001878abb5bbaf17a6b6cdc12b3e465b1d3bace83b37fdf0345a SHA512 4eb2acbe13ee2373922420e3238be63d2108dacba640438bddbdea12ec2de9c655f33db611e4c0654b66bf4fdb844a7b6554a823aac73171b17599096856abdb WHIRLPOOL a6d21cce7ab8c430528682f78a6e6492f753c87949b7b1bdc15dc02911559cd89deb45329c2ba32da57b776dd4feaabec8a3e7a59a78094cfb079261b6475c76
-DIST node-v5.10.1.tar.xz 13317868 SHA256 9eecd853cdd06ebee24a1bb8d753cd20af5a19297c5d3a3b1680fe36b47d5cbe SHA512 e0dcd5fd6d23c4905a4fbf483621cb2a878516a5bfeefad68901edd1be2dba76281cd22fff073f5f8e2432dbac3c68728c597e1aab753ce3b3dfe9e0674ef808 WHIRLPOOL 2aecbb9a538320c09d6306a756ed6cde2537fd4d9e5ef9b6713956062178ba8070d060e1ae2fab264d834fbb1e5452eaf744b4c0a9cd70ffa181e6c479b4086a
-DIST node-v5.11.0.tar.xz 13298460 SHA256 083766aff72fc5c78f6999dd0d00bc0340a052ab270fd60d6928b719ca2b3fd1 SHA512 47f2b25007877dc7597af9dd841e4f30197a9df6dcf01f45336c2eaec8d5c75057534b962df361e9bdaf461dab8cb97a878d326d74105a38a7797b77ed67df44 WHIRLPOOL 0b670baa82e3dbd0a2492476f3ebca8006d7c1c4efef47e85954624ad776517a3f0403d8556e438c16c8373818bed444bc66a72500c3a55025d50cdb694ec411
-DIST node-v5.9.1.tar.xz 13226192 SHA256 668067077dfceb3d2039d0df693fec6aa20b920d01a42b53dc61d4aa91e0ae55 SHA512 34774d88eda775bdf153a76bd02b26c499e4a9ef47d8e94ad7b66d360d04891b45ce8f211833ca69e8c0a786ca36424b0c620a90b1fbc6d5afc77d20f4b5fadb WHIRLPOOL d666aa6fd4d577f7a6f89c3bfa75e62a0281e0dd7592373f384bfe01fa2dcbf81156bf6a21fc2097d48d5024a39057713c2593f4609c70ff8f84090471b073a9
-DIST node-v6.5.0.tar.xz 15555848 SHA256 ddf2056a9164c723db707b6c016f9e617f17166298dc88c5a7cb1d7d5ddb1290 SHA512 1a0ba9de2b6f270d124275cb1d098fd4c667a6c408a48fac3d92bfc3d957e3de5c1fea8172c96dd94a3b7826ef1d93859152cc835a07cf07d7b09858f874b2da WHIRLPOOL 3ffdbbcbbe94a0bf8f7bbe86a9832cc97f9796a35e7638daf07acd9822ef9b0afb4946e24664e15007b8c31948c3a686f2208a96d72acf3337a7fa7e1a443b44
-DIST node-v6.6.0.tar.xz 15580876 SHA256 640485d2b672d3313203eae164576539e61f1e55d68122ff2c7fb59896e21a33 SHA512 3b382f98d9c92dbb1fa9c93969b14aa0be8d7b7eabbecf8be30ff92e9a5519cbaa5f5349b2dc88e919281638d6b7f109ff0f2fa03f84c7765c0fae496d51b1f2 WHIRLPOOL 395a4cfe26877cf6f1271d677d1538ddb78024030f5d8404426e7ef2acc4eb88e0914d8f27760cac4508dccbedfb1cfe8692eeaa2e091e2dc6b961a25053b273
-DIST node-v6.7.0.tar.xz 15609148 SHA256 ceb028324aab1ee8c7ea6a62026f036f3ea71f5ef5212593d0f833f999dd3be5 SHA512 acf86362e33d10c5c59349a086fa2e07368e8bbb58b00c3d0df2c571e8ba637c5bee8f08d344d8693a24fcd75884448f9f3d389f2af48de6a86fc6b064c3e1ba WHIRLPOOL 3c3adf10ad6abd5aa71b5773def1661b2acd873c63ebcbe79c8f409ed83fc309a1cde4a45d241687485e709a5996062a046439bad8f2644616c5c839522baf4b
-DIST node-v6.8.1.tar.xz 15619508 SHA256 a44ff48de369381c506661996dec568085d42998613ed2a23ebb37fddc12c99a SHA512 9da04e126c3ed98f8fd7f310a08349804db9d8fa65f6a305df013e7f82a7afcad627da224ee73bd6142d4ae266ed9aa6ba04839f2cf7e051413b958c9296603e WHIRLPOOL 9d0144a7c908ad5db40a772a19a89e9ef7f7abf7201c79238bb97a8f6f2f7d80b16d89e10796f60cf407388e3ee753b5c308b8d9401eb10185dd3c61c0c25850
 DIST node-v6.9.0.tar.xz 15615224 SHA256 656342ed8a84c95a36af902f309aeeca7103b16d61c02925bd37bd47d2194915 SHA512 c8dc6899e8ec9d97d37b72a0ff6483069c494b05020ff6cf101c2b8b2774ed2673138fc260dc90b7317123d77daf89d0ba3321deda47457fa892456054f93337 WHIRLPOOL e65031667b619e0449924272359db01fd846dc68238e45a2bc4890d6f539b32dc173bab282c858412f2d34b73cdf68371a5677d081f9b56fb19791a9354ad740
 DIST node-v6.9.1.tar.xz 15617228 SHA256 0bdd8d1305777cc8cd206129ea494d6c6ce56001868dd80147aff531d6df0729 SHA512 3f1c724dfc9f76f101064be6ef222482f3b7e53d8d6c026b3d166dfbdd104f05055cf04a3205679793fa12f946548fc06e3272527655b28002d0bf0e7eccdf1b WHIRLPOOL dd1607b4c193f7ef05f7d0571f31c72133464e2ebd023278cf055d7156daa6e194e5170948f32cae8027f1ef5c6eaef6a89bf7271ed386d45c787b30e57880fb

diff --git a/net-libs/nodejs/files/nodejs-v8-3.5.patch b/net-libs/nodejs/files/nodejs-v8-3.5.patch
deleted file mode 100644
index 87a8eed..00000000
--- a/net-libs/nodejs/files/nodejs-v8-3.5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- src/node_buffer.cc	2011-10-25 08:45:00.665600749 +0200
-+++ src/node_buffer.cc	2011-10-25 08:45:31.168622565 +0200
-@@ -478,7 +478,7 @@
- 
-   if (written > 0 && p[written-1] == '\0' && char_written == length) {
-     uint16_t last_char;
--    s->Write(&last_char, length - 1, 1, String::NO_HINTS);
-+    s->Write(&last_char, length - 1, 1, String::NO_OPTIONS);
-     if (last_char != 0 || written > s->Utf8Length()) {
-       written--;
-     }

diff --git a/net-libs/nodejs/nodejs-0.12.7.ebuild b/net-libs/nodejs/nodejs-0.12.7.ebuild
deleted file mode 100644
index e0e1b3e..00000000
--- a/net-libs/nodejs/nodejs-0.12.7.ebuild
+++ /dev/null
@@ -1,123 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-# has known failures. sigh.
-RESTRICT="test"
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit pax-utils python-single-r1 toolchain-funcs
-
-DESCRIPTION="Evented IO for V8 Javascript"
-HOMEPAGE="http://nodejs.org/"
-SRC_URI="http://nodejs.org/dist/v${PV}/node-v${PV}.tar.gz"
-
-LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
-SLOT="0"
-KEYWORDS="~amd64 ~arm ~x86 ~x64-macos"
-IUSE="debug icu +npm +snapshot +ssl"
-
-RDEPEND="icu? ( dev-libs/icu )
-	${PYTHON_DEPS}
-	ssl? ( dev-libs/openssl:0=[-bindist] )
-	>=net-libs/http-parser-2.3
-	>=dev-libs/libuv-1.4.2"
-DEPEND="${RDEPEND}"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-src_prepare() {
-	tc-export CC CXX PKG_CONFIG
-	export V=1 # Verbose build
-	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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || die
-	sed -i -e "s|\"lib\"|\"${LIBDIR}\"|" deps/npm/lib/npm.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
-}
-
-src_configure() {
-	local myconf=()
-	local myarch=""
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu )
-	use npm || myconf+=( --without-npm )
-	use snapshot || myconf+=( --without-snapshot )
-	use ssl || myconf+=( --without-ssl )
-
-	case ${ABI} in
-		x86) myarch="ia32";;
-		amd64) myarch="x64";;
-		arm) myarch="arm";;
-		*) die "Unrecognized ARCH ${ARCH}";;
-	esac
-
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--shared-openssl \
-		--shared-libuv \
-		--shared-http-parser \
-		--shared-zlib \
-		--without-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)"
-	emake install DESTDIR="${ED}" PREFIX=/usr
-	use npm && dodoc -r "${LIBDIR}"/node_modules/npm/html
-	rm -rf "${LIBDIR}"/node_modules/npm/{doc,html} || die
-	find "${LIBDIR}"/node_modules -type f -name "LICENSE*" -or -name "LICENCE*" -delete
-
-	# set up a symlink structure that npm 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
-
-	pax-mark -m "${ED}"/usr/bin/node
-}
-
-src_test() {
-	declare -xl TESTTYPE="${BUILDTYPE}"
-	"${PYTHON}" tools/test.py --mode=${TESTTYPE} -J message simple || die
-}
-
-pkg_postinst() {
-	einfo "When using node-gyp to install native modules, you can avoid"
-	einfo "having to download the full tarball by doing the following:"
-	einfo ""
-	einfo "node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-4.4.0.ebuild b/net-libs/nodejs/nodejs-4.4.0.ebuild
deleted file mode 100644
index 5512f91..00000000
--- a/net-libs/nodejs/nodejs-4.4.0.ebuild
+++ /dev/null
@@ -1,143 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~x86 ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug icu +npm snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-55:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.5.2:=
-	>=dev-libs/libuv-1.8.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-src_prepare() {
-	tc-export CC CXX PKG_CONFIG
-	export V=1 # Verbose build
-	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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || die
-	sed -i -e "s|\"lib\"|\"${LIBDIR}\"|" deps/npm/lib/npm.js || 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
-
-	epatch_user
-}
-
-src_configure() {
-	local myarch=""
-	local myconf+=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	case ${ABI} in
-		x86) myarch="ia32";;
-		amd64) myarch="x64";;
-		x32) myarch="x32";;
-		arm) myarch="arm";;
-		arm64) myarch="arm64";;
-		*) die "Unrecognized ARCH ${ARCH}";;
-	esac
-
-	GYP_DEFINES="linux_use_gold_flags=0
-		linux_use_bundled_binutils=0
-		linux_use_bundled_gold=0" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${ED}" PREFIX=/usr
-	if use npm; then
-		dodoc -r "${LIBDIR}"/node_modules/npm/html
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html} || die
-		find "${LIBDIR}"/node_modules -type f -name "LICENSE*" -or -name "LICENCE*" -delete || die
-	fi
-
-	# set up a symlink structure that npm 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
-
-	pax-mark -m "${ED}"/usr/bin/node
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "When using node-gyp to install native modules, you can avoid"
-	einfo "having to download the full tarball by doing the following:"
-	einfo ""
-	einfo "node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-4.4.1.ebuild b/net-libs/nodejs/nodejs-4.4.1.ebuild
deleted file mode 100644
index 5b627ae..00000000
--- a/net-libs/nodejs/nodejs-4.4.1.ebuild
+++ /dev/null
@@ -1,143 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="amd64 ~arm ~arm64 x86 ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug icu +npm snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-55:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.5.2:=
-	>=dev-libs/libuv-1.8.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-src_prepare() {
-	tc-export CC CXX PKG_CONFIG
-	export V=1 # Verbose build
-	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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || die
-	sed -i -e "s|\"lib\"|\"${LIBDIR}\"|" deps/npm/lib/npm.js || 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
-
-	epatch_user
-}
-
-src_configure() {
-	local myarch=""
-	local myconf+=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	case ${ABI} in
-		x86) myarch="ia32";;
-		amd64) myarch="x64";;
-		x32) myarch="x32";;
-		arm) myarch="arm";;
-		arm64) myarch="arm64";;
-		*) die "Unrecognized ARCH ${ARCH}";;
-	esac
-
-	GYP_DEFINES="linux_use_gold_flags=0
-		linux_use_bundled_binutils=0
-		linux_use_bundled_gold=0" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${ED}" PREFIX=/usr
-	if use npm; then
-		dodoc -r "${LIBDIR}"/node_modules/npm/html
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html} || die
-		find "${LIBDIR}"/node_modules -type f -name "LICENSE*" -or -name "LICENCE*" -delete || die
-	fi
-
-	# set up a symlink structure that npm 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
-
-	pax-mark -m "${ED}"/usr/bin/node
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "When using node-gyp to install native modules, you can avoid"
-	einfo "having to download the full tarball by doing the following:"
-	einfo ""
-	einfo "node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-4.4.7.ebuild b/net-libs/nodejs/nodejs-4.4.7.ebuild
deleted file mode 100644
index 4da7b46..00000000
--- a/net-libs/nodejs/nodejs-4.4.7.ebuild
+++ /dev/null
@@ -1,144 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug icu +npm snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-55:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.5.2:=
-	>=dev-libs/libuv-1.8.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-src_prepare() {
-	tc-export CC CXX PKG_CONFIG
-	export V=1 # Verbose build
-	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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || die
-	sed -i -e "s|\"lib\"|\"${LIBDIR}\"|" deps/npm/lib/npm.js || 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
-
-	epatch_user
-}
-
-src_configure() {
-	local myarch=""
-	local myconf+=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	case ${ABI} in
-		amd64) myarch="x64";;
-		arm) myarch="arm";;
-		arm64) myarch="arm64";;
-		ppc64) myarch="ppc64";;
-		x32) myarch="x32";;
-		x86) myarch="ia32";;
-		*) die "Unrecognized ARCH ${ARCH}";;
-	esac
-
-	GYP_DEFINES="linux_use_gold_flags=0
-		linux_use_bundled_binutils=0
-		linux_use_bundled_gold=0" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${ED}" PREFIX=/usr
-	if use npm; then
-		dodoc -r "${LIBDIR}"/node_modules/npm/html
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html} || die
-		find "${LIBDIR}"/node_modules -type f -name "LICENSE*" -or -name "LICENCE*" -delete || die
-	fi
-
-	# set up a symlink structure that npm 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
-
-	pax-mark -m "${ED}"/usr/bin/node
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "When using node-gyp to install native modules, you can avoid"
-	einfo "having to download the full tarball by doing the following:"
-	einfo ""
-	einfo "node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-4.5.0.ebuild b/net-libs/nodejs/nodejs-4.5.0.ebuild
deleted file mode 100644
index 4da7b46..00000000
--- a/net-libs/nodejs/nodejs-4.5.0.ebuild
+++ /dev/null
@@ -1,144 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug icu +npm snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-55:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.5.2:=
-	>=dev-libs/libuv-1.8.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-src_prepare() {
-	tc-export CC CXX PKG_CONFIG
-	export V=1 # Verbose build
-	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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || die
-	sed -i -e "s|\"lib\"|\"${LIBDIR}\"|" deps/npm/lib/npm.js || 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
-
-	epatch_user
-}
-
-src_configure() {
-	local myarch=""
-	local myconf+=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	case ${ABI} in
-		amd64) myarch="x64";;
-		arm) myarch="arm";;
-		arm64) myarch="arm64";;
-		ppc64) myarch="ppc64";;
-		x32) myarch="x32";;
-		x86) myarch="ia32";;
-		*) die "Unrecognized ARCH ${ARCH}";;
-	esac
-
-	GYP_DEFINES="linux_use_gold_flags=0
-		linux_use_bundled_binutils=0
-		linux_use_bundled_gold=0" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${ED}" PREFIX=/usr
-	if use npm; then
-		dodoc -r "${LIBDIR}"/node_modules/npm/html
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html} || die
-		find "${LIBDIR}"/node_modules -type f -name "LICENSE*" -or -name "LICENCE*" -delete || die
-	fi
-
-	# set up a symlink structure that npm 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
-
-	pax-mark -m "${ED}"/usr/bin/node
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "When using node-gyp to install native modules, you can avoid"
-	einfo "having to download the full tarball by doing the following:"
-	einfo ""
-	einfo "node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-5.10.1.ebuild b/net-libs/nodejs/nodejs-5.10.1.ebuild
deleted file mode 100644
index 5aba2f6..00000000
--- a/net-libs/nodejs/nodejs-5.10.1.ebuild
+++ /dev/null
@@ -1,195 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc +icu +npm +snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-56:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.6.2:=
-	>=dev-libs/libuv-1.8.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-dtrace \
-		"${myconf[@]}" || die
-}
-
-src_compile() {
-	emake -C out mksnapshot
-	pax-mark m "out/${BUILDTYPE}/mksnapshot"
-	emake -C out
-
-	use doc && emake doc
-}
-
-src_install() {
-	local LIBDIR="${ED}/usr/$(get_libdir)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -r "${S}"/out/doc/api/*
-	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'|'${D}/etc'|g" "${ED}/${npm_config}" || die
-		local tmp_npm_completion_file="$(emktemp)"
-		"${ED}/usr/bin/npm" completion > "${tmp_npm_completion_file}"
-		newbashcomp "${tmp_npm_completion_file}" npm
-		sed -i -e "s|'${D}/etc'|'/etc'|g" "${ED}/${npm_config}" || die
-
-		# Move man pages
-		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
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-5.11.0.ebuild b/net-libs/nodejs/nodejs-5.11.0.ebuild
deleted file mode 100644
index 85d5f98..00000000
--- a/net-libs/nodejs/nodejs-5.11.0.ebuild
+++ /dev/null
@@ -1,195 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc +icu +npm +snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-56:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.6.2:=
-	>=dev-libs/libuv-1.8.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-dtrace \
-		"${myconf[@]}" || die
-}
-
-src_compile() {
-	emake -C out mksnapshot
-	pax-mark m "out/${BUILDTYPE}/mksnapshot"
-	emake -C out
-
-	use doc && emake doc
-}
-
-src_install() {
-	local LIBDIR="${ED}/usr/$(get_libdir)"
-	emake install DESTDIR="${ED}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -r "${S}"/out/doc/api/*
-	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'|'${D}/etc'|g" "${ED}/${npm_config}" || die
-		local tmp_npm_completion_file="$(emktemp)"
-		"${ED}/usr/bin/npm" completion > "${tmp_npm_completion_file}"
-		newbashcomp "${tmp_npm_completion_file}" npm
-		sed -i -e "s|'${D}/etc'|'/etc'|g" "${ED}/${npm_config}" || die
-
-		# Move man pages
-		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
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-5.9.1.ebuild b/net-libs/nodejs/nodejs-5.9.1.ebuild
deleted file mode 100644
index 8c77a3c..00000000
--- a/net-libs/nodejs/nodejs-5.9.1.ebuild
+++ /dev/null
@@ -1,195 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu +npm +snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-56:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.6.2:=
-	>=dev-libs/libuv-1.8.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-dtrace \
-		"${myconf[@]}" || die
-}
-
-src_compile() {
-	emake -C out mksnapshot
-	pax-mark m "out/${BUILDTYPE}/mksnapshot"
-	emake -C out
-
-	use doc && emake doc
-}
-
-src_install() {
-	local LIBDIR="${ED}/usr/$(get_libdir)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -r "${S}"/out/doc/api/*
-	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'|'${D}/etc'|g" "${ED}/${npm_config}" || die
-		local tmp_npm_completion_file="$(emktemp)"
-		"${ED}/usr/bin/npm" completion > "${tmp_npm_completion_file}"
-		newbashcomp "${tmp_npm_completion_file}" npm
-		sed -i -e "s|'${D}/etc'|'/etc'|g" "${ED}/${npm_config}" || die
-
-		# Move man pages
-		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
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-6.5.0.ebuild b/net-libs/nodejs/nodejs-6.5.0.ebuild
deleted file mode 100644
index 4e76890..00000000
--- a/net-libs/nodejs/nodejs-6.5.0.ebuild
+++ /dev/null
@@ -1,193 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu +npm +snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-56:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.6.2:=
-	>=dev-libs/libuv-1.9.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-6.6.0.ebuild b/net-libs/nodejs/nodejs-6.6.0.ebuild
deleted file mode 100644
index 4e76890..00000000
--- a/net-libs/nodejs/nodejs-6.6.0.ebuild
+++ /dev/null
@@ -1,193 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu +npm +snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-56:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.6.2:=
-	>=dev-libs/libuv-1.9.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-6.7.0.ebuild b/net-libs/nodejs/nodejs-6.7.0.ebuild
deleted file mode 100644
index 4e76890..00000000
--- a/net-libs/nodejs/nodejs-6.7.0.ebuild
+++ /dev/null
@@ -1,193 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu +npm +snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-56:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.6.2:=
-	>=dev-libs/libuv-1.9.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-6.8.1.ebuild b/net-libs/nodejs/nodejs-6.8.1.ebuild
deleted file mode 100644
index 4e76890..00000000
--- a/net-libs/nodejs/nodejs-6.8.1.ebuild
+++ /dev/null
@@ -1,193 +0,0 @@
-# Copyright 1999-2016 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu +npm +snapshot +ssl test"
-
-RDEPEND="icu? ( >=dev-libs/icu-56:= )
-	npm? ( ${PYTHON_DEPS} )
-	>=net-libs/http-parser-2.6.2:=
-	>=dev-libs/libuv-1.9.0:=
-	>=dev-libs/openssl-1.0.2g:0=[-bindist]
-	sys-libs/zlib"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
-	use npm || myconf+=( --without-npm )
-	use icu && myconf+=( --with-intl=system-icu )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl || myconf+=( --without-ssl )
-	use debug && myconf+=( --debug )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2017-08-18 14:17 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2017-08-18 14:17 UTC (permalink / raw
  To: gentoo-commits

commit:     f23d77314a0490304f83bba4d8076b768426ccab
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Fri Aug 18 14:16:41 2017 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Fri Aug 18 14:17:02 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f23d7731

net-libs/nodejs: Version bump.

Package-Manager: Portage-2.3.8, Repoman-2.3.3

 net-libs/nodejs/Manifest                           |   1 +
 .../nodejs/files/nodejs-8.4.0-shared-nghttp2.patch | 105 +++++++++++
 net-libs/nodejs/nodejs-8.4.0.ebuild                | 196 +++++++++++++++++++++
 3 files changed, 302 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 9911e42715c..c1f487949bc 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -17,3 +17,4 @@ DIST node-v8.1.0.tar.xz 17723984 SHA256 f2ff20b69b782dee85e887ad06e830590b225085
 DIST node-v8.1.2.tar.xz 17730764 SHA256 ac190c1964ee0c28d4c163c0ccbb47435b2e4bd9b4c065b74a93373105c574b3 SHA512 c071040c33c69768d021613c3213bb227a8afe0868232e3a6094f28e86c118c4e2a74acefa1870e3d54c09c7b0ba6d0bda13ae16e954cdb0dc098aa638037788 WHIRLPOOL deac3b78e0219369d026df189206da1e0596a215ab670ac96192fa41d9622aa79fc3a79ee56af12fc57aa362c528c8b5b73a9e20dc69dd94682abd3c352a167c
 DIST node-v8.1.4.tar.xz 17737792 SHA256 a83c86445f79749c46fd4f2c4e681a3e5bb51b2bde5dc7aed1dc38e4e242c301 SHA512 b9b8d0842313f456e156ca88ec0d7f0082130368597d2d8d7a547658342d7e1692be928c17d2a77a09ee0ac2b443038b135cd99055ffee29ff61d957dea4ee14 WHIRLPOOL 4955ea1778f95a3232c0eaf45407eaa04ae91de2180341d4b87e711e484d2abbfc9875577be7df4d59fb3c8dc34579c779fbe47153a248be202cd0265f581585
 DIST node-v8.2.1.tar.xz 17897168 SHA256 02c46d8914540eea73d0ad33bf9f371a28aa0dc8c5d740948491fef044ad8c8b SHA512 8d84998e8408b89e003929d7fce89c31703aea59ca5826246422d4d1935941730b0b9907a8a9af088ec8ccad60d8919da04104037083a2363daf118682a3b82a WHIRLPOOL dbbf430699f88b1c86b1a818b9c2fe424d3c63eb36c2b85b54de78954d8f01dc47a2f66a6cecf30c43e8ab29236f0a7509a26afc4586501abcda4494a78a21c7
+DIST node-v8.4.0.tar.xz 18265792 SHA256 5d5aa2a101dcc617231a475812eb8ed87cac21491f1dcc7997b9dd463563f361 SHA512 7d0d97ca64db0bf87f1892490f8b7758a879d2ac22532b69e8e0ee5c04bd11073fd917353eeeabdcfbebc83540715d8c520ec9bf9ea1afc82d8ee7b6caf819f1 WHIRLPOOL 23f50be06615350564577349f6388d6563cbcae9e9b0229133baaab30852be7c759fbb4f265816ab999fa2bfa8666b47fb3ba438e09beff8e030fa2db547001c

diff --git a/net-libs/nodejs/files/nodejs-8.4.0-shared-nghttp2.patch b/net-libs/nodejs/files/nodejs-8.4.0-shared-nghttp2.patch
new file mode 100644
index 00000000000..1f1a2e6ea63
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-8.4.0-shared-nghttp2.patch
@@ -0,0 +1,105 @@
+--- a/configure
++++ b/configure
+@@ -182,6 +182,27 @@
+     dest='shared_http_parser_libpath',
+     help='a directory to search for the shared http_parser DLL')
+ 
++shared_optgroup.add_option('--shared-nghttp2',
++    action='store_true',
++    dest='shared_nghttp2',
++    help='link to a shared nghttp2 DLL instead of static linking')
++
++shared_optgroup.add_option('--shared-nghttp2-includes',
++    action='store',
++    dest='shared_nghttp2_includes',
++    help='directory containing nghttp2 header files')
++
++shared_optgroup.add_option('--shared-nghttp2-libname',
++    action='store',
++    dest='shared_nghttp2_libname',
++    default='nghttp2',
++    help='alternative lib name to link to [default: %default]')
++
++shared_optgroup.add_option('--shared-nghttp2-libpath',
++    action='store',
++    dest='shared_nghttp2_libpath',
++    help='a directory to search for the shared nghttp2 DLL')
++
+ shared_optgroup.add_option('--shared-libuv',
+     action='store_true',
+     dest='shared_libuv',
+@@ -1381,6 +1381,7 @@
+ configure_node(output)
+ configure_library('zlib', output)
+ configure_library('http_parser', output)
++configure_library('nghttp2', output)
+ configure_library('libuv', output)
+ configure_library('libcares', output)
+ # stay backwards compatible with shared cares builds
+--- a/node.gyp
++++ b/node.gyp
+@@ -14,6 +14,7 @@
+     'node_module_version%': '',
+     'node_shared_zlib%': 'false',
+     'node_shared_http_parser%': 'false',
++    'node_shared_nghttp2%': 'false',
+     'node_shared_cares%': 'false',
+     'node_shared_libuv%': 'false',
+     'node_use_openssl%': 'true',
+@@ -149,10 +150,17 @@
+       'type': '<(node_target_type)',
+
+       'dependencies': [
+-        'node_js2c#host',
+-        'deps/nghttp2/nghttp2.gyp:nghttp2'
++        'node_js2c#host'
+       ],
+
++      'conditions': [
++        [ 'node_shared_nghttp2=="false"', {
++          'dependencies': [
++            'deps/nghttp2/nghttp2.gyp:nghttp2'
++          ]
++        }]
++      ],
++
+       'includes': [
+         'node.gypi'
+       ],
+@@ -161,8 +161,7 @@
+         'src',
+         'tools/msvs/genfiles',
+         'deps/uv/src/ares',
+-        '<(SHARED_INTERMEDIATE_DIR)', # for node_natives.h
+-        'deps/nghttp2/lib/includes'
++        '<(SHARED_INTERMEDIATE_DIR)' # for node_natives.h
+       ],
+ 
+       'sources': [
+@@ -275,9 +274,7 @@
+         'NODE_PLATFORM="<(OS)"',
+         'NODE_WANT_INTERNALS=1',
+         # Warn when using deprecated V8 APIs.
+-        'V8_DEPRECATION_WARNINGS=1',
+-        # We're using the nghttp2 static lib
+-        'NGHTTP2_STATICLIB'
++        'V8_DEPRECATION_WARNINGS=1'
+       ],
+     },
+     {
+@@ -687,6 +684,15 @@
+                 'deps/http_parser/http_parser.gyp:http_parser'
+               ]
+             }],
++            [ 'node_shared_nghttp2=="false"', {
++              'dependencies': [
++                'deps/nghttp2/nghttp2.gyp:nghttp2'
++              ],
++              'defines': [
++                # We're using the nghttp2 static lib
++                'NGHTTP2_STATICLIB'
++              ]
++            }],
+             [ 'node_shared_libuv=="false"', {
+               'dependencies': [
+                 'deps/uv/uv.gyp:libuv'

diff --git a/net-libs/nodejs/nodejs-8.4.0.ebuild b/net-libs/nodejs/nodejs-8.4.0.ebuild
new file mode 100644
index 00000000000..a86e5fe18f8
--- /dev/null
+++ b/net-libs/nodejs/nodejs-8.4.0.ebuild
@@ -0,0 +1,196 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+RESTRICT="test"
+
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="threads"
+
+inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
+
+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"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
+IUSE="cpu_flags_x86_sse2 debug doc icu +npm +snapshot +ssl systemtap test"
+
+RDEPEND="icu? ( >=dev-libs/icu-56:= )
+	npm? ( ${PYTHON_DEPS} )
+	>=net-libs/http-parser-2.6.2:=
+	>=dev-libs/libuv-1.11.0:=
+	net-libs/nghttp2
+	>=dev-libs/openssl-1.0.2g:0=[-bindist]
+	sys-libs/zlib"
+DEPEND="${RDEPEND}
+	${PYTHON_DEPS}
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )"
+
+S="${WORKDIR}/node-v${PV}"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+PATCHES=(
+	"${FILESDIR}"/gentoo-global-npm-config.patch
+	"${FILESDIR}"/nodejs-8.4.0-shared-nghttp2.patch
+)
+
+pkg_pretend() {
+	(use x86 && ! use cpu_flags_x86_sse2) && \
+		die "Your CPU doesn't support the required SSE2 instruction."
+
+	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
+		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
+}
+
+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
+
+	# make sure we use python2.* while using gyp
+	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
+	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
+
+	# 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() {
+	local myarch=""
+	local myconf=( --shared-http-parser --shared-libuv --shared-nghttp2 --shared-openssl --shared-zlib )
+	use npm || myconf+=( --without-npm )
+	use icu && myconf+=( --with-intl=system-icu )
+	use snapshot && myconf+=( --with-snapshot )
+	use ssl || myconf+=( --without-ssl )
+	use debug && myconf+=( --debug )
+
+	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" \
+	"${PYTHON}" configure \
+		--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)"
+	emake install DESTDIR="${D}"
+	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
+		# Patch docs to make them offline readable
+		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
+			sed -i '/fonts.googleapis.com/ d' $i;
+		done
+		# Install docs!
+		dohtml -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="$(emktemp)"
+		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
+		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
+
+		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
+}
+
+src_test() {
+	out/${BUILDTYPE}/cctest || die
+	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
+}
+
+pkg_postinst() {
+	einfo "The global npm config lives in /etc/npm. This deviates slightly"
+	einfo "from upstream which otherwise would have it live in /usr/etc/."
+	einfo ""
+	einfo "Protip: When using node-gyp to install native modules, you can"
+	einfo "avoid having to download extras by doing the following:"
+	einfo "$ node-gyp --nodedir /usr/include/node <command>"
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2017-10-24  4:49 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2017-10-24  4:49 UTC (permalink / raw
  To: gentoo-commits

commit:     1552d931b0812314bb69e11bfccd7bfd9da99cf0
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Tue Oct 24 04:45:27 2017 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Tue Oct 24 04:49:16 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1552d931

net-libs/nodejs: Version bump (more on this later).

Package-Manager: Portage-2.3.12, Repoman-2.3.3

 net-libs/nodejs/Manifest                           |   1 +
 .../nodejs/files/nodejs-8.7.0-shared-nghttp2.patch | 105 +++++++++++
 net-libs/nodejs/nodejs-8.7.0.ebuild                | 196 +++++++++++++++++++++
 3 files changed, 302 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 76b36b7107e..ba24f7870bd 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -7,3 +7,4 @@ DIST node-v7.10.0.tar.xz 16751724 SHA256 dc34dd15524ba821ffcae7b245eabe8631e2614
 DIST node-v8.2.1.tar.xz 17897168 SHA256 02c46d8914540eea73d0ad33bf9f371a28aa0dc8c5d740948491fef044ad8c8b SHA512 8d84998e8408b89e003929d7fce89c31703aea59ca5826246422d4d1935941730b0b9907a8a9af088ec8ccad60d8919da04104037083a2363daf118682a3b82a WHIRLPOOL dbbf430699f88b1c86b1a818b9c2fe424d3c63eb36c2b85b54de78954d8f01dc47a2f66a6cecf30c43e8ab29236f0a7509a26afc4586501abcda4494a78a21c7
 DIST node-v8.4.0.tar.xz 18265792 SHA256 5d5aa2a101dcc617231a475812eb8ed87cac21491f1dcc7997b9dd463563f361 SHA512 7d0d97ca64db0bf87f1892490f8b7758a879d2ac22532b69e8e0ee5c04bd11073fd917353eeeabdcfbebc83540715d8c520ec9bf9ea1afc82d8ee7b6caf819f1 WHIRLPOOL 23f50be06615350564577349f6388d6563cbcae9e9b0229133baaab30852be7c759fbb4f265816ab999fa2bfa8666b47fb3ba438e09beff8e030fa2db547001c
 DIST node-v8.5.0.tar.xz 18326412 SHA256 e1cde5d8e5049e7e1b61aef128f26162059d885dc8cab5014bf5cbf693f75c3c SHA512 7ef83a6da7ba9d61c19df0530dfee7b769c0bc7ab066fc29fdb54c9b09085a3536699c7c92889cea8fbf3d6241cc66c383cd351451da8019fea4e0d25d043f3d WHIRLPOOL 63576159748e9423a0b1df7d032d4f5edc23d33f22fd76d3dc0f0b4804606abf57011097dcf4fd2d3707b22babe69bcd976133b7450558925b5d679872abd382
+DIST node-v8.7.0.tar.xz 18186384 SHA256 5a17d08c68ee7c1e748fd32534edda766cb57c13ed98e693f3075bc9d9a0b59a SHA512 5ce41d2d7f1c07330c4d9acc8129840d03fb820dac2f87be3f277a372ed6d84d6e1516e1d804e2277d500f32f9838d4307122b26962029d4f811904523f72530 WHIRLPOOL f4541efef681204684d491c9a2539560602c017087fa895e41b3ee9616ce6860a22634179bb904e816eee45b5f5ebc06bada5bb55be05e6e1418cac45cc55966

diff --git a/net-libs/nodejs/files/nodejs-8.7.0-shared-nghttp2.patch b/net-libs/nodejs/files/nodejs-8.7.0-shared-nghttp2.patch
new file mode 100644
index 00000000000..5f5a2c7b7ff
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-8.7.0-shared-nghttp2.patch
@@ -0,0 +1,105 @@
+--- a/configure
++++ b/configure
+@@ -182,6 +182,27 @@
+     dest='shared_http_parser_libpath',
+     help='a directory to search for the shared http_parser DLL')
+ 
++shared_optgroup.add_option('--shared-nghttp2',
++    action='store_true',
++    dest='shared_nghttp2',
++    help='link to a shared nghttp2 DLL instead of static linking')
++
++shared_optgroup.add_option('--shared-nghttp2-includes',
++    action='store',
++    dest='shared_nghttp2_includes',
++    help='directory containing nghttp2 header files')
++
++shared_optgroup.add_option('--shared-nghttp2-libname',
++    action='store',
++    dest='shared_nghttp2_libname',
++    default='nghttp2',
++    help='alternative lib name to link to [default: %default]')
++
++shared_optgroup.add_option('--shared-nghttp2-libpath',
++    action='store',
++    dest='shared_nghttp2_libpath',
++    help='a directory to search for the shared nghttp2 DLL')
++
+ shared_optgroup.add_option('--shared-libuv',
+     action='store_true',
+     dest='shared_libuv',
+@@ -1360,6 +1381,7 @@
+ configure_node(output)
+ configure_library('zlib', output)
+ configure_library('http_parser', output)
++configure_library('nghttp2', output)
+ configure_library('libuv', output)
+ configure_library('libcares', output)
+ # stay backwards compatible with shared cares builds
+--- a/node.gyp
++++ b/node.gyp
+@@ -14,6 +14,7 @@
+     'node_module_version%': '',
+     'node_shared_zlib%': 'false',
+     'node_shared_http_parser%': 'false',
++    'node_shared_nghttp2%': 'false',
+     'node_shared_cares%': 'false',
+     'node_shared_libuv%': 'false',
+     'node_use_openssl%': 'true',
+@@ -151,8 +152,15 @@
+       'type': '<(node_target_type)',
+ 
+       'dependencies': [
+-        'node_js2c#host',
+-        'deps/nghttp2/nghttp2.gyp:nghttp2'
++        'node_js2c#host'
++      ],
++
++      'conditions': [
++        [ 'node_shared_nghttp2=="false"', {
++          'dependencies': [
++            'deps/nghttp2/nghttp2.gyp:nghttp2'
++          ]
++        }]
+       ],
+ 
+       'includes': [
+@@ -163,8 +171,7 @@
+         'src',
+         'tools/msvs/genfiles',
+         'deps/uv/src/ares',
+-        '<(SHARED_INTERMEDIATE_DIR)', # for node_natives.h
+-        'deps/nghttp2/lib/includes'
++        '<(SHARED_INTERMEDIATE_DIR)' # for node_natives.h
+       ],
+ 
+       'sources': [
+@@ -691,6 +696,15 @@
+                 'deps/http_parser/http_parser.gyp:http_parser'
+               ]
+             }],
++            [ 'node_shared_nghttp2=="false"', {
++              'dependencies': [
++                'deps/nghttp2/nghttp2.gyp:nghttp2'
++              ],
++              'defines': [
++                # We're using the nghttp2 static lib
++                'NGHTTP2_STATICLIB'
++              ]
++            }],
+             [ 'node_shared_libuv=="false"', {
+               'dependencies': [
+                 'deps/uv/uv.gyp:libuv'
+--- a/node.gypi
++++ b/node.gypi
+@@ -251,6 +251,10 @@
+       'dependencies': [ 'deps/http_parser/http_parser.gyp:http_parser' ],
+     }],
+ 
++    [ 'node_shared_nghttp2=="false"', {
++      'dependencies': [ 'deps/nghttp2/nghttp2.gyp:nghttp2' ],
++    }],
++
+     [ 'node_shared_cares=="false"', {
+       'dependencies': [ 'deps/cares/cares.gyp:cares' ],
+     }],

diff --git a/net-libs/nodejs/nodejs-8.7.0.ebuild b/net-libs/nodejs/nodejs-8.7.0.ebuild
new file mode 100644
index 00000000000..2739d2a8cd9
--- /dev/null
+++ b/net-libs/nodejs/nodejs-8.7.0.ebuild
@@ -0,0 +1,196 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+RESTRICT="test"
+
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="threads"
+
+inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
+
+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"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
+IUSE="cpu_flags_x86_sse2 debug doc icu +npm +snapshot +ssl systemtap test"
+
+RDEPEND="icu? ( >=dev-libs/icu-56:= )
+	npm? ( ${PYTHON_DEPS} )
+	>=net-libs/http-parser-2.7.0:=
+	>=dev-libs/libuv-1.15.0:=
+	>=net-libs/nghttp2-1.25.0
+	>=dev-libs/openssl-1.0.2g:0=[-bindist]
+	sys-libs/zlib"
+DEPEND="${RDEPEND}
+	${PYTHON_DEPS}
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )"
+
+S="${WORKDIR}/node-v${PV}"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+PATCHES=(
+	"${FILESDIR}"/gentoo-global-npm-config.patch
+	"${FILESDIR}"/nodejs-8.7.0-shared-nghttp2.patch
+)
+
+pkg_pretend() {
+	(use x86 && ! use cpu_flags_x86_sse2) && \
+		die "Your CPU doesn't support the required SSE2 instruction."
+
+	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
+		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
+}
+
+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
+
+	# make sure we use python2.* while using gyp
+	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
+	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
+
+	# 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() {
+	local myarch=""
+	local myconf=( --shared-http-parser --shared-libuv --shared-nghttp2 --shared-openssl --shared-zlib )
+	use npm || myconf+=( --without-npm )
+	use icu && myconf+=( --with-intl=system-icu )
+	use snapshot && myconf+=( --with-snapshot )
+	use ssl || myconf+=( --without-ssl )
+	use debug && myconf+=( --debug )
+
+	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" \
+	"${PYTHON}" configure \
+		--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)"
+	emake install DESTDIR="${D}"
+	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
+		# Patch docs to make them offline readable
+		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
+			sed -i '/fonts.googleapis.com/ d' $i;
+		done
+		# Install docs!
+		dohtml -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="$(emktemp)"
+		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
+		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
+
+		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
+}
+
+src_test() {
+	out/${BUILDTYPE}/cctest || die
+	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
+}
+
+pkg_postinst() {
+	einfo "The global npm config lives in /etc/npm. This deviates slightly"
+	einfo "from upstream which otherwise would have it live in /usr/etc/."
+	einfo ""
+	einfo "Protip: When using node-gyp to install native modules, you can"
+	einfo "avoid having to download extras by doing the following:"
+	einfo "$ node-gyp --nodedir /usr/include/node <command>"
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2017-11-15 15:13 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2017-11-15 15:13 UTC (permalink / raw
  To: gentoo-commits

commit:     143a0116d9c526f5010b52db31431e70f33aa134
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Wed Nov 15 15:13:20 2017 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Wed Nov 15 15:13:36 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=143a0116

net-libs/nodejs: Version bump.

Package-Manager: Portage-2.3.13, Repoman-2.3.4

 net-libs/nodejs/Manifest                           |   1 +
 .../nodejs/files/nodejs-9.2.0-shared-nghttp2.patch |  89 ++++++++++
 net-libs/nodejs/nodejs-9.2.0.ebuild                | 197 +++++++++++++++++++++
 3 files changed, 287 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index e466edb6328..d6d171d04ad 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -4,3 +4,4 @@ DIST node-v6.11.5.tar.xz 15699404 SHA256 1c6de415216799fbaeca82304b3fef87accc710
 DIST node-v6.9.4.tar.xz 15519264 SHA256 c51d7c61db40455d57428abcadc7eb0f0a08a8878cb1d8ea3c1e211c54532c35 SHA512 86d3e2889031c2b50c021bd3fd63194c2c22c44291d51dff1b5e1652b01853c09d2880c2f58fdad062e3e2a3f637a3f0d78dac66b835b676790cf272e64f8dce WHIRLPOOL d1bcf488ed1aae7959303b988c9467fc5d0930166c7bfe0e441392763e19f788496971c07560a9f62586bbb2be7ce741ece8346140d665d29593b9b8f649b002
 DIST node-v8.9.1.tar.xz 18290848 SHA256 ef160c21f60f8aca64145985e01b4044435e381dc16e8f0640ed0223e84f17e0 SHA512 e1d93def34c1b91de90b807031e2f313661658cd045d44d290950190b10512770df05cb92e9657bab7ad6654d3359364193567cf693ddb2b3574d2a48e4ee256 WHIRLPOOL f1e47a0d078e0c1c29c993c8266337ae1fa0ee18ac81e053c4deabe85a94a5de0681ea9ed7f81119d108235055b849bc30557eb0d86345675580d76bd7c05f4d
 DIST node-v9.1.0.tar.xz 18256556 SHA256 7e34d581332aedc85306859e613a81cce2531bdd30eef358cb54db8a4f5c3c49 SHA512 3e99c8c93cb05194e572a1fcf25032da2d94e5dffec1ec3044945d70c02a07f31d872501c0614dd9e8142ddb60e1c20cf13b59859be9c4e9e6beb3f7b8fc3aae WHIRLPOOL 70864c2bbb1e69f5e30a41098dd68ab399cc2e78e9d90237bdc08e425d7f1d06c6a8b74557f44e1b73f021d18096e60eaee00e5a0c51b58408ac11a13f0cc53a
+DIST node-v9.2.0.tar.xz 18347108 SHA256 64caf263eadc1aea072ce5d30ded7f4534aa7f59c8c6993eee4accad96e3bbc2 SHA512 3335a2ec17f4698bda58f2a2c9548546912b9a4109c0bff0ffc57bca14d40101bcc00356231c95c08733860286ac340e227ca79debac581835f84ae3967cdb4b WHIRLPOOL f14cd3f537d2f1f41ee299f2492f2dc275587846dc231f668ccb3c2d31720020b982474130ae7ce4b8ca709e2f67c510d3e65b7641fbc3fff0e3f9be3321ca2a

diff --git a/net-libs/nodejs/files/nodejs-9.2.0-shared-nghttp2.patch b/net-libs/nodejs/files/nodejs-9.2.0-shared-nghttp2.patch
new file mode 100644
index 00000000000..a145c0c7116
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-9.2.0-shared-nghttp2.patch
@@ -0,0 +1,89 @@
+--- a/configure
++++ b/configure
+@@ -182,6 +182,27 @@
+     dest='shared_http_parser_libpath',
+     help='a directory to search for the shared http_parser DLL')
+ 
++shared_optgroup.add_option('--shared-nghttp2',
++    action='store_true',
++    dest='shared_nghttp2',
++    help='link to a shared nghttp2 DLL instead of static linking')
++
++shared_optgroup.add_option('--shared-nghttp2-includes',
++    action='store',
++    dest='shared_nghttp2_includes',
++    help='directory containing nghttp2 header files')
++
++shared_optgroup.add_option('--shared-nghttp2-libname',
++    action='store',
++    dest='shared_nghttp2_libname',
++    default='nghttp2',
++    help='alternative lib name to link to [default: %default]')
++
++shared_optgroup.add_option('--shared-nghttp2-libpath',
++    action='store',
++    dest='shared_nghttp2_libpath',
++    help='a directory to search for the shared nghttp2 DLL')
++
+ shared_optgroup.add_option('--shared-libuv',
+     action='store_true',
+     dest='shared_libuv',
+@@ -1360,6 +1381,7 @@
+ configure_node(output)
+ configure_library('zlib', output)
+ configure_library('http_parser', output)
++configure_library('nghttp2', output)
+ configure_library('libuv', output)
+ configure_library('libcares', output)
+ # stay backwards compatible with shared cares builds
+--- a/node.gyp
++++ b/node.gyp
+@@ -14,6 +14,7 @@
+     'node_module_version%': '',
+     'node_shared_zlib%': 'false',
+     'node_shared_http_parser%': 'false',
++    'node_shared_nghttp2%': 'false',
+     'node_shared_cares%': 'false',
+     'node_shared_libuv%': 'false',
+     'node_use_openssl%': 'true',
+@@ -151,8 +152,15 @@
+       'type': '<(node_target_type)',
+ 
+       'dependencies': [
+-        'node_js2c#host',
+-        'deps/nghttp2/nghttp2.gyp:nghttp2'
++        'node_js2c#host'
++      ],
++
++      'conditions': [
++        [ 'node_shared_nghttp2=="false"', {
++          'dependencies': [
++            'deps/nghttp2/nghttp2.gyp:nghttp2'
++          ]
++        }]
+       ],
+ 
+       'includes': [
+@@ -180,8 +180,7 @@
+       'include_dirs': [
+         'src',
+         'tools/msvs/genfiles',
+-        '<(SHARED_INTERMEDIATE_DIR)', # for node_natives.h
+-        'deps/nghttp2/lib/includes'
++        '<(SHARED_INTERMEDIATE_DIR)' # for node_natives.h
+       ],
+ 
+       'sources': [
+--- a/node.gypi
++++ b/node.gypi
+@@ -251,6 +251,10 @@
+       'dependencies': [ 'deps/http_parser/http_parser.gyp:http_parser' ],
+     }],
+ 
++    [ 'node_shared_nghttp2=="false"', {
++      'dependencies': [ 'deps/nghttp2/nghttp2.gyp:nghttp2' ],
++    }],
++
+     [ 'node_shared_cares=="false"', {
+       'dependencies': [ 'deps/cares/cares.gyp:cares' ],
+     }],

diff --git a/net-libs/nodejs/nodejs-9.2.0.ebuild b/net-libs/nodejs/nodejs-9.2.0.ebuild
new file mode 100644
index 00000000000..aaab3c90a4b
--- /dev/null
+++ b/net-libs/nodejs/nodejs-9.2.0.ebuild
@@ -0,0 +1,197 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+RESTRICT="test"
+
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="threads"
+
+inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
+
+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"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
+IUSE="cpu_flags_x86_sse2 debug doc icu +npm +snapshot +ssl systemtap test"
+
+RDEPEND="icu? ( >=dev-libs/icu-59:= )
+	npm? ( ${PYTHON_DEPS} )
+	>=net-libs/http-parser-2.7.0:=
+	>=dev-libs/libuv-1.16.1:=
+	>=net-libs/nghttp2-1.25.0
+	>=dev-libs/openssl-1.0.2g:0=[-bindist]
+	sys-libs/zlib"
+DEPEND="${RDEPEND}
+	${PYTHON_DEPS}
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )"
+
+S="${WORKDIR}/node-v${PV}"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+PATCHES=(
+	"${FILESDIR}"/gentoo-global-npm-config.patch
+	"${FILESDIR}"/nodejs-9.2.0-shared-nghttp2.patch
+)
+
+pkg_pretend() {
+	(use x86 && ! use cpu_flags_x86_sse2) && \
+		die "Your CPU doesn't support the required SSE2 instruction."
+
+	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
+		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
+}
+
+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
+
+	# make sure we use python2.* while using gyp
+	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
+	sed -i -e "s/|| 'python2'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js 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 || 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() {
+	local myarch=""
+	local myconf=( --shared-http-parser --shared-libuv --shared-nghttp2 --shared-openssl --shared-zlib )
+	use npm || myconf+=( --without-npm )
+	use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none )
+	use snapshot && myconf+=( --with-snapshot )
+	use ssl || myconf+=( --without-ssl )
+	use debug && myconf+=( --debug )
+
+	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" \
+	"${PYTHON}" configure \
+		--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)"
+	emake install DESTDIR="${D}"
+	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
+		# Patch docs to make them offline readable
+		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
+			sed -i '/fonts.googleapis.com/ d' $i;
+		done
+		# Install docs!
+		dohtml -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="$(emktemp)"
+		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
+		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
+
+		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
+}
+
+src_test() {
+	out/${BUILDTYPE}/cctest || die
+	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
+}
+
+pkg_postinst() {
+	einfo "The global npm config lives in /etc/npm. This deviates slightly"
+	einfo "from upstream which otherwise would have it live in /usr/etc/."
+	einfo ""
+	einfo "Protip: When using node-gyp to install native modules, you can"
+	einfo "avoid having to download extras by doing the following:"
+	einfo "$ node-gyp --nodedir /usr/include/node <command>"
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2018-07-23 10:49 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2018-07-23 10:49 UTC (permalink / raw
  To: gentoo-commits

commit:     889194e648e41fc1179e590d926dbee5371b37ce
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Mon Jul 23 10:47:59 2018 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Mon Jul 23 10:47:59 2018 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=889194e6

net-libs/nodejs: Fix npm patch (bug #660450).

Package-Manager: Portage-2.3.43, Repoman-2.3.10

 net-libs/nodejs/files/nodejs-10.3.0-global-npm-config.patch       | 4 ++--
 net-libs/nodejs/{nodejs-10.6.0.ebuild => nodejs-10.6.0-r1.ebuild} | 0
 net-libs/nodejs/{nodejs-10.7.0.ebuild => nodejs-10.7.0-r1.ebuild} | 0
 3 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/net-libs/nodejs/files/nodejs-10.3.0-global-npm-config.patch b/net-libs/nodejs/files/nodejs-10.3.0-global-npm-config.patch
index e2bbbbe97a3..9c7fe6888fb 100644
--- a/net-libs/nodejs/files/nodejs-10.3.0-global-npm-config.patch
+++ b/net-libs/nodejs/files/nodejs-10.3.0-global-npm-config.patch
@@ -1,6 +1,6 @@
 --- a/deps/npm/lib/config/core.js
 +++ b/deps/npm/lib/config/core.js
-@@ -153,11 +153,13 @@
+@@ -153,11 +153,12 @@
      // Eg, `npm config get globalconfig --prefix ~/local` should
      // return `~/local/etc/npmrc`
      // annoying humans and their expectations!
@@ -8,12 +8,12 @@
 -      var etc = path.resolve(conf.get('prefix'), 'etc')
 -      defaults.globalconfig = path.resolve(etc, 'npmrc')
 -      defaults.globalignorefile = path.resolve(etc, 'npmignore')
+-    }
 +    // gentoo deviates wrt global config; store in /etc/npm
 +    var globalconfig = path.resolve('/etc', 'npm')
 +    mkdirp(globalconfig, function () {
 +      defaults.globalconfig = path.resolve(globalconfig, 'npmrc')
 +      defaults.globalignorefile = path.resolve(globalconfig, 'npmignore')
-     }
 +    })
  
      conf.addFile(conf.get('globalconfig'), 'global')

diff --git a/net-libs/nodejs/nodejs-10.6.0.ebuild b/net-libs/nodejs/nodejs-10.6.0-r1.ebuild
similarity index 100%
rename from net-libs/nodejs/nodejs-10.6.0.ebuild
rename to net-libs/nodejs/nodejs-10.6.0-r1.ebuild

diff --git a/net-libs/nodejs/nodejs-10.7.0.ebuild b/net-libs/nodejs/nodejs-10.7.0-r1.ebuild
similarity index 100%
rename from net-libs/nodejs/nodejs-10.7.0.ebuild
rename to net-libs/nodejs/nodejs-10.7.0-r1.ebuild


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2018-12-13 12:50 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2018-12-13 12:50 UTC (permalink / raw
  To: gentoo-commits

commit:     7f275c73799d53dbf45cdded0c5e6d52839c5e2c
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Thu Dec 13 12:49:53 2018 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Thu Dec 13 12:50:16 2018 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7f275c73

net-libs/nodejs: Fix llhttp/http_parser in live ebuild

Package-Manager: Portage-2.3.52, Repoman-2.3.12
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>

 net-libs/nodejs/files/nodejs-99999999-llhttp.patch | 20 ++++++++++++++++++++
 net-libs/nodejs/nodejs-99999999.ebuild             |  1 +
 2 files changed, 21 insertions(+)

diff --git a/net-libs/nodejs/files/nodejs-99999999-llhttp.patch b/net-libs/nodejs/files/nodejs-99999999-llhttp.patch
new file mode 100644
index 00000000000..1b6eb9fb7fa
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-99999999-llhttp.patch
@@ -0,0 +1,20 @@
+--- a/node.gypi
++++ b/node.gypi
+@@ -169,11 +169,15 @@
+ 
+     [ 'node_shared_http_parser=="false"', {
+       'dependencies': [
+-        'deps/http_parser/http_parser.gyp:http_parser',
+-        'deps/llhttp/llhttp.gyp:llhttp'
++        'deps/http_parser/http_parser.gyp:http_parser'
+       ],
+     } ],
+ 
++    [ '"true"', { 'dependencies': [
++        'deps/llhttp/llhttp.gyp:llhttp'
++      ],
++    }],
++
+     [ 'node_shared_cares=="false"', {
+       'dependencies': [ 'deps/cares/cares.gyp:cares' ],
+     }],

diff --git a/net-libs/nodejs/nodejs-99999999.ebuild b/net-libs/nodejs/nodejs-99999999.ebuild
index f6a2fedbb6b..e5f27818359 100644
--- a/net-libs/nodejs/nodejs-99999999.ebuild
+++ b/net-libs/nodejs/nodejs-99999999.ebuild
@@ -39,6 +39,7 @@ DEPEND="
 "
 PATCHES=(
 	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
+	"${FILESDIR}"/${PN}-99999999-llhttp.patch
 )
 
 pkg_pretend() {


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2018-12-27 14:59 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2018-12-27 14:59 UTC (permalink / raw
  To: gentoo-commits

commit:     cd787e294ef5ba4448aeffdd9396e39ce9ba7e6d
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Thu Dec 27 14:58:46 2018 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Thu Dec 27 14:58:59 2018 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cd787e29

net-libs/nodejs: Old

Package-Manager: Portage-2.3.52, Repoman-2.3.12
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>

 net-libs/nodejs/Manifest                         |   6 -
 net-libs/nodejs/files/nodejs-11.4.0-llhttp.patch |  30 ----
 net-libs/nodejs/nodejs-10.14.0.ebuild            | 205 ----------------------
 net-libs/nodejs/nodejs-10.14.2.ebuild            | 205 ----------------------
 net-libs/nodejs/nodejs-11.4.0.ebuild             | 207 -----------------------
 net-libs/nodejs/nodejs-11.5.0.ebuild             | 207 -----------------------
 net-libs/nodejs/nodejs-6.15.1.ebuild             | 200 ----------------------
 net-libs/nodejs/nodejs-8.14.1.ebuild             | 207 -----------------------
 8 files changed, 1267 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 9e69b154428..193cd7e834c 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,14 +1,8 @@
 DIST node-v0.12.18.tar.gz 19842591 BLAKE2B f94f4de6e2875267be194580c645087a262b90da99f10d651a22838c041da07056df81204bb04ce8da083a080062509dcca4d1e3ac2250d651ead8a4cc025028 SHA512 6866608a43eb213f3b715ea0fcc28983fd959ab679c567a1b464f62acd936506f2bce88ea48a60209d8ef8d98259f4b47cd3434893eb4ff82a132775edb37b7b
-DIST node-v10.14.0.tar.xz 20193912 BLAKE2B a72411c9b7bfc9e257089d26cfc7a00321d1db7836b9a292544971fbceaaeae8b178ef53735175621d42169eb6839173340b00e441e498187bf4fffc02edca71 SHA512 82900373993ae2a068ccc9217eadc700a91956893f0a9973c5003ca648e16859a5b37919ea15c06bc1bd746957db6915ad75aa3d8ddb18c1b949c5723617c0c9
-DIST node-v10.14.2.tar.xz 20214264 BLAKE2B ca962d58a5b23c0acdc242d80d5b9a5bf2b2c81b218ad177503d6152bdc58682873156f01f1c0634217486316628edaa1de4042241906912e910c7b1dfa2abf5 SHA512 35d66708ffe557b87d93328d49d46423b18a3ada6f33031a39b1fab063adf8d61d431cea4e91df853922b1cf34d337fe3adbb3f6582f37bc059c0e793dd8034a
 DIST node-v10.15.0.tar.xz 20217588 BLAKE2B ef7f626bd3b13b11a1cbf21f5c6a2ce08567dddc2fb525c5f10e02f81750a648245c2eb88535d8aac1b055a13d12f9ead72d55c4ccf68062940da09d582344c3 SHA512 6c10ae4070cd8b89d4d31ee2137453fa582cef85c6f002c78d5029ceedddf5caeee8e28a4e75dfc632c3af3c8e2acec403ab17a927ba51fa31175d58b45cbf49
-DIST node-v11.4.0.tar.xz 20406416 BLAKE2B 45c5f2d42aa328c5f5530be99e89e01fe70947e41c9c6b9def599d62df57fb48ce575f36da36369756e98fe3c6d4d0093c0f2f28e0c571874e711cca6d705582 SHA512 1d2fc3cb545f0262bcec674ffb47cd9391876744bcac5f1d95e59022fa1afef921f2dbb2d0ae957b8162349a085fba8ad526d71f63ebc38213e8e9b56908ed31
-DIST node-v11.5.0.tar.xz 20415048 BLAKE2B 5d156545c9fc4a93991aa3d695b9792e7e7fa1768d9ddd32f6aa600f6967a18e3f5cb8b17081a0e1bf0baeaa8f4d731e80dc115163e1f79cf080ef1a2404821d SHA512 17910b008f1d6d9ff29cad89e1683abbf02702e09ab192bd8059c2e37ef774011a2339d7100f4d691cfb3e8fd576b88e45cadc50bff394b4848c2bdd246a407a
 DIST node-v11.6.0.tar.xz 20410716 BLAKE2B bf6150a42070f714dfa5a38da70a4ce6b6a81ca5b9aedb84e672dff5244676ce77ca771ee46d34adc7cd7b84a0fe91537f9cbd3841a95c4bee67a894d4e8b4e7 SHA512 7e3ee41a5de8395669796cf8f81a9e8f584ceda480b54874fceb057ccf8aa5b986239ca842b2dbd796dd1a97f9e2111995b334278f6d7bf38421a84c4e883c65
 DIST node-v4.9.1.tar.xz 13250164 BLAKE2B 7a689b99bb4bf507f7f21dd2c096a5766d023a8174c0f468cab37365af1920b8700da04157e1a406917790524255ef32c243a74662fd50ef7d3567d189dac9cf SHA512 690c9fdf608e5194069a10955bdd94ec87cb1c308f13bc4d2cae92fa01436ace10fadf58f2e51d477dde6c570b23edc1c71fafea79bfc9cab2903eb2fa5f87aa
 DIST node-v6.14.4.tar.xz 15842824 BLAKE2B fc56364be64fe5824e2bb50d861ebf8f58f9895f2c9c108b8df3315b127ffb2755eac85c28165ac9779adab4611ce8f5ea1a5745f43ebaa1389e82b8215c6396 SHA512 1ead0c097ec125230dd631f19a5c3ec06a1371f9ca3b392b5ad08fcc227dd0142f33ad52f96890c2c17448a4951a635b9099dfff00d7d8b3ffb59b07904d1bfa
-DIST node-v6.15.1.tar.xz 15845836 BLAKE2B 8adedbc72bbc0899ec4782894c19ad550c9d41d4069ed640471c7d97185d413b0f9e9a29b9538df5e1b39f59a04abc4adfb2bbdcda9b8803c18a650a2779e92b SHA512 e1d927c91a949b8c681c0ab2c8cbd62d7c202d76abeb9791b1260cf64a01c8aeaa50697e1ed33658586565fa85223abcaeb9370024313a5a5e31297ed4fe310b
 DIST node-v6.16.0.tar.xz 15854256 BLAKE2B 0c70ce154639cbae12e0dfd6e7d5705999badb5872d71f388a3bb89f2830ddb096761aed47bdc6e310f2088fa79070d8a3427361206d74f686d86b27f929a4b4 SHA512 e9a222af328c8afb47b4b9c0f39ca5c1e45c5590b2064b3a8994b25f63acd041fba591d390e5a617db08d1212de15c438c66000ddcbc65cd071681311fa3591d
 DIST node-v8.12.0.tar.xz 18310452 BLAKE2B 79634fc57cd76a97e72bab4be37da91d5eff4d13cdaa2b48e83f013885fa3590ba4a28378baf036ed26b7304bf234753d1d4014f72571496f5bb6cd5b221e5f0 SHA512 665d2dba287d78bcd723d7b4d00a6897fb996f4aa69a541e010a3dfeb2614257892117fcce7123966b1ecaddc9269a6667e0e262df693baea1f476c96de55c42
-DIST node-v8.14.1.tar.xz 18497208 BLAKE2B 4ce23e9257c224dfa646a57acfc5d86a0cd70ba5861e6ec75c6d912c6c23f50c99e8239aba364179ae9e07cd20dde67c86e76aed0ec3d1feb1606b25a55cac2c SHA512 038975261da930aa8122e9ad44f6d59c32b32dbf6f71a4da8ba74f0874455a7b8f7a9878d900829898b25adb57b81a8114b4222b0384173db19daa769ea025d0
 DIST node-v8.15.0.tar.xz 18499412 BLAKE2B bba68517358cea14e9ba7c0c14b3f30caa00e358ff79d0602a1a71c9dd80334800ea2fd12086c5bee47cc23b9debe2cb0e36650f6be02e20615047a971297c54 SHA512 9a3d54ee9e22919ab425532ea64336b1dee0ae3ce4afd4eaacc109a2c2d34c98ea8188acd436c55a5dbba30fb4f95f8fcc9000ea60a81224d09b90d2f493cefd

diff --git a/net-libs/nodejs/files/nodejs-11.4.0-llhttp.patch b/net-libs/nodejs/files/nodejs-11.4.0-llhttp.patch
deleted file mode 100644
index 07ac9af6c66..00000000000
--- a/net-libs/nodejs/files/nodejs-11.4.0-llhttp.patch
+++ /dev/null
@@ -1,30 +0,0 @@
---- a/node.gypi
-+++ b/node.gypi
-@@ -169,11 +169,15 @@
- 
-     [ 'node_shared_http_parser=="false"', {
-       'dependencies': [
--        'deps/http_parser/http_parser.gyp:http_parser',
--        'deps/llhttp/llhttp.gyp:llhttp'
-+        'deps/http_parser/http_parser.gyp:http_parser'
-       ],
-     } ],
- 
-+    [ '"true"', { 'dependencies': [
-+        'deps/llhttp/llhttp.gyp:llhttp'
-+      ],
-+    }],
-+
-     [ 'node_shared_cares=="false"', {
-       'dependencies': [ 'deps/cares/cares.gyp:cares' ],
-     }],
---- a/src/node_metadata.cc
-+++ b/src/node_metadata.cc
-@@ -2,6 +2,7 @@
- #include "ares.h"
- #include "nghttp2/nghttp2ver.h"
- #include "node.h"
-+#include "node_internals.h"
- #include "util.h"
- #include "uv.h"
- #include "v8.h"

diff --git a/net-libs/nodejs/nodejs-10.14.0.ebuild b/net-libs/nodejs/nodejs-10.14.0.ebuild
deleted file mode 100644
index ea37a260ff5..00000000000
--- a/net-libs/nodejs/nodejs-10.14.0.ebuild
+++ /dev/null
@@ -1,205 +0,0 @@
-# Copyright 1999-2018 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl systemtap test"
-REQUIRED_USE="
-	${PYTHON_REQUIRED_USE}
-	inspector? ( icu ssl )
-	npm? ( ssl )
-"
-
-RDEPEND="
-	>=dev-libs/libuv-1.23.2:=
-	>=net-dns/c-ares-1.14.0
-	>=net-libs/http-parser-2.8.0:=
-	>=net-libs/nghttp2-1.34.0
-	sys-libs/zlib
-	icu? ( >=dev-libs/icu-62.1:= )
-	ssl? ( =dev-libs/openssl-1.1.0*:0= )
-"
-DEPEND="
-	${RDEPEND}
-	${PYTHON_DEPS}
-	systemtap? ( dev-util/systemtap )
-	test? ( net-misc/curl )
-"
-S="${WORKDIR}/node-v${PV}"
-PATCHES=(
-	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python2'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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 deps/v8/gypfiles/toolchain.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() {
-	local myconf=( --shared-cares --shared-http-parser --shared-libuv --shared-nghttp2 --shared-zlib )
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none )
-	use inspector || myconf+=( --without-inspector )
-	use npm || myconf+=( --without-npm )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl && myconf+=( --shared-openssl ) || myconf+=( --without-ssl )
-
-	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" \
-	"${PYTHON}" configure \
-		--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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs
-		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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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 "${D}"/usr/share/doc/node "${D}"/usr/share/doc/${PF} || die
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-10.14.2.ebuild b/net-libs/nodejs/nodejs-10.14.2.ebuild
deleted file mode 100644
index ccc31bc334c..00000000000
--- a/net-libs/nodejs/nodejs-10.14.2.ebuild
+++ /dev/null
@@ -1,205 +0,0 @@
-# Copyright 1999-2018 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl systemtap test"
-REQUIRED_USE="
-	${PYTHON_REQUIRED_USE}
-	inspector? ( icu ssl )
-	npm? ( ssl )
-"
-
-RDEPEND="
-	>=dev-libs/libuv-1.23.2:=
-	>=net-dns/c-ares-1.15.0
-	>=net-libs/http-parser-2.8.0:=
-	>=net-libs/nghttp2-1.34.0
-	sys-libs/zlib
-	icu? ( >=dev-libs/icu-62.1:= )
-	ssl? ( =dev-libs/openssl-1.1.0*:0= )
-"
-DEPEND="
-	${RDEPEND}
-	${PYTHON_DEPS}
-	systemtap? ( dev-util/systemtap )
-	test? ( net-misc/curl )
-"
-S="${WORKDIR}/node-v${PV}"
-PATCHES=(
-	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python2'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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 deps/v8/gypfiles/toolchain.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() {
-	local myconf=( --shared-cares --shared-http-parser --shared-libuv --shared-nghttp2 --shared-zlib )
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none )
-	use inspector || myconf+=( --without-inspector )
-	use npm || myconf+=( --without-npm )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl && myconf+=( --shared-openssl ) || myconf+=( --without-ssl )
-
-	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" \
-	"${PYTHON}" configure \
-		--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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs
-		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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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 "${D}"/usr/share/doc/node "${D}"/usr/share/doc/${PF} || die
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-11.4.0.ebuild b/net-libs/nodejs/nodejs-11.4.0.ebuild
deleted file mode 100644
index 0e67f6a9bcd..00000000000
--- a/net-libs/nodejs/nodejs-11.4.0.ebuild
+++ /dev/null
@@ -1,207 +0,0 @@
-# Copyright 1999-2018 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl systemtap test"
-REQUIRED_USE="
-	${PYTHON_REQUIRED_USE}
-	inspector? ( icu ssl )
-	npm? ( ssl )
-"
-
-RDEPEND="
-	>=dev-libs/libuv-1.24.0:=
-	>=net-dns/c-ares-1.15.0
-	>=net-libs/http-parser-2.8.0:=
-	>=net-libs/nghttp2-1.34.0
-	sys-libs/zlib
-	icu? ( >=dev-libs/icu-63.1:= )
-	ssl? ( =dev-libs/openssl-1.1.0*:0= )
-"
-DEPEND="
-	${RDEPEND}
-	${PYTHON_DEPS}
-	systemtap? ( dev-util/systemtap )
-	test? ( net-misc/curl )
-"
-S="${WORKDIR}/node-v${PV}"
-PATCHES=(
-	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
-	"${FILESDIR}"/${PN}-11.4.0-llhttp.patch
-	"${FILESDIR}"/${PN}-11.4.0-stdarg_h.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python2'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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 deps/v8/gypfiles/toolchain.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() {
-	local myconf=( --shared-cares --shared-http-parser --shared-libuv --shared-nghttp2 --shared-zlib )
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none )
-	use inspector || myconf+=( --without-inspector )
-	use npm || myconf+=( --without-npm )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl && myconf+=( --shared-openssl ) || myconf+=( --without-ssl )
-
-	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" \
-	"${PYTHON}" configure \
-		--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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs
-		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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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 "${D}"/usr/share/doc/node "${D}"/usr/share/doc/${PF} || die
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-11.5.0.ebuild b/net-libs/nodejs/nodejs-11.5.0.ebuild
deleted file mode 100644
index cfa00efc596..00000000000
--- a/net-libs/nodejs/nodejs-11.5.0.ebuild
+++ /dev/null
@@ -1,207 +0,0 @@
-# Copyright 1999-2018 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl systemtap test"
-REQUIRED_USE="
-	${PYTHON_REQUIRED_USE}
-	inspector? ( icu ssl )
-	npm? ( ssl )
-"
-
-RDEPEND="
-	>=dev-libs/libuv-1.24.0:=
-	>=net-dns/c-ares-1.15.0
-	>=net-libs/http-parser-2.8.0:=
-	>=net-libs/nghttp2-1.34.0
-	sys-libs/zlib
-	icu? ( >=dev-libs/icu-63.1:= )
-	ssl? ( =dev-libs/openssl-1.1.0*:0= )
-"
-DEPEND="
-	${RDEPEND}
-	${PYTHON_DEPS}
-	systemtap? ( dev-util/systemtap )
-	test? ( net-misc/curl )
-"
-S="${WORKDIR}/node-v${PV}"
-PATCHES=(
-	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
-	"${FILESDIR}"/${PN}-11.4.0-stdarg_h.patch
-	"${FILESDIR}"/${PN}-99999999-llhttp.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python2'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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 deps/v8/gypfiles/toolchain.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() {
-	local myconf=( --shared-cares --shared-http-parser --shared-libuv --shared-nghttp2 --shared-zlib )
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none )
-	use inspector || myconf+=( --without-inspector )
-	use npm || myconf+=( --without-npm )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl && myconf+=( --shared-openssl ) || myconf+=( --without-ssl )
-
-	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" \
-	"${PYTHON}" configure \
-		--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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs
-		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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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 "${D}"/usr/share/doc/node "${D}"/usr/share/doc/${PF} || die
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-6.15.1.ebuild b/net-libs/nodejs/nodejs-6.15.1.ebuild
deleted file mode 100644
index 82289475261..00000000000
--- a/net-libs/nodejs/nodejs-6.15.1.ebuild
+++ /dev/null
@@ -1,200 +0,0 @@
-# Copyright 1999-2018 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl test"
-REQUIRED_USE="
-	${PYTHON_REQUIRED_USE}
-	inspector? ( icu ssl )
-"
-
-RDEPEND="
-	>=dev-libs/libuv-1.16.1:=
-	>=net-libs/http-parser-2.7.0:=
-	sys-libs/zlib
-	icu? ( >=dev-libs/icu-58.2:= )
-	ssl? ( >=dev-libs/openssl-1.0.2n:0=[-bindist] )
-"
-DEPEND="
-	${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )
-"
-S="${WORKDIR}/node-v${PV}"
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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" \
-		-e 's|share/doc/node/|share/doc/'"${PF}"'/|g' \
-		tools/install.py || die
-	sed -i -e "s/'lib'/'${LIBDIR}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-libuv --shared-http-parser --shared-zlib )
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu )
-	use inspector || myconf+=( --without-inspector )
-	use npm || myconf+=( --without-npm )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl && myconf+=( --shared-openssl ) || myconf+=( --without-ssl )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-8.14.1.ebuild b/net-libs/nodejs/nodejs-8.14.1.ebuild
deleted file mode 100644
index 69c390294cd..00000000000
--- a/net-libs/nodejs/nodejs-8.14.1.ebuild
+++ /dev/null
@@ -1,207 +0,0 @@
-# Copyright 1999-2018 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-RESTRICT="test"
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl systemtap test"
-REQUIRED_USE="
-	${PYTHON_REQUIRED_USE}
-	inspector? ( icu ssl )
-	npm? ( ssl )
-"
-
-RDEPEND="
-	>=dev-libs/libuv-1.23.2:=
-	>=net-dns/c-ares-1.10.1
-	>=net-libs/http-parser-2.8.0:=
-	>=net-libs/nghttp2-1.33.0
-	sys-libs/zlib
-	icu? ( >=dev-libs/icu-60.1:= )
-	ssl? ( =dev-libs/openssl-1.0.2*:0=[-bindist] )
-"
-DEPEND="${RDEPEND}
-	${PYTHON_DEPS}
-	systemtap? ( dev-util/systemtap )
-	test? ( net-misc/curl )"
-
-S="${WORKDIR}/node-v${PV}"
-
-PATCHES=(
-	"${FILESDIR}"/nodejs-10.3.0-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python2'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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" \
-		-e 's|share/doc/node/|share/doc/'"${PF}"'/|g' \
-		tools/install.py || die
-
-	sed -i -e "s/'lib'/'${LIBDIR}'/" lib/module.js 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 deps/v8/gypfiles/toolchain.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() {
-	local myconf=( --shared-cares --shared-http-parser --shared-libuv --shared-nghttp2 --shared-zlib )
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none )
-	use inspector || myconf+=( --without-inspector )
-	use npm || myconf+=( --without-npm )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl && myconf+=( --shared-openssl ) || myconf+=( --without-ssl )
-
-	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" \
-	"${PYTHON}" configure \
-		--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_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-src_install() {
-	local LIBDIR="${ED}/usr/$(get_libdir)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs
-		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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2019-03-16 14:45 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2019-03-16 14:45 UTC (permalink / raw
  To: gentoo-commits

commit:     33d606cf69cee530fddba05a20359282a0ccbf52
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 16 12:14:56 2019 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Sat Mar 16 14:45:35 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=33d606cf

net-libs/nodejs: Old

Package-Manager: Portage-2.3.62, Repoman-2.3.12
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 -
 net-libs/nodejs/files/nodejs-11.4.0-stdarg_h.patch |  10 -
 net-libs/nodejs/nodejs-11.10.1.ebuild              | 210 ---------------------
 3 files changed, 221 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index f6c449c3f90..de3f7946880 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,7 +1,6 @@
 DIST node-v0.12.18.tar.gz 19842591 BLAKE2B f94f4de6e2875267be194580c645087a262b90da99f10d651a22838c041da07056df81204bb04ce8da083a080062509dcca4d1e3ac2250d651ead8a4cc025028 SHA512 6866608a43eb213f3b715ea0fcc28983fd959ab679c567a1b464f62acd936506f2bce88ea48a60209d8ef8d98259f4b47cd3434893eb4ff82a132775edb37b7b
 DIST node-v10.15.2.tar.xz 20232972 BLAKE2B 3ffaa0890ddec6b9d00a0b3f32fc62e55a665ea6faba6265df71be601f88a1c948011f908851f1cbb198974ca36f8626fa9a2b4b8827f0155e57ff48f3e25c10 SHA512 2d4ef4758d3a73a160b95249c7dce32307287ef84511f56c3077f18c0d87a53bb73b44dd86131a402c4e86686e5e7cb5aeedb2b075b8ab261fc43d5abbe70ce6
 DIST node-v10.15.3.tar.xz 20262632 BLAKE2B d65d4e274fa829be5cda1970b0ebe7081e8476334cb825e5727324c3202bc015f4ba39589608284d0f8c0b722079c06d1587de5299a3c81ccb7b0eacbdaccf84 SHA512 cf741f733af7a7e1fbd37b0f98110078494b4771dbdfccacfda95a5ea4cda6cdcea4f8d31dddcf27477213614e4ab6cf7d1a1f900cb92936333730737ac4f9e8
-DIST node-v11.10.1.tar.xz 22074212 BLAKE2B de4c224063050901a3898bb9d2a26dba8027b3722528c402d461f2ca892a80e230e16131e9c8b22d6fefbd44b79a6d78aef631934c80ed53f8601fd2d3405150 SHA512 8da793946d18c8368f12e786bc4fdcff0ac61237c95f896a49895d6433edcd42005d50237095fd2b1c69b51d56900d122528783338dbb97e5fcee9dcc9a5812c
 DIST node-v11.11.0.tar.xz 22094004 BLAKE2B 3ca03a659fc1104bf280510277a74167a2a188ba0798c4723730fb850cae3d4ddc4d5f4bbad88dc9dde8b7f57b02f5d9c47d047bb15668e3488e0a002e225cfb SHA512 c89fd154dfbaa999806429c6e416c4fa2f0d5f3cfb9ac6de8b21f9195681ae0170325ae6fd7ab811f4f394d03c1d56db77ae1c730d5e8ff6a64b9a6dfa2286e8
 DIST node-v11.12.0.tar.xz 22077236 BLAKE2B 1cd7252983c0e444e0ce183a11af0912c994b2e36a8f50a86ca543f59548629fb3b857a0d106340f44124637e06cf90b2e079a17a30c2bd8386bd6575fac1fd9 SHA512 54d19ee6cb5127298276287f536dca9d4c9389038bb23fc48e8ef0246bcfcf59961ae704a94c68eb67104a230e3b23cbb7c8559aca83f542b35a46b2797d31e4
 DIST node-v4.9.1.tar.xz 13250164 BLAKE2B 7a689b99bb4bf507f7f21dd2c096a5766d023a8174c0f468cab37365af1920b8700da04157e1a406917790524255ef32c243a74662fd50ef7d3567d189dac9cf SHA512 690c9fdf608e5194069a10955bdd94ec87cb1c308f13bc4d2cae92fa01436ace10fadf58f2e51d477dde6c570b23edc1c71fafea79bfc9cab2903eb2fa5f87aa

diff --git a/net-libs/nodejs/files/nodejs-11.4.0-stdarg_h.patch b/net-libs/nodejs/files/nodejs-11.4.0-stdarg_h.patch
deleted file mode 100644
index 951c35989c6..00000000000
--- a/net-libs/nodejs/files/nodejs-11.4.0-stdarg_h.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/src/node.cc
-+++ b/src/node.cc
-@@ -75,6 +75,7 @@
- #include <fcntl.h>  // _O_RDWR
- #include <limits.h>  // PATH_MAX
- #include <signal.h>
-+#include <stdarg.h> // va_start/va_end
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>

diff --git a/net-libs/nodejs/nodejs-11.10.1.ebuild b/net-libs/nodejs/nodejs-11.10.1.ebuild
deleted file mode 100644
index c4b2df6f8bd..00000000000
--- a/net-libs/nodejs/nodejs-11.10.1.ebuild
+++ /dev/null
@@ -1,210 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-single-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl systemtap test"
-REQUIRED_USE="
-	${PYTHON_REQUIRED_USE}
-	inspector? ( icu ssl )
-	npm? ( ssl )
-"
-
-RDEPEND="
-	>=dev-libs/libuv-1.26.0:=
-	>=net-dns/c-ares-1.15.0
-	>=net-libs/http-parser-2.9.0:=
-	>=net-libs/nghttp2-1.34.0
-	sys-libs/zlib
-	icu? ( >=dev-libs/icu-63.1:= )
-	ssl? ( =dev-libs/openssl-1.1.1*:0= )
-"
-DEPEND="
-	${RDEPEND}
-	${PYTHON_DEPS}
-	systemtap? ( dev-util/systemtap )
-	test? ( net-misc/curl )
-"
-PATCHES=(
-	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
-	"${FILESDIR}"/${PN}-11.4.0-stdarg_h.patch
-	"${FILESDIR}"/${PN}-99999999-llhttp.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."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python2'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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 deps/v8/gypfiles/toolchain.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() {
-	local myconf=(
-		--shared-cares --shared-http-parser --shared-libuv --shared-nghttp2
-		--shared-zlib
-	)
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none )
-	use inspector || myconf+=( --without-inspector )
-	use npm || myconf+=( --without-npm )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl && myconf+=( --shared-openssl ) || myconf+=( --without-ssl )
-
-	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" \
-	"${PYTHON}" configure \
-		--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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs
-		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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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>"
-}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2019-10-11 14:53 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2019-10-11 14:53 UTC (permalink / raw
  To: gentoo-commits

commit:     f92f76eed69b8a806ffffa3ee09e8d2d2a25c905
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Fri Oct 11 14:39:55 2019 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Fri Oct 11 14:53:08 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f92f76ee

net-libs/nodejs: Old

Support for the 6.x.x branch ended in April 2019.

https://github.com/nodejs/node/blob/master/doc/changelogs/CHANGELOG_V6.md#6.17.1

Package-Manager: Portage-2.3.76, Repoman-2.3.17
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   2 -
 .../nodejs/files/gentoo-global-npm-config.patch    |  40 -----
 net-libs/nodejs/nodejs-6.14.4.ebuild               | 196 --------------------
 net-libs/nodejs/nodejs-6.17.1.ebuild               | 199 ---------------------
 4 files changed, 437 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 664dcf5b68b..69dff6cece8 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,8 +1,6 @@
 DIST node-v10.16.3.tar.xz 21505540 BLAKE2B 2ae6c3ce96a42cb72a388ca7727affb1e2eae06b997098bd8cad2b339b888f1f188c868d39631c51e10ef7b3a5a9173a3b016afe9fa7a4fb74c24a584781c329 SHA512 5d5457adaae87e41699cdf5bd62d32e9590248f7dadd583614cca9078a1749a4ee477433ebbe4278ec872fdfc377d99097c1e06073e0fd47c8c6597256ccdeb7
 DIST node-v12.10.0.tar.xz 22726116 BLAKE2B deb6ecaec54233050eaeb335d58020b8a82009bbab51c41c00784cab3003e57dbc96f3c25715deefbb5b3aee704b3db920cbb650af33cbcb1a62c1bb654f48f8 SHA512 7eb57b40effa9627b93c74ddc01ce1c044e878c669969c506ed40f72a7946c7c6951931c4fe4fbef456386ad459f7f4f1d0f04177e38343375aa463974ca1dba
 DIST node-v12.11.1.tar.xz 22852156 BLAKE2B 38205c3ad52ccac2656c72b31c5714268e4771375b13d7c113e4a5fe7e9530d2826c43aeaa3ed3e30210f504d37221f90f3fb2a15f4c5fbca8878d0f2639b9fa SHA512 9567ee592ea8a05f899755d5e1c934413532676c78a663a1a861a6fa882c7eecae411c05c4b034191b7266776341609c098fbccfcd93c93eba7b84d138eeffb9
-DIST node-v6.14.4.tar.xz 15842824 BLAKE2B fc56364be64fe5824e2bb50d861ebf8f58f9895f2c9c108b8df3315b127ffb2755eac85c28165ac9779adab4611ce8f5ea1a5745f43ebaa1389e82b8215c6396 SHA512 1ead0c097ec125230dd631f19a5c3ec06a1371f9ca3b392b5ad08fcc227dd0142f33ad52f96890c2c17448a4951a635b9099dfff00d7d8b3ffb59b07904d1bfa
-DIST node-v6.17.1.tar.xz 15858444 BLAKE2B ad050f71452f0ddf989e66a4eb02e88e4e5001faa2bcb0eae6b57784da87ba1d8251201e3a3d15245bb4d846f31f39854ddfae47aa1212c0526ec717438ba778 SHA512 6938c4864a96f5698ebc4e9a1228644820789d5402f42348eb1ff9ccd64f31bb91309a1f3301636b1117424c88b0b41b42baae51a1070d5c532604e5d7d7b868
 DIST node-v8.12.0.tar.xz 18310452 BLAKE2B 79634fc57cd76a97e72bab4be37da91d5eff4d13cdaa2b48e83f013885fa3590ba4a28378baf036ed26b7304bf234753d1d4014f72571496f5bb6cd5b221e5f0 SHA512 665d2dba287d78bcd723d7b4d00a6897fb996f4aa69a541e010a3dfeb2614257892117fcce7123966b1ecaddc9269a6667e0e262df693baea1f476c96de55c42
 DIST node-v8.16.1.tar.xz 18519480 BLAKE2B a721ea5118e6e97ce36245367d33fb2eab8a9b4fba72f59f1a65dfc79de394a235a579fa789e8676d2897a928444db11e7792e7fe49c59bf17ac4cc1cac63941 SHA512 7d2d7c063934227e5204b2912de45ed1667d5c35573322192393bdac623491559ccd9fa8fbf05828bd2bb8e3aeb03d82804775cccb1139b48298758defe92be3
 DIST node-v8.16.2.tar.xz 18531368 BLAKE2B aec2f6257ab9237097e590b70b2e8615b664576b3af2f176260f26460f4f50bb1e00c2aff477a32cdb9ebf83f8b4eadc3ccdc2df431e359904fe4375513fb6c1 SHA512 8b0d4a089a5c80869971ceeffbef3ca03f4de4f53452a9fd16cbd189e5d76c7fdef475c144848c8d657256b41e342c020e11f6acd1880dde92ed0d0e8cf9e600

diff --git a/net-libs/nodejs/files/gentoo-global-npm-config.patch b/net-libs/nodejs/files/gentoo-global-npm-config.patch
deleted file mode 100644
index e7346b82685..00000000000
--- a/net-libs/nodejs/files/gentoo-global-npm-config.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-commit 46ac7cd4229eac5e0182ab62b7ed844c24a8c52e
-Author: Johan Bergström <bugs@bergstroem.nu>
-Date:   Wed Feb 10 22:45:59 2016 +1100
-
-    npm: set global config folder to /etc/npm
-    
-    npm previously assumed that the global config path would be
-    based on $prefix/etc. Since gentoo installs nodejs into /usr,
-    this means we're also creating /usr/etc which is less desirable.
-    
-    This patch will likely never go upstream.
-
-diff --git a/deps/npm/lib/config/core.js b/deps/npm/lib/config/core.js
-index d1306eb..bd2ef89 100644
---- a/deps/npm/lib/config/core.js
-+++ b/deps/npm/lib/config/core.js
-@@ -150,16 +150,14 @@ function load_ (builtin, rc, cli, cb) {
-     // Eg, `npm config get globalconfig --prefix ~/local` should
-     // return `~/local/etc/npmrc`
-     // annoying humans and their expectations!
--    if (conf.get('prefix')) {
--      var etc = path.resolve(conf.get('prefix'), 'etc')
--      mkdirp(etc, function () {
--        defaults.globalconfig = path.resolve(etc, 'npmrc')
--        defaults.globalignorefile = path.resolve(etc, 'npmignore')
--        afterUserContinuation()
--      })
--    } else {
-+
-+    // gentoo deviates wrt global config; store in /etc/npm
-+    var globalconfig = path.resolve('/etc', 'npm')
-+    mkdirp(globalconfig, function () {
-+      defaults.globalconfig = path.resolve(globalconfig, 'npmrc')
-+      defaults.globalignorefile = path.resolve(globalconfig, 'npmignore')
-       afterUserContinuation()
--    }
-+    })
-   }
- 
-   function afterUserContinuation () {

diff --git a/net-libs/nodejs/nodejs-6.14.4.ebuild b/net-libs/nodejs/nodejs-6.14.4.ebuild
deleted file mode 100644
index 909ebd44dfe..00000000000
--- a/net-libs/nodejs/nodejs-6.14.4.ebuild
+++ /dev/null
@@ -1,196 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-any-r1 toolchain-funcs
-
-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"
-KEYWORDS="amd64 arm ~arm64 x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl test"
-REQUIRED_USE="
-	inspector? ( icu ssl )
-"
-
-RDEPEND="
-	>=dev-libs/libuv-1.16.1:=
-	>=net-libs/http-parser-2.7.0:=
-	sys-libs/zlib
-	icu? ( >=dev-libs/icu-58.2:= )
-	ssl? ( >=dev-libs/openssl-1.0.2n:0=[-bindist] )
-"
-DEPEND="
-	${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )
-"
-S="${WORKDIR}/node-v${PV}"
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.patch
-)
-
-pkg_pretend() {
-	(use x86 && ! use cpu_flags_x86_sse2) && \
-		die "Your CPU doesn't support the required SSE2 instruction."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-libuv --shared-http-parser --shared-zlib )
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu )
-	use inspector || myconf+=( --without-inspector )
-	use npm || myconf+=( --without-npm )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl && myconf+=( --shared-openssl ) || myconf+=( --without-ssl )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}

diff --git a/net-libs/nodejs/nodejs-6.17.1.ebuild b/net-libs/nodejs/nodejs-6.17.1.ebuild
deleted file mode 100644
index 814a80538d1..00000000000
--- a/net-libs/nodejs/nodejs-6.17.1.ebuild
+++ /dev/null
@@ -1,199 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python2_7 )
-PYTHON_REQ_USE="threads"
-
-inherit bash-completion-r1 eutils flag-o-matic pax-utils python-any-r1 toolchain-funcs
-
-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"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl test"
-REQUIRED_USE="
-	inspector? ( icu ssl )
-"
-
-RDEPEND="
-	>=dev-libs/libuv-1.16.1:=
-	>=net-libs/http-parser-2.9.0:=
-	sys-libs/zlib
-	icu? ( >=dev-libs/icu-58.2:= )
-	ssl? ( >=dev-libs/openssl-1.0.2n:0=[-bindist] )
-"
-DEPEND="
-	${RDEPEND}
-	${PYTHON_DEPS}
-	test? ( net-misc/curl )
-"
-PATCHES=(
-	"${FILESDIR}"/gentoo-global-npm-config.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."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
-}
-
-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
-
-	# make sure we use python2.* while using gyp
-	sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
-	sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || 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" \
-		-e 's|share/doc/node/|share/doc/'"${PF}"'/|g' \
-		tools/install.py || die
-	sed -i -e "s/'lib'/'${LIBDIR}'/" lib/module.js || 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
-
-	# 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() {
-	local myarch=""
-	local myconf=( --shared-libuv --shared-http-parser --shared-zlib )
-	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu )
-	use inspector || myconf+=( --without-inspector )
-	use npm || myconf+=( --without-npm )
-	use snapshot && myconf+=( --with-snapshot )
-	use ssl && myconf+=( --shared-openssl ) || myconf+=( --without-ssl )
-
-	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" \
-	"${PYTHON}" configure \
-		--prefix="${EPREFIX}"/usr \
-		--dest-cpu=${myarch} \
-		--without-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)"
-	emake install DESTDIR="${D}"
-	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
-		# Patch docs to make them offline readable
-		for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
-			sed -i '/fonts.googleapis.com/ d' $i;
-		done
-		# Install docs!
-		dohtml -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="$(emktemp)"
-		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
-		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
-
-		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
-}
-
-src_test() {
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	einfo "The global npm config lives in /etc/npm. This deviates slightly"
-	einfo "from upstream which otherwise would have it live in /usr/etc/."
-	einfo ""
-	einfo "Protip: When using node-gyp to install native modules, you can"
-	einfo "avoid having to download extras by doing the following:"
-	einfo "$ node-gyp --nodedir /usr/include/node <command>"
-}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2019-11-27 21:37 Magnus Granberg
  0 siblings, 0 replies; 36+ messages in thread
From: Magnus Granberg @ 2019-11-27 21:37 UTC (permalink / raw
  To: gentoo-commits

commit:     d3b53be221b0288c4eb5155ad52fa8f27bda083d
Author:     Magnus Granberg <zorry <AT> gentoo <DOT> org>
AuthorDate: Wed Nov 27 21:28:02 2019 +0000
Commit:     Magnus Granberg <zorry <AT> gentoo <DOT> org>
CommitDate: Wed Nov 27 21:29:14 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d3b53be2

net-libs/nodejs: Fix build on PAX enable kernel (bug 694100)

We need to disable mprotect on two bins when we compile
bug 694100.

Closes: https://bugs.gentoo.org/694100
Reported-by: Attila Tóth <atoth <AT> atoth.sote.hu>
Co-developed-by: Attila Tóth <atoth <AT> atoth.sote.hu>
Signed-off-by: Magnus Granberg <zorry <AT> gentoo.org>
Package-Manager: Portage-2.3.76, Repoman-2.3.16

 .../nodejs/files/nodejs-13.2.0-paxmarking.patch    | 71 ++++++++++++++++++++++
 net-libs/nodejs/metadata.xml                       |  1 +
 net-libs/nodejs/nodejs-13.2.0.ebuild               |  8 ++-
 net-libs/nodejs/nodejs-99999999.ebuild             |  8 ++-
 4 files changed, 82 insertions(+), 6 deletions(-)

diff --git a/net-libs/nodejs/files/nodejs-13.2.0-paxmarking.patch b/net-libs/nodejs/files/nodejs-13.2.0-paxmarking.patch
new file mode 100644
index 00000000000..143e4166272
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-13.2.0-paxmarking.patch
@@ -0,0 +1,71 @@
+    Bug: 694100
+    Add actions for pax marking mkcodecache and node_mksnapshot
+    to disable mprotect for pax enable kernel.
+    Reported-by: Attila Tóth <atoth@atoth.sote.hu>
+    Co-developed-by: Attila Tóth <atoth@atoth.sote.hu>
+    Signed-off-by: Magnus Granberg <zorry@gentoo.org>
+    
+--- a/node.gyp	2019-10-23 11:52:41.000000000 +0200
++++ a/node.gyp	2019-11-12 20:58:43.957881862 +0100
+@@ -233,7 +233,9 @@
+       'deps/acorn-plugins/acorn-static-class-features/index.js',
+     ],
+     'node_mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot<(EXECUTABLE_SUFFIX)',
++    'node_mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'mkcodecache_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache<(EXECUTABLE_SUFFIX)',
++    'mkcodecache_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache_u<(EXECUTABLE_SUFFIX)',
+     'conditions': [
+       [ 'node_shared=="true"', {
+         'node_target_type%': 'shared_library',
+@@ -436,10 +438,24 @@
+           ],
+           'actions': [
+             {
++              'action_name': 'run_pax_mkcodecache',
++              'inputs': [
++                '<(mkcodecache_exec)',
++              ],
++              'outputs': [
++                '<(mkcodecache_u_exec)',
++              ],
++              'action': [
++                'bash',
++                '-c',
++                'mv <(mkcodecache_exec) <(mkcodecache_u_exec) && paxmark.sh m <(mkcodecache_u_exec)',
++              ],
++            },
++            {
+               'action_name': 'run_mkcodecache',
+               'process_outputs_as_sources': 1,
+               'inputs': [
+-                '<(mkcodecache_exec)',
++                '<(mkcodecache_u_exec)',
+               ],
+               'outputs': [
+                 '<(SHARED_INTERMEDIATE_DIR)/node_code_cache.cc',
+@@ -461,10 +477,24 @@
+           ],
+           'actions': [
+             {
++              'action_name': 'run_pax_mksnapshot',
++              'inputs': [
++                '<(node_mksnapshot_exec)',
++              ],
++              'outputs': [
++                '<(node_mksnapshot_u_exec)',
++              ],
++              'action': [
++                'bash',
++                '-c',
++                'mv <(node_mksnapshot_exec) <(node_mksnapshot_u_exec) && paxmark.sh m <(node_mksnapshot_u_exec)',
++              ],
++            },
++            {
+               'action_name': 'node_mksnapshot',
+               'process_outputs_as_sources': 1,
+               'inputs': [
+-                '<(node_mksnapshot_exec)',
++                '<(node_mksnapshot_u_exec)',
+               ],
+               'outputs': [
+                 '<(SHARED_INTERMEDIATE_DIR)/node_snapshot.cc',

diff --git a/net-libs/nodejs/metadata.xml b/net-libs/nodejs/metadata.xml
index aaaba184187..3f344f0d8ed 100644
--- a/net-libs/nodejs/metadata.xml
+++ b/net-libs/nodejs/metadata.xml
@@ -7,6 +7,7 @@
 	<use>
 		<flag name="inspector">Enable V8 inspector</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>
 		<flag name="systemtap">Enable SystemTAP/DTrace tracing</flag>
 	</use>

diff --git a/net-libs/nodejs/nodejs-13.2.0.ebuild b/net-libs/nodejs/nodejs-13.2.0.ebuild
index 56bbeb5526f..8013ab7c39a 100644
--- a/net-libs/nodejs/nodejs-13.2.0.ebuild
+++ b/net-libs/nodejs/nodejs-13.2.0.ebuild
@@ -15,7 +15,7 @@ SRC_URI="
 LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
 SLOT="0"
 KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl systemtap test"
+IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm pax_kernel +snapshot +ssl systemtap test"
 REQUIRED_USE="
 	inspector? ( icu ssl )
 	npm? ( ssl )
@@ -33,6 +33,7 @@ BDEPEND="
 	${PYTHON_DEPS}
 	systemtap? ( dev-util/systemtap )
 	test? ( net-misc/curl )
+	pax_kernel? ( sys-apps/elfix )
 "
 DEPEND="
 	${RDEPEND}
@@ -86,6 +87,9 @@ src_prepare() {
 		BUILDTYPE=Debug
 	fi
 
+	# We need to disable mprotect on two files when it builds Bug 694100.
+	use pax_kernel && PATCHES+=( "${FILESDIR}"/${PN}-13.2.0-paxmarking.patch )
+
 	default
 }
 
@@ -124,8 +128,6 @@ src_configure() {
 }
 
 src_compile() {
-	emake -C out mksnapshot
-	pax-mark m "out/${BUILDTYPE}/mksnapshot"
 	emake -C out
 }
 

diff --git a/net-libs/nodejs/nodejs-99999999.ebuild b/net-libs/nodejs/nodejs-99999999.ebuild
index e36828c990a..96dcccf3770 100644
--- a/net-libs/nodejs/nodejs-99999999.ebuild
+++ b/net-libs/nodejs/nodejs-99999999.ebuild
@@ -13,7 +13,7 @@ EGIT_REPO_URI="https://github.com/nodejs/node"
 LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
 SLOT="0"
 KEYWORDS=""
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl systemtap test"
+IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm pax_kernel +snapshot +ssl systemtap test"
 REQUIRED_USE="
 	inspector? ( icu ssl )
 	npm? ( ssl )
@@ -31,6 +31,7 @@ BDEPEND="
 	${PYTHON_DEPS}
 	systemtap? ( dev-util/systemtap )
 	test? ( net-misc/curl )
+	pax_kernel? ( sys-apps/elfix )
 "
 DEPEND="
 	${RDEPEND}
@@ -82,6 +83,9 @@ src_prepare() {
 		BUILDTYPE=Debug
 	fi
 
+	# We need to disable mprotect on two files when it builds Bug 694100.
+	use pax_kernel && PATCHES+=( "${FILESDIR}"/${PN}-13.2.0-paxmarking.patch )
+
 	default
 }
 
@@ -120,8 +124,6 @@ src_configure() {
 }
 
 src_compile() {
-	emake -C out mksnapshot
-	pax-mark m "out/${BUILDTYPE}/mksnapshot"
 	emake -C out
 }
 


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2020-09-04  7:09 Jeroen Roovers
  0 siblings, 0 replies; 36+ messages in thread
From: Jeroen Roovers @ 2020-09-04  7:09 UTC (permalink / raw
  To: gentoo-commits

commit:     eda2daf31ca9729e117cdf8ada5c3ac90fc20780
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Fri Sep  4 07:03:41 2020 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Fri Sep  4 07:09:38 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=eda2daf3

net-libs/nodejs: Restore some of the 12.x.x branch

Package-Manager: Portage-3.0.5, Repoman-3.0.1
RepoMan-Options: --force
Bug: https://bugs.gentoo.org/726836
Bug: https://bugs.gentoo.org/739340
Closes: https://bugs.gentoo.org/740218
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   2 +
 net-libs/nodejs/files/nodejs-99999999-llhttp.patch |  20 ++
 net-libs/nodejs/nodejs-12.16.1.ebuild              | 213 +++++++++++++++++++++
 net-libs/nodejs/nodejs-12.18.3.ebuild              | 213 +++++++++++++++++++++
 4 files changed, 448 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 04de0ee0ad3..0317e181d16 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,3 +1,5 @@
+DIST node-v12.16.1.tar.xz 23481768 BLAKE2B 29371b952c14907778c064269108f1da5e3818c32773e73090c61edcd07190c418189db6a505987ca71f99bb868880e297de5d2181b9a880774eaaf515985f26 SHA512 fe1e9fabb6fe52e3bc4275b33e6c5e4a761550b04964c0ae7dbef7172f5d415207bb2985751d068e357ce45a0ba414b07c0abd1531ef839b9463e98eeae8f9a4
+DIST node-v12.18.3.tar.xz 23679596 BLAKE2B 496a8fa0f0368634a900c5961b442cb9ef9e0cf7cb0fc974a9e29624fc40077a61bd6371851d5487b9eeeb50ebf6a238e5db5c801fef000c7cb15bd990cadae2 SHA512 a1c72d4664fbead4e63736abe46417b13dcd0581c7c9f8a94ca5c5b2bd782fefabac63e63f824dda6a771c3b5e647749e3156a611dcb100aad11c3f23e17ed5d
 DIST node-v14.2.0.tar.xz 32884616 BLAKE2B 7bcb07cb7623c5e08c20267c320cdf23ad110f124c5ad1f2447ef8b76ab8dc44ed50dab7c5651424d9d3a36f7eeecdf3292b07c02cb2e22c3fbe4ed633c4b842 SHA512 47e5ec0b7a207082d43419a7e0a6ea9242ec43b4d7c2217eb66d0b45e2f4d5cb561b3f6fe35fdc41a8be95c182dc122ba262f696ebd12833596d71b372ec85d2
 DIST node-v14.4.0.tar.xz 33005312 BLAKE2B bc1462d897e24a6b842e6f8146971866c73b54ff5383d76cfc5728a73e2c135d28ced068744174b3fb5af4a6ec05ef1f115ea51c2d65517cbe18e1d733460d04 SHA512 f1a7c788a8a149b942ec2b90a4314baaa5355c381029eda45002728ce7209925c016323b0ec1e0dfe2359fddb24f494df125805d0d266b738a333dcddb3f59c3
 DIST node-v14.8.0.tar.xz 33342288 BLAKE2B 4f8129beb16ece09f14c234395b29bc53e84896fdd9877821a27c80d88a0740d42ea4dcf65a0a5c52a98129262be236207f4c07d81f76cc5e4471f21227083e9 SHA512 ebb20f7163e20e8074dd9cc5d3ee7f3cbc536c55a7753d39c482ea90e9314d8fdfe1a88203be7f250f6d77b9f13da04d32d99770d300c2ab0dfdee3d7582f068

diff --git a/net-libs/nodejs/files/nodejs-99999999-llhttp.patch b/net-libs/nodejs/files/nodejs-99999999-llhttp.patch
new file mode 100644
index 00000000000..1b6eb9fb7fa
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-99999999-llhttp.patch
@@ -0,0 +1,20 @@
+--- a/node.gypi
++++ b/node.gypi
+@@ -169,11 +169,15 @@
+ 
+     [ 'node_shared_http_parser=="false"', {
+       'dependencies': [
+-        'deps/http_parser/http_parser.gyp:http_parser',
+-        'deps/llhttp/llhttp.gyp:llhttp'
++        'deps/http_parser/http_parser.gyp:http_parser'
+       ],
+     } ],
+ 
++    [ '"true"', { 'dependencies': [
++        'deps/llhttp/llhttp.gyp:llhttp'
++      ],
++    }],
++
+     [ 'node_shared_cares=="false"', {
+       'dependencies': [ 'deps/cares/cares.gyp:cares' ],
+     }],

diff --git a/net-libs/nodejs/nodejs-12.16.1.ebuild b/net-libs/nodejs/nodejs-12.16.1.ebuild
new file mode 100644
index 00000000000..29723942409
--- /dev/null
+++ b/net-libs/nodejs/nodejs-12.16.1.ebuild
@@ -0,0 +1,213 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+PYTHON_COMPAT=( python3_{6,7} )
+PYTHON_REQ_USE="threads(+)"
+inherit bash-completion-r1 eutils 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"
+KEYWORDS="amd64 arm arm64 ~ppc ~ppc64 x86 ~amd64-linux ~x64-macos"
+IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl +system-ssl systemtap test"
+REQUIRED_USE="
+	inspector? ( icu ssl )
+	npm? ( ssl )
+	system-ssl? ( ssl )
+"
+
+RDEPEND="
+	>=dev-libs/libuv-1.34.0:=
+	>=net-dns/c-ares-1.15.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}
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )
+"
+DEPEND="
+	${RDEPEND}
+"
+PATCHES=(
+	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.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."
+
+	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
+		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
+}
+
+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
+
+	local myconf=(
+		--shared-cares
+		--shared-http-parser
+		--shared-libuv
+		--shared-nghttp2
+		--shared-zlib
+	)
+	use debug && myconf+=( --debug )
+	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="$(emktemp)"
+		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
+		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
+
+		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.18.3.ebuild b/net-libs/nodejs/nodejs-12.18.3.ebuild
new file mode 100644
index 00000000000..6148cf5bb50
--- /dev/null
+++ b/net-libs/nodejs/nodejs-12.18.3.ebuild
@@ -0,0 +1,213 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+PYTHON_COMPAT=( python3_{6,7} )
+PYTHON_REQ_USE="threads(+)"
+inherit bash-completion-r1 eutils 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"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
+IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl +system-ssl systemtap test"
+REQUIRED_USE="
+	inspector? ( icu ssl )
+	npm? ( ssl )
+	system-ssl? ( ssl )
+"
+
+RDEPEND="
+	>=dev-libs/libuv-1.38.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}
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )
+"
+DEPEND="
+	${RDEPEND}
+"
+PATCHES=(
+	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.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."
+
+	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
+		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
+}
+
+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
+
+	local myconf=(
+		--shared-cares
+		--shared-http-parser
+		--shared-libuv
+		--shared-nghttp2
+		--shared-zlib
+	)
+	use debug && myconf+=( --debug )
+	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="$(emktemp)"
+		"${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 "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
+		rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
+
+		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>"
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2020-11-09 15:06 Marek Szuba
  0 siblings, 0 replies; 36+ messages in thread
From: Marek Szuba @ 2020-11-09 15:06 UTC (permalink / raw
  To: gentoo-commits

commit:     1398b77a96625ee50dd430fb4d265b7f793322be
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Mon Nov  9 13:52:36 2020 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Mon Nov  9 15:05:39 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1398b77a

net-libs/nodejs: bump to 14.15.0

Includes subslotting, support for building against bundled ICU, a fix
for PPC64 crashes and python3_9 support.

Closes: https://bugs.gentoo.org/724978
Closes: https://bugs.gentoo.org/728110
Closes: https://bugs.gentoo.org/747100
Closes: https://bugs.gentoo.org/749852
Closes: https://github.com/gentoo/gentoo/pull/17809
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |  2 +-
 .../files/nodejs-14.15.0-fix_ppc64_crashes.patch   | 33 +++++++++++
 net-libs/nodejs/metadata.xml                       |  1 +
 ...nodejs-14.14.0.ebuild => nodejs-14.15.0.ebuild} | 64 ++++++++++------------
 4 files changed, 65 insertions(+), 35 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index f2f49ce2d02..00154d0e2bf 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -4,6 +4,6 @@ DIST node-v14.11.0.tar.xz 33379456 BLAKE2B 99e2eba4ba2e54209836fa1e3b63e42caf854
 DIST node-v14.12.0.tar.xz 33390472 BLAKE2B 930b196ada16d21e2d2b43d030d936391e039cc985ee517b6b420277baa071ecef8c8cef7bd2f24b5e167465e9d4acc6b0da36ae4e7332fe179c47724e05ff50 SHA512 168141a3e3f20be98a0e800a8e8f70e1ff330ff087cc08c31d6ae185882615723166f445d6310a23e1bb5a023e671a74834b40e1b83f2b789f65c787c18762e2
 DIST node-v14.13.0.tar.xz 33418156 BLAKE2B 8a986a467b77485fbe2bc9d580c48ae72536d6d62c826319b787d2937c86358787ae452676b69df608adb9d9754f4cd068b729614989a4f2a93973380c4929d1 SHA512 7a75bff501520afbe15d6ceea4b4507717111c87cf03de47047af790df2e2e9d71da9501c7256d5dd9f58616c3d04db2e74401dfbcbd72abbd0c81778a588893
 DIST node-v14.13.1.tar.xz 33428732 BLAKE2B f3a7349ea4a13b47a66272b74fb7273d6071c35d7d047b147da13d5fd97a912a0770047ceed4d298f0999b9cab57aee81aaac44a6ffec59df1ee1d2ec9156e7b SHA512 a0ad1e6e4be887d56388d0cbe30d72e87fefdaa71be8fe8c96e3dce470821730741b7beff23c67277ab02991aa9813e9fb708b6b708a2cf108c5442a59d527a0
-DIST node-v14.14.0.tar.xz 33439920 BLAKE2B 6cea7fdb00cc0857d5dc46dbd83dc6387ef8a7561afd8616dfc37bf28981faa9dffd664b6e38035e13ec9c7720ec13c2499e948d412e8446e7dc39736852f045 SHA512 d5af1fa219297a8779e031bd94755212f002b6655539929f8fa8cd69a9c1c4b824fa0ccfa961b52023b92d2975e4fd2ec44c0fb238efac0b1a6e2bdfd2b7cff7
+DIST node-v14.15.0.tar.xz 33440584 BLAKE2B dda9fb44f163b2268db126dfcda34e80064eba24921e4f8e6c14c212deb9170c79f31f7b2be272c8fa7ca992d14540df490c6cad078833514bd348825934ad95 SHA512 2a0cd1b9d95e0ac228a90aca82cb04b9f4fc4d08ab86f0286eed7a519ca6e756081b37375ad5d14d7f0e09affdd27bad658c3e364237eb3c212fe5b5e27af96e
 DIST node-v14.2.0.tar.xz 32884616 BLAKE2B 7bcb07cb7623c5e08c20267c320cdf23ad110f124c5ad1f2447ef8b76ab8dc44ed50dab7c5651424d9d3a36f7eeecdf3292b07c02cb2e22c3fbe4ed633c4b842 SHA512 47e5ec0b7a207082d43419a7e0a6ea9242ec43b4d7c2217eb66d0b45e2f4d5cb561b3f6fe35fdc41a8be95c182dc122ba262f696ebd12833596d71b372ec85d2
 DIST node-v14.4.0.tar.xz 33005312 BLAKE2B bc1462d897e24a6b842e6f8146971866c73b54ff5383d76cfc5728a73e2c135d28ced068744174b3fb5af4a6ec05ef1f115ea51c2d65517cbe18e1d733460d04 SHA512 f1a7c788a8a149b942ec2b90a4314baaa5355c381029eda45002728ce7209925c016323b0ec1e0dfe2359fddb24f494df125805d0d266b738a333dcddb3f59c3

diff --git a/net-libs/nodejs/files/nodejs-14.15.0-fix_ppc64_crashes.patch b/net-libs/nodejs/files/nodejs-14.15.0-fix_ppc64_crashes.patch
new file mode 100644
index 00000000000..c9c01843cd6
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-14.15.0-fix_ppc64_crashes.patch
@@ -0,0 +1,33 @@
+--- a/deps/v8/src/compiler/backend/instruction-selector.cc
++++ b/deps/v8/src/compiler/backend/instruction-selector.cc
+@@ -2808,7 +2808,7 @@
+   switch (call_descriptor->kind()) {
+     case CallDescriptor::kCallAddress: {
+       int misc_field = static_cast<int>(call_descriptor->ParameterCount());
+-#if defined(_AIX)
++#if ABI_USES_FUNCTION_DESCRIPTORS
+       // Highest misc_field bit is used on AIX to indicate if a CFunction call
+       // has function descriptor or not.
+       if (!call_descriptor->NoFunctionDescriptor()) {
+--- a/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
++++ b/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
+@@ -1039,7 +1039,7 @@
+           linkage()->GetIncomingDescriptor()->IsWasmCapiFunction();
+       int offset = (FLAG_enable_embedded_constant_pool ? 20 : 23) * kInstrSize;
+ 
+-#if defined(_AIX)
++#if ABI_USES_FUNCTION_DESCRIPTORS
+       // AIX/PPC64BE Linux uses a function descriptor
+       int kNumParametersMask = kHasFunctionDescriptorBitMask - 1;
+       num_parameters = kNumParametersMask & misc_field;
+--- a/deps/v8/src/execution/simulator.h
++++ b/deps/v8/src/execution/simulator.h
+@@ -128,7 +128,7 @@
+ #if defined(V8_TARGET_OS_WIN) && !defined(V8_OS_WIN)
+     FATAL("Generated code execution not possible during cross-compilation.");
+ #endif  // defined(V8_TARGET_OS_WIN) && !defined(V8_OS_WIN)
+-#if V8_OS_AIX
++#if ABI_USES_FUNCTION_DESCRIPTORS
+     // AIX ABI requires function descriptors (FD).  Artificially create a pseudo
+     // FD to ensure correct dispatch to generated code.  The 'volatile'
+     // declaration is required to avoid the compiler from not observing the

diff --git a/net-libs/nodejs/metadata.xml b/net-libs/nodejs/metadata.xml
index 0c48f58c533..c23cc81d8e4 100644
--- a/net-libs/nodejs/metadata.xml
+++ b/net-libs/nodejs/metadata.xml
@@ -11,6 +11,7 @@
 		<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>
+		<flag name="system-icu">Use system <pkg>dev-libs/icu</pkg> instead of the bundled version</flag>
 		<flag name="system-ssl">Use system OpenSSL instead of the bundled one</flag>
 		<flag name="systemtap">Enable SystemTAP/DTrace tracing</flag>
 	</use>

diff --git a/net-libs/nodejs/nodejs-14.14.0.ebuild b/net-libs/nodejs/nodejs-14.15.0.ebuild
similarity index 83%
rename from net-libs/nodejs/nodejs-14.14.0.ebuild
rename to net-libs/nodejs/nodejs-14.15.0.ebuild
index f6e7a717189..6c9a27f20e6 100644
--- a/net-libs/nodejs/nodejs-14.14.0.ebuild
+++ b/net-libs/nodejs/nodejs-14.15.0.ebuild
@@ -2,57 +2,52 @@
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
-PYTHON_COMPAT=( python3_{6,7,8} )
+
+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
+
+inherit bash-completion-r1 flag-o-matic 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
-"
+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"
+SLOT="0/$(ver_cut 1)"
 KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-IUSE="cpu_flags_x86_sse2 debug doc +icu inspector +npm pax_kernel +snapshot +ssl +system-ssl systemtap test"
-REQUIRED_USE="
-	inspector? ( icu ssl )
+
+IUSE="cpu_flags_x86_sse2 debug doc +icu inspector +npm +snapshot +ssl system-icu +system-ssl systemtap test"
+REQUIRED_USE="inspector? ( icu ssl )
 	npm? ( ssl )
-	system-ssl? ( ssl )
-"
+	system-icu? ( icu )
+	system-ssl? ( ssl )"
 
-RDEPEND="
-	>=app-arch/brotli-1.0.9
+# 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
-	icu? ( >=dev-libs/icu-67:= )
-	system-ssl? ( >=dev-libs/openssl-1.1.1:0= )
-"
-BDEPEND="
-	${PYTHON_DEPS}
+	system-icu? ( >=dev-libs/icu-67:= )
+	system-ssl? ( >=dev-libs/openssl-1.1.1:0= )"
+BDEPEND="${PYTHON_DEPS}
 	sys-apps/coreutils
 	systemtap? ( dev-util/systemtap )
-	test? ( net-misc/curl )
-	pax_kernel? ( sys-apps/elfix )
-"
-DEPEND="
-	${RDEPEND}
-"
+	test? ( net-misc/curl )"
+DEPEND="${RDEPEND}"
+
 PATCHES=(
 	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
+	"${FILESDIR}"/${PN}-14.15.0-fix_ppc64_crashes.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."
-
-	( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
-		die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
 }
 
 src_prepare() {
@@ -90,9 +85,6 @@ src_prepare() {
 		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
 }
 
@@ -107,7 +99,13 @@ src_configure() {
 		--shared-zlib
 	)
 	use debug && myconf+=( --debug )
-	use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none )
+	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 )
@@ -146,8 +144,6 @@ 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


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2020-11-13 17:25 Marek Szuba
  0 siblings, 0 replies; 36+ messages in thread
From: Marek Szuba @ 2020-11-13 17:25 UTC (permalink / raw
  To: gentoo-commits

commit:     19add7ba6500e6c60c8699b6bdda397744dfa73b
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Fri Nov 13 14:51:49 2020 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Fri Nov 13 17:25:03 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=19add7ba

net-libs/nodejs: drop PaX support altogether

Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 .../nodejs/files/nodejs-13.2.0-paxmarking.patch    |  71 -------------
 .../nodejs/files/nodejs-13.8.0-paxmarking.patch    | 111 ---------------------
 net-libs/nodejs/metadata.xml                       |   1 -
 net-libs/nodejs/nodejs-12.18.4-r1.ebuild           |   5 +-
 net-libs/nodejs/nodejs-14.2.0.ebuild               |  10 +-
 net-libs/nodejs/nodejs-99999999.ebuild             |  10 +-
 6 files changed, 5 insertions(+), 203 deletions(-)

diff --git a/net-libs/nodejs/files/nodejs-13.2.0-paxmarking.patch b/net-libs/nodejs/files/nodejs-13.2.0-paxmarking.patch
deleted file mode 100644
index 143e4166272..00000000000
--- a/net-libs/nodejs/files/nodejs-13.2.0-paxmarking.patch
+++ /dev/null
@@ -1,71 +0,0 @@
-    Bug: 694100
-    Add actions for pax marking mkcodecache and node_mksnapshot
-    to disable mprotect for pax enable kernel.
-    Reported-by: Attila Tóth <atoth@atoth.sote.hu>
-    Co-developed-by: Attila Tóth <atoth@atoth.sote.hu>
-    Signed-off-by: Magnus Granberg <zorry@gentoo.org>
-    
---- a/node.gyp	2019-10-23 11:52:41.000000000 +0200
-+++ a/node.gyp	2019-11-12 20:58:43.957881862 +0100
-@@ -233,7 +233,9 @@
-       'deps/acorn-plugins/acorn-static-class-features/index.js',
-     ],
-     'node_mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot<(EXECUTABLE_SUFFIX)',
-+    'node_mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot_u<(EXECUTABLE_SUFFIX)',
-     'mkcodecache_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache<(EXECUTABLE_SUFFIX)',
-+    'mkcodecache_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache_u<(EXECUTABLE_SUFFIX)',
-     'conditions': [
-       [ 'node_shared=="true"', {
-         'node_target_type%': 'shared_library',
-@@ -436,10 +438,24 @@
-           ],
-           'actions': [
-             {
-+              'action_name': 'run_pax_mkcodecache',
-+              'inputs': [
-+                '<(mkcodecache_exec)',
-+              ],
-+              'outputs': [
-+                '<(mkcodecache_u_exec)',
-+              ],
-+              'action': [
-+                'bash',
-+                '-c',
-+                'mv <(mkcodecache_exec) <(mkcodecache_u_exec) && paxmark.sh m <(mkcodecache_u_exec)',
-+              ],
-+            },
-+            {
-               'action_name': 'run_mkcodecache',
-               'process_outputs_as_sources': 1,
-               'inputs': [
--                '<(mkcodecache_exec)',
-+                '<(mkcodecache_u_exec)',
-               ],
-               'outputs': [
-                 '<(SHARED_INTERMEDIATE_DIR)/node_code_cache.cc',
-@@ -461,10 +477,24 @@
-           ],
-           'actions': [
-             {
-+              'action_name': 'run_pax_mksnapshot',
-+              'inputs': [
-+                '<(node_mksnapshot_exec)',
-+              ],
-+              'outputs': [
-+                '<(node_mksnapshot_u_exec)',
-+              ],
-+              'action': [
-+                'bash',
-+                '-c',
-+                'mv <(node_mksnapshot_exec) <(node_mksnapshot_u_exec) && paxmark.sh m <(node_mksnapshot_u_exec)',
-+              ],
-+            },
-+            {
-               'action_name': 'node_mksnapshot',
-               'process_outputs_as_sources': 1,
-               'inputs': [
--                '<(node_mksnapshot_exec)',
-+                '<(node_mksnapshot_u_exec)',
-               ],
-               'outputs': [
-                 '<(SHARED_INTERMEDIATE_DIR)/node_snapshot.cc',

diff --git a/net-libs/nodejs/files/nodejs-13.8.0-paxmarking.patch b/net-libs/nodejs/files/nodejs-13.8.0-paxmarking.patch
deleted file mode 100644
index c29825df3cf..00000000000
--- a/net-libs/nodejs/files/nodejs-13.8.0-paxmarking.patch
+++ /dev/null
@@ -1,111 +0,0 @@
-    Bug: 694100
-    Add actions for pax marking mkcodecache, node_mksnapshot and mksnapshot
-    to disable mprotect for pax enable kernel.
-    Reported-by: Attila Tóth <atoth@atoth.sote.hu>
-    Co-developed-by: Attila Tóth <atoth@atoth.sote.hu>
-    Signed-off-by: Magnus Granberg <zorry@gentoo.org>
-    
---- a/node.gyp	2019-10-23 11:52:41.000000000 +0200
-+++ b/node.gyp	2019-11-12 20:58:43.957881862 +0100
-@@ -233,7 +233,9 @@
-       'deps/acorn-plugins/acorn-static-class-features/index.js',
-     ],
-     'node_mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot<(EXECUTABLE_SUFFIX)',
-+    'node_mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot_u<(EXECUTABLE_SUFFIX)',
-     'mkcodecache_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache<(EXECUTABLE_SUFFIX)',
-+    'mkcodecache_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache_u<(EXECUTABLE_SUFFIX)',
-     'conditions': [
-       [ 'node_shared=="true"', {
-         'node_target_type%': 'shared_library',
-@@ -436,10 +438,24 @@
-           ],
-           'actions': [
-             {
-+              'action_name': 'run_pax_mkcodecache',
-+              'inputs': [
-+                '<(mkcodecache_exec)',
-+              ],
-+              'outputs': [
-+                '<(mkcodecache_u_exec)',
-+              ],
-+              'action': [
-+                'bash',
-+                '-c',
-+                'mv <(mkcodecache_exec) <(mkcodecache_u_exec) && paxmark.sh m <(mkcodecache_u_exec)',
-+              ],
-+            },
-+            {
-               'action_name': 'run_mkcodecache',
-               'process_outputs_as_sources': 1,
-               'inputs': [
--                '<(mkcodecache_exec)',
-+                '<(mkcodecache_u_exec)',
-               ],
-               'outputs': [
-                 '<(SHARED_INTERMEDIATE_DIR)/node_code_cache.cc',
-@@ -461,10 +477,24 @@
-           ],
-           'actions': [
-             {
-+              'action_name': 'run_pax_mksnapshot',
-+              'inputs': [
-+                '<(node_mksnapshot_exec)',
-+              ],
-+              'outputs': [
-+                '<(node_mksnapshot_u_exec)',
-+              ],
-+              'action': [
-+                'bash',
-+                '-c',
-+                'mv <(node_mksnapshot_exec) <(node_mksnapshot_u_exec) && paxmark.sh m <(node_mksnapshot_u_exec)',
-+              ],
-+            },
-+            {
-               'action_name': 'node_mksnapshot',
-               'process_outputs_as_sources': 1,
-               'inputs': [
--                '<(node_mksnapshot_exec)',
-+                '<(node_mksnapshot_u_exec)',
-               ],
-               'outputs': [
-                 '<(SHARED_INTERMEDIATE_DIR)/node_snapshot.cc',
---- a/tools/v8_gypfiles/v8.gyp	2019-12-03 16:10:36.000000000 +0100
-+++ b/tools/v8_gypfiles/v8.gyp	2019-12-17 18:37:33.695839254 +0100
-@@ -9,6 +9,7 @@
-     'v8_vector_stores%': 0,
-     'v8_embed_script%': "",
-     'mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
-+    'mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot_u<(EXECUTABLE_SUFFIX)',
-     'v8_os_page_size%': 0,
-     'generate_bytecode_output_root': '<(SHARED_INTERMEDIATE_DIR)/generate-bytecode-output-root',
-     'generate_bytecode_builtins_list_output': '<(generate_bytecode_output_root)/builtins-generated/bytecodes-builtins-list.h',
-@@ -427,6 +425,20 @@
-       },
-       'actions': [
-         {
-+          'action_name': 'run_pax_mksnapshot',
-+          'inputs': [
-+            '<(mksnapshot_exec)',
-+          ],
-+          'outputs': [
-+            '<(mksnapshot_u_exec)',
-+          ],
-+          'action': [
-+            'bash',
-+            '-c',
-+            'mv <(mksnapshot_exec) <(mksnapshot_u_exec) && paxmark.sh m <(mksnapshot_u_exec)',
-+          ],
-+        },
-+        {
-           'action_name': 'run_mksnapshot',
-           'message': 'generating: >@(_outputs)',
-           'variables': {
-@@ -442,7 +454,7 @@
-             ],
-           },
-           'inputs': [
--            '<(mksnapshot_exec)',
-+            '<(mksnapshot_u_exec)',
-           ],
-           'outputs': ["<(INTERMEDIATE_DIR)/snapshot.cc"],
-           'process_outputs_as_sources': 1,

diff --git a/net-libs/nodejs/metadata.xml b/net-libs/nodejs/metadata.xml
index ff595099c9d..1f2cfaf97be 100644
--- a/net-libs/nodejs/metadata.xml
+++ b/net-libs/nodejs/metadata.xml
@@ -13,7 +13,6 @@
 	<use>
 		<flag name="inspector">Enable V8 inspector</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>
 		<flag name="system-icu">Use system <pkg>dev-libs/icu</pkg> instead of the bundled version</flag>
 		<flag name="system-ssl">Use system OpenSSL instead of the bundled one</flag>

diff --git a/net-libs/nodejs/nodejs-12.18.4-r1.ebuild b/net-libs/nodejs/nodejs-12.18.4-r1.ebuild
index c606807087a..bbdc7bd8dd9 100644
--- a/net-libs/nodejs/nodejs-12.18.4-r1.ebuild
+++ b/net-libs/nodejs/nodejs-12.18.4-r1.ebuild
@@ -4,7 +4,7 @@
 EAPI=7
 PYTHON_COMPAT=( python3_{6,7} )
 PYTHON_REQ_USE="threads(+)"
-inherit bash-completion-r1 flag-o-matic pax-utils python-any-r1 toolchain-funcs xdg-utils
+inherit bash-completion-r1 flag-o-matic python-any-r1 toolchain-funcs xdg-utils
 
 DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine"
 HOMEPAGE="https://nodejs.org/"
@@ -139,7 +139,6 @@ src_configure() {
 
 src_compile() {
 	emake -C out mksnapshot
-	pax-mark m "out/${BUILDTYPE}/mksnapshot"
 	emake -C out
 }
 
@@ -147,8 +146,6 @@ 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

diff --git a/net-libs/nodejs/nodejs-14.2.0.ebuild b/net-libs/nodejs/nodejs-14.2.0.ebuild
index 47e27f90889..4b3509f8db3 100644
--- a/net-libs/nodejs/nodejs-14.2.0.ebuild
+++ b/net-libs/nodejs/nodejs-14.2.0.ebuild
@@ -4,7 +4,7 @@
 EAPI=7
 PYTHON_COMPAT=( python3_{6,7,8} )
 PYTHON_REQ_USE="threads(+)"
-inherit bash-completion-r1 flag-o-matic pax-utils python-any-r1 toolchain-funcs xdg-utils
+inherit bash-completion-r1 flag-o-matic python-any-r1 toolchain-funcs xdg-utils
 
 DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine"
 HOMEPAGE="https://nodejs.org/"
@@ -15,7 +15,7 @@ SRC_URI="
 LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
 SLOT="0"
 KEYWORDS="ppc"
-IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm pax_kernel +snapshot +ssl +system-ssl systemtap test"
+IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl +system-ssl systemtap test"
 REQUIRED_USE="
 	inspector? ( icu ssl )
 	npm? ( ssl )
@@ -35,7 +35,6 @@ BDEPEND="
 	sys-apps/coreutils
 	systemtap? ( dev-util/systemtap )
 	test? ( net-misc/curl )
-	pax_kernel? ( sys-apps/elfix )
 "
 DEPEND="
 	${RDEPEND}
@@ -89,9 +88,6 @@ src_prepare() {
 		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
 }
 
@@ -141,8 +137,6 @@ 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

diff --git a/net-libs/nodejs/nodejs-99999999.ebuild b/net-libs/nodejs/nodejs-99999999.ebuild
index e7a2c7c7eb9..65d30862d4c 100644
--- a/net-libs/nodejs/nodejs-99999999.ebuild
+++ b/net-libs/nodejs/nodejs-99999999.ebuild
@@ -4,7 +4,7 @@
 EAPI=7
 PYTHON_COMPAT=( python3_{6,7,8} )
 PYTHON_REQ_USE="threads(+)"
-inherit bash-completion-r1 flag-o-matic git-r3 pax-utils python-any-r1 toolchain-funcs xdg-utils
+inherit bash-completion-r1 flag-o-matic git-r3 python-any-r1 toolchain-funcs xdg-utils
 
 DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine"
 HOMEPAGE="https://nodejs.org/"
@@ -13,7 +13,7 @@ EGIT_REPO_URI="https://github.com/nodejs/node"
 LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
 SLOT="0"
 KEYWORDS=""
-IUSE="cpu_flags_x86_sse2 debug doc +icu inspector +npm pax_kernel +snapshot +ssl +system-ssl systemtap test"
+IUSE="cpu_flags_x86_sse2 debug doc +icu inspector +npm +snapshot +ssl +system-ssl systemtap test"
 RESTRICT="!test? ( test )"
 REQUIRED_USE="
 	inspector? ( icu ssl )
@@ -35,7 +35,6 @@ BDEPEND="
 	sys-apps/coreutils
 	systemtap? ( dev-util/systemtap )
 	test? ( net-misc/curl )
-	pax_kernel? ( sys-apps/elfix )
 "
 DEPEND="
 	${RDEPEND}
@@ -84,9 +83,6 @@ src_prepare() {
 		BUILDTYPE=Debug
 	fi
 
-	# We need to disable mprotect on two files when it builds Bug 694100.
-	use pax_kernel && PATCHES+=( "${FILESDIR}"/${PN}-13.2.0-paxmarking.patch )
-
 	default
 }
 
@@ -140,8 +136,6 @@ 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


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2020-11-21 21:36 Marek Szuba
  0 siblings, 0 replies; 36+ messages in thread
From: Marek Szuba @ 2020-11-21 21:36 UTC (permalink / raw
  To: gentoo-commits

commit:     5d8c279936a29f2455ed9aa85ba735b77530cf7b
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Sat Nov 21 21:32:24 2020 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Sat Nov 21 21:36:23 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5d8c2799

net-libs/nodejs: bump to 15.2.0

No PaX support yet, will be added separately.

Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 +
 .../files/nodejs-15.2.0-global-npm-config.patch    |  13 ++
 net-libs/nodejs/nodejs-15.2.1.ebuild               | 196 +++++++++++++++++++++
 3 files changed, 210 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index b981c6dec8b..87cfe291987 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,3 +1,4 @@
 DIST node-v12.19.1.tar.xz 23829692 BLAKE2B 244ca8ef29e315ce027638d9d5c66469ac8cd69abec47d5bf6370b990da0d9d2a7af812963530e5187d273d3f20638be0d23ccb1c0409fbbd678677740939f4f SHA512 7c628ca214d3b17b34658aae32e335ce863d90853c92f1cd4119e9a82b7097ddf47d0d4cc7c9bbdbfdd4b403811aa6ee08e844078a947f31a3adc78f569b931a
 DIST node-v14.15.0.tar.xz 33440584 BLAKE2B dda9fb44f163b2268db126dfcda34e80064eba24921e4f8e6c14c212deb9170c79f31f7b2be272c8fa7ca992d14540df490c6cad078833514bd348825934ad95 SHA512 2a0cd1b9d95e0ac228a90aca82cb04b9f4fc4d08ab86f0286eed7a519ca6e756081b37375ad5d14d7f0e09affdd27bad658c3e364237eb3c212fe5b5e27af96e
 DIST node-v14.15.1.tar.xz 33437304 BLAKE2B f08251d2a76e4030433001fd7f062c71193de190036d1147ade0ea36350df0d65df9e1b749fbac77837dd090cbeda6c133ff88099691c932bc29e75b7bfa2acc SHA512 cbab757e370a09b73c29a9bcb310b4122e4424d6baeaeaf1b10919ed6b348bc6ddbfc0e0eaff99d8ebb4d3d74f0206f575e2656245151eda564dd2cd33ff823a
+DIST node-v15.2.1.tar.xz 33172472 BLAKE2B d63dbc138ec161253f996fb61c9f40db2eabb5a598804eca7f2446b654ae8a11164820d46ea3c2b41b6a891bb0a3f15fe67712988ed67c1344ab72e2e4749fac SHA512 b05663131d6bb458fe49cf610a7296cdd169b6e957df3e5117ad5553de9891ed4cb71c7d3dc0dbb7774153c884cf245f49faecfa308736086fe6f041f83c8a57

diff --git a/net-libs/nodejs/files/nodejs-15.2.0-global-npm-config.patch b/net-libs/nodejs/files/nodejs-15.2.0-global-npm-config.patch
new file mode 100644
index 00000000000..2b0705b1d71
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-15.2.0-global-npm-config.patch
@@ -0,0 +1,13 @@
+--- a/deps/npm/node_modules/@npmcli/config/lib/index.js
++++ b/deps/npm/node_modules/@npmcli/config/lib/index.js
+@@ -275,8 +275,9 @@
+     // default the globalconfig file to that location, instead of the default
+     // global prefix.  It's weird that `npm get globalconfig --prefix=/foo`
+     // returns `/foo/etc/npmrc`, but better to not change it at this point.
++    // gentoo deviates wrt global config; store in /etc/npm
+     settableGetter(data, 'globalconfig', () =>
+-      resolve(this[_get]('prefix'), 'etc/npmrc'))
++      resolve('/etc', 'npmrc'))
+   }
+ 
+   loadHome () {

diff --git a/net-libs/nodejs/nodejs-15.2.1.ebuild b/net-libs/nodejs/nodejs-15.2.1.ebuild
new file mode 100644
index 00000000000..a69a9626746
--- /dev/null
+++ b/net-libs/nodejs/nodejs-15.2.1.ebuild
@@ -0,0 +1,196 @@
+# Copyright 1999-2020 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 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 +npm +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.17.0
+	>=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
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )"
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.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."
+}
+
+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
+
+	default
+}
+
+src_configure() {
+	xdg_environment_reset
+
+	local myconf=(
+		--shared-brotli
+		--shared-cares
+		--shared-libuv
+		--shared-nghttp2
+		--shared-zlib
+	)
+	use debug && myconf+=( --debug )
+	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
+
+	# 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
+		keepdir /etc/npm
+
+		# Install bash completion for `npm`
+		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
+
+		# Move man pages
+		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
+
+		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
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2021-01-08 22:55 Marek Szuba
  0 siblings, 0 replies; 36+ messages in thread
From: Marek Szuba @ 2021-01-08 22:55 UTC (permalink / raw
  To: gentoo-commits

commit:     cd0cb8e673c0a2609174f456c3145e61ec408791
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Fri Jan  8 22:53:40 2021 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Fri Jan  8 22:53:40 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cd0cb8e6

net-libs/nodejs-12.20.1: fix mksnapshot segfaults on ppc64

Upstream regression?

Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 .../files/nodejs-12.20.1-fix_ppc64_crashes.patch   | 44 ++++++++++++++++++++++
 net-libs/nodejs/nodejs-12.20.1.ebuild              |  1 +
 2 files changed, 45 insertions(+)

diff --git a/net-libs/nodejs/files/nodejs-12.20.1-fix_ppc64_crashes.patch b/net-libs/nodejs/files/nodejs-12.20.1-fix_ppc64_crashes.patch
new file mode 100644
index 00000000000..0982d3c81c2
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-12.20.1-fix_ppc64_crashes.patch
@@ -0,0 +1,44 @@
+Backport of https://github.com/nodejs/node/pull/33866 to nodejs-12
+
+--- a/deps/v8/src/compiler/backend/instruction-selector.cc
++++ b/deps/v8/src/compiler/backend/instruction-selector.cc
+@@ -2788,7 +2788,7 @@
+   switch (call_descriptor->kind()) {
+     case CallDescriptor::kCallAddress: {
+       int misc_field = static_cast<int>(call_descriptor->ParameterCount());
+-#if defined(_AIX)
++#if ABI_USES_FUNCTION_DESCRIPTORS
+       // Highest misc_field bit is used on AIX to indicate if a CFunction call
+       // has function descriptor or not.
+       misc_field |= call_descriptor->HasFunctionDescriptor()
+--- a/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
++++ b/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
+@@ -1026,7 +1026,7 @@
+       Label start_call;
+       bool isWasmCapiFunction =
+           linkage()->GetIncomingDescriptor()->IsWasmCapiFunction();
+-#if defined(_AIX)
++#if ABI_USES_FUNCTION_DESCRIPTORS
+       // AIX/PPC64BE Linux uses a function descriptor
+       int kNumParametersMask = kHasFunctionDescriptorBitMask - 1;
+       num_parameters = kNumParametersMask & misc_field;
+--- a/deps/v8/src/execution/simulator.h
++++ b/deps/v8/src/execution/simulator.h
+@@ -122,7 +122,7 @@
+ 
+   DISABLE_CFI_ICALL Return Call(Args... args) {
+     // When running without a simulator we call the entry directly.
+-#if V8_OS_AIX
++#if ABI_USES_FUNCTION_DESCRIPTORS
+     // AIX ABI requires function descriptors (FD).  Artificially create a pseudo
+     // FD to ensure correct dispatch to generated code.  The 'volatile'
+     // declaration is required to avoid the compiler from not observing the
+@@ -134,7 +134,7 @@
+     return fn(args...);
+ #else
+     return fn_ptr_(args...);
+-#endif  // V8_OS_AIX
++#endif  // ABI_USES_FUNCTION_DESCRIPTORS
+   }
+ #endif  // USE_SIMULATOR
+ 

diff --git a/net-libs/nodejs/nodejs-12.20.1.ebuild b/net-libs/nodejs/nodejs-12.20.1.ebuild
index 87b53e063d2..fc8227e01db 100644
--- a/net-libs/nodejs/nodejs-12.20.1.ebuild
+++ b/net-libs/nodejs/nodejs-12.20.1.ebuild
@@ -45,6 +45,7 @@ DEPEND="
 "
 PATCHES=(
 	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
+	"${FILESDIR}"/${PN}-12.20.1-fix_ppc64_crashes.patch
 	"${FILESDIR}"/${PN}-99999999-llhttp.patch
 )
 RESTRICT="test"


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2021-05-04 15:42 Marek Szuba
  0 siblings, 0 replies; 36+ messages in thread
From: Marek Szuba @ 2021-05-04 15:42 UTC (permalink / raw
  To: gentoo-commits

commit:     d2aae48cbb242fae42837df1fba82b3aaf70139a
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Tue May  4 15:37:14 2021 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Tue May  4 15:41:57 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d2aae48c

net-libs/nodejs: really link against system libuv

Turns out the bundled library "uvwasi" implicitly pulled in the bundled
libuv as a static library regardless of us having been passing
--shared-libuv to configure.py pretty much for ever. Fortunately,
patching the relevant lines out of the uvwasi gyp file seems to take
care of the problem.

Closes: https://bugs.gentoo.org/787251
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 .../nodejs/files/nodejs-12.22.1-uvwasi_shared_libuv.patch    | 12 ++++++++++++
 net-libs/nodejs/nodejs-12.22.1-r1.ebuild                     |  1 +
 net-libs/nodejs/nodejs-14.16.1-r1.ebuild                     |  1 +
 net-libs/nodejs/nodejs-16.0.0-r1.ebuild                      |  1 +
 4 files changed, 15 insertions(+)

diff --git a/net-libs/nodejs/files/nodejs-12.22.1-uvwasi_shared_libuv.patch b/net-libs/nodejs/files/nodejs-12.22.1-uvwasi_shared_libuv.patch
new file mode 100644
index 00000000000..eb56bb87d86
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-12.22.1-uvwasi_shared_libuv.patch
@@ -0,0 +1,12 @@
+--- a/deps/uvwasi/uvwasi.gyp
++++ b/deps/uvwasi/uvwasi.gyp
+@@ -18,9 +18,6 @@
+         'src/wasi_rights.c',
+         'src/wasi_serdes.c',
+       ],
+-      'dependencies': [
+-        '../uv/uv.gyp:libuv',
+-      ],
+       'direct_dependent_settings': {
+         'include_dirs': ['include']
+       },

diff --git a/net-libs/nodejs/nodejs-12.22.1-r1.ebuild b/net-libs/nodejs/nodejs-12.22.1-r1.ebuild
index 52bbbaf5862..f96dac1dcb1 100644
--- a/net-libs/nodejs/nodejs-12.22.1-r1.ebuild
+++ b/net-libs/nodejs/nodejs-12.22.1-r1.ebuild
@@ -47,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-uvwasi_shared_libuv.patch
 	"${FILESDIR}"/${PN}-12.22.1-v8_icu69.patch
 	"${FILESDIR}"/${PN}-99999999-llhttp.patch
 )

diff --git a/net-libs/nodejs/nodejs-14.16.1-r1.ebuild b/net-libs/nodejs/nodejs-14.16.1-r1.ebuild
index 37454244851..c386c0e45b7 100644
--- a/net-libs/nodejs/nodejs-14.16.1-r1.ebuild
+++ b/net-libs/nodejs/nodejs-14.16.1-r1.ebuild
@@ -41,6 +41,7 @@ DEPEND="${RDEPEND}"
 
 PATCHES=(
 	"${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
+	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
 	"${FILESDIR}"/${PN}-14.15.0-fix_ppc64_crashes.patch
 	"${FILESDIR}"/${PN}-14.16.1-v8_icu69.patch
 )

diff --git a/net-libs/nodejs/nodejs-16.0.0-r1.ebuild b/net-libs/nodejs/nodejs-16.0.0-r1.ebuild
index b9358387895..95528f2021f 100644
--- a/net-libs/nodejs/nodejs-16.0.0-r1.ebuild
+++ b/net-libs/nodejs/nodejs-16.0.0-r1.ebuild
@@ -41,6 +41,7 @@ BDEPEND="${PYTHON_DEPS}
 DEPEND="${RDEPEND}"
 
 PATCHES=(
+	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
 	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
 	"${FILESDIR}"/${PN}-16.0.0-v8_lto.patch
 )


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2021-05-09 14:29 Marek Szuba
  0 siblings, 0 replies; 36+ messages in thread
From: Marek Szuba @ 2021-05-09 14:29 UTC (permalink / raw
  To: gentoo-commits

commit:     a52b28a758d244f86e4609bd5936b7a1023a34d6
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Sun May  9 12:24:29 2021 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Sun May  9 14:28:33 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a52b28a7

net-libs/nodejs-16.1.0: Backport upstream fix for test-repl-history-navigation

Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 ...odejs-16.1.0-test-repl-history-navigation.patch | 56 ++++++++++++++++++++++
 net-libs/nodejs/nodejs-16.1.0.ebuild               |  5 +-
 2 files changed, 57 insertions(+), 4 deletions(-)

diff --git a/net-libs/nodejs/files/nodejs-16.1.0-test-repl-history-navigation.patch b/net-libs/nodejs/files/nodejs-16.1.0-test-repl-history-navigation.patch
new file mode 100644
index 00000000000..724541a870d
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-16.1.0-test-repl-history-navigation.patch
@@ -0,0 +1,56 @@
+From 7c8a60851c459ea18afbfc54bfc8cf7394ea56c3 Mon Sep 17 00:00:00 2001
+From: Antoine du Hamel <duhamelantoine1995@gmail.com>
+Date: Thu, 6 May 2021 12:00:07 +0200
+Subject: [PATCH] test,repl: fix tests when inspector is disabled
+
+Fixes: https://github.com/nodejs/node/issues/38558
+
+PR-URL: https://github.com/nodejs/node/pull/38564
+Reviewed-By: Anna Henningsen <anna@addaleax.net>
+Reviewed-By: James M Snell <jasnell@gmail.com>
+Reviewed-By: Rich Trott <rtrott@gmail.com>
+---
+ test/parallel/test-repl-history-navigation.js | 12 ++++++------
+ 1 file changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/test/parallel/test-repl-history-navigation.js b/test/parallel/test-repl-history-navigation.js
+index df4f0390a69c..527cf235bddd 100644
+--- a/test/parallel/test-repl-history-navigation.js
++++ b/test/parallel/test-repl-history-navigation.js
+@@ -559,14 +559,14 @@ const tests = [
+     env: { NODE_REPL_HISTORY: defaultHistoryPath },
+     test: ['const util = {}', ENTER,
+            'ut', RIGHT, ENTER],
+-    expected: common.hasIntl && common.hasCrypto ? [
++    expected: [
+       prompt, ...'const util = {}',
+       'undefined\n',
+-      prompt, ...'ut', ' // il', '\n// {}',
+-      'il', '\n// {}',
++      prompt, ...'ut', ...(prev ? [' // il', '\n// {}',
++                                   'il', '\n// {}'] : [' // il', 'il']),
+       '{}\n',
+       prompt,
+-    ] : [],
++    ],
+     clean: false
+   },
+   {
+@@ -577,7 +577,7 @@ const tests = [
+       'globalThis.util = {}', ENTER,
+       'ut', RIGHT, ENTER,
+       'Reflect.defineProperty(globalThis, "util", utilDesc)', ENTER],
+-    expected: common.hasIntl && common.hasCrypto ? [
++    expected: [
+       prompt, ...'const utilDesc = ' +
+       'Reflect.getOwnPropertyDescriptor(globalThis, "util")',
+       'undefined\n',
+@@ -588,7 +588,7 @@ const tests = [
+       prompt, ...'Reflect.defineProperty(globalThis, "util", utilDesc)',
+       'true\n',
+       prompt,
+-    ] : [],
++    ],
+     clean: false
+   },
+ ];

diff --git a/net-libs/nodejs/nodejs-16.1.0.ebuild b/net-libs/nodejs/nodejs-16.1.0.ebuild
index 61ddcf50edb..f3079de1131 100644
--- a/net-libs/nodejs/nodejs-16.1.0.ebuild
+++ b/net-libs/nodejs/nodejs-16.1.0.ebuild
@@ -42,6 +42,7 @@ DEPEND="${RDEPEND}"
 PATCHES=(
 	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
 	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
+	"${FILESDIR}"/${PN}-16.1.0-test-repl-history-navigation.patch
 )
 
 S="${WORKDIR}/node-v${PV}"
@@ -70,10 +71,6 @@ src_prepare() {
 	export V=1
 	export BUILDTYPE=Release
 
-	# See https://github.com/nodejs/node/issues/38558
-	# FIXME: temporary, until we have figured out why that one single test fails.
-	rm -f test/parallel/test-repl-history-navigation.js
-
 	# 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


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2021-05-09 14:29 Marek Szuba
  0 siblings, 0 replies; 36+ messages in thread
From: Marek Szuba @ 2021-05-09 14:29 UTC (permalink / raw
  To: gentoo-commits

commit:     ae867aad2f1430c812d608eb2a8bdfb1cd7ad1a7
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Sun May  9 12:25:37 2021 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Sun May  9 14:28:36 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ae867aad

net-libs/nodejs: drop 16.0.0-r1

Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 net-libs/nodejs/Manifest                         |   1 -
 net-libs/nodejs/files/nodejs-16.0.0-v8_lto.patch |  39 ----
 net-libs/nodejs/nodejs-16.0.0-r1.ebuild          | 229 -----------------------
 3 files changed, 269 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index c0656482fd6..aec0f6fda87 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,4 +1,3 @@
 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
 DIST node-v16.1.0.tar.xz 33770472 BLAKE2B 2b7cf5f07dbf72eb25018cd046ce15cf6c5a444225e34d425614c19e69888b4f5c9488b079fed12e6fe52cb8dfdee20cf61c4df5a39f53e60b95c4da445f2091 SHA512 dc12078203940e7b280198ae15f51f68aaefcf8cab71a9f988952e67045e4b16dc48ec471abcc497bd15b0b426c06678e376b53762349d6568b48d52888cc2d5

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
deleted file mode 100644
index a3e4acb02c3..00000000000
--- a/net-libs/nodejs/files/nodejs-16.0.0-v8_lto.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-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/nodejs-16.0.0-r1.ebuild b/net-libs/nodejs/nodejs-16.0.0-r1.ebuild
deleted file mode 100644
index 95528f2021f..00000000000
--- a/net-libs/nodejs/nodejs-16.0.0-r1.ebuild
+++ /dev/null
@@ -1,229 +0,0 @@
-# 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 )"
-
-# As of 16.0.0, tests fail because "npm is not ready for this release"
-RESTRICT="test"
-
-RDEPEND=">=app-arch/brotli-1.0.9
-	>=dev-libs/libuv-1.40.0:=
-	>=net-dns/c-ares-1.17.0
-	>=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}-12.22.1-uvwasi_shared_libuv.patch
-	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
-	"${FILESDIR}"/${PN}-16.0.0-v8_lto.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
-			if tc-is-gcc; then
-				if [[ $(gcc-major-version) -ge 11 ]]; then
-					# Bug #787158
-					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
-				fi
-			else
-				# configure.py will abort on this later if we do not
-				die "${PN} only supports LTO for gcc"
-			fi
-		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
-		keepdir /etc/npm
-
-		# Install bash completion for `npm`
-		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
-
-		# 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() {
-	# parallel/test-fs-mkdir is known to fail with FEATURES=usersandbox
-	if has usersandbox ${FEATURES}; then
-		ewarn "You are emerging ${P} with 'usersandbox' enabled." \
-			"Expect some test failures or emerge with 'FEATURES=-usersandbox'!"
-	fi
-
-	out/${BUILDTYPE}/cctest || die
-	"${EPYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
-}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2021-06-04 12:01 Marek Szuba
  0 siblings, 0 replies; 36+ messages in thread
From: Marek Szuba @ 2021-06-04 12:01 UTC (permalink / raw
  To: gentoo-commits

commit:     c696ef464b522cc22961cc0393efeafd64155f0e
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Fri Jun  4 11:55:09 2021 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Fri Jun  4 12:00:55 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c696ef46

net-libs/nodejs: drop 16.1.0

We will only stabilise v16 once it has reached the Active LTS status
(since according to upstream release schedule it is only then that a
Node.js major version becomes ready for general use), i.e. not before
2021-10-27. Until then, no point in keeping old v16 ebuilds in the tree
once a newer version has been added.

Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 -
 ...odejs-16.1.0-test-repl-history-navigation.patch |  56 -----
 net-libs/nodejs/nodejs-16.1.0.ebuild               | 235 ---------------------
 3 files changed, 292 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 72047ea96f6..ca1d06ede63 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,5 +1,4 @@
 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-v14.17.0.tar.xz 33484212 BLAKE2B 0ad045b7e0b96f564f42cef703338fece2167cb8bfe32840b765b137e01491a43a9c31ce290a3379ffa834ddfe4e2e1f42f95d4d0014240151b06313e0339383 SHA512 7a7683523904580462077c8bf3ee9640f1b674c7df55655049ca50ca3cfdb2973b13088f2b65e4eccf4df2641cd9c86c9716bcd160a5d5863a969cb1e88de093
-DIST node-v16.1.0.tar.xz 33770472 BLAKE2B 2b7cf5f07dbf72eb25018cd046ce15cf6c5a444225e34d425614c19e69888b4f5c9488b079fed12e6fe52cb8dfdee20cf61c4df5a39f53e60b95c4da445f2091 SHA512 dc12078203940e7b280198ae15f51f68aaefcf8cab71a9f988952e67045e4b16dc48ec471abcc497bd15b0b426c06678e376b53762349d6568b48d52888cc2d5
 DIST node-v16.3.0.tar.xz 33801084 BLAKE2B aa1f2fc6639ccb995252e483b68e1b425a9ad47cd148f5536fad168e94b0582819df511f797b3a278fd54d45e45f64dc701a997c2f17ad72d94d8b02d590cf81 SHA512 f25243521869ee9d99c2490150f8f9361b1603e497364ec559917d5c76e4a857e6c25c90d54b11e5a9d16fabb85e12b052ea768f3c2977ff18e96d33f60d9eff

diff --git a/net-libs/nodejs/files/nodejs-16.1.0-test-repl-history-navigation.patch b/net-libs/nodejs/files/nodejs-16.1.0-test-repl-history-navigation.patch
deleted file mode 100644
index 724541a870d..00000000000
--- a/net-libs/nodejs/files/nodejs-16.1.0-test-repl-history-navigation.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From 7c8a60851c459ea18afbfc54bfc8cf7394ea56c3 Mon Sep 17 00:00:00 2001
-From: Antoine du Hamel <duhamelantoine1995@gmail.com>
-Date: Thu, 6 May 2021 12:00:07 +0200
-Subject: [PATCH] test,repl: fix tests when inspector is disabled
-
-Fixes: https://github.com/nodejs/node/issues/38558
-
-PR-URL: https://github.com/nodejs/node/pull/38564
-Reviewed-By: Anna Henningsen <anna@addaleax.net>
-Reviewed-By: James M Snell <jasnell@gmail.com>
-Reviewed-By: Rich Trott <rtrott@gmail.com>
----
- test/parallel/test-repl-history-navigation.js | 12 ++++++------
- 1 file changed, 6 insertions(+), 6 deletions(-)
-
-diff --git a/test/parallel/test-repl-history-navigation.js b/test/parallel/test-repl-history-navigation.js
-index df4f0390a69c..527cf235bddd 100644
---- a/test/parallel/test-repl-history-navigation.js
-+++ b/test/parallel/test-repl-history-navigation.js
-@@ -559,14 +559,14 @@ const tests = [
-     env: { NODE_REPL_HISTORY: defaultHistoryPath },
-     test: ['const util = {}', ENTER,
-            'ut', RIGHT, ENTER],
--    expected: common.hasIntl && common.hasCrypto ? [
-+    expected: [
-       prompt, ...'const util = {}',
-       'undefined\n',
--      prompt, ...'ut', ' // il', '\n// {}',
--      'il', '\n// {}',
-+      prompt, ...'ut', ...(prev ? [' // il', '\n// {}',
-+                                   'il', '\n// {}'] : [' // il', 'il']),
-       '{}\n',
-       prompt,
--    ] : [],
-+    ],
-     clean: false
-   },
-   {
-@@ -577,7 +577,7 @@ const tests = [
-       'globalThis.util = {}', ENTER,
-       'ut', RIGHT, ENTER,
-       'Reflect.defineProperty(globalThis, "util", utilDesc)', ENTER],
--    expected: common.hasIntl && common.hasCrypto ? [
-+    expected: [
-       prompt, ...'const utilDesc = ' +
-       'Reflect.getOwnPropertyDescriptor(globalThis, "util")',
-       'undefined\n',
-@@ -588,7 +588,7 @@ const tests = [
-       prompt, ...'Reflect.defineProperty(globalThis, "util", utilDesc)',
-       'true\n',
-       prompt,
--    ] : [],
-+    ],
-     clean: false
-   },
- ];

diff --git a/net-libs/nodejs/nodejs-16.1.0.ebuild b/net-libs/nodejs/nodejs-16.1.0.ebuild
deleted file mode 100644
index e1f164dff75..00000000000
--- a/net-libs/nodejs/nodejs-16.1.0.ebuild
+++ /dev/null
@@ -1,235 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python3_{7..10} )
-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/"
-LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
-
-if [[ ${PV} == *9999 ]]; then
-	inherit git-r3
-	EGIT_REPO_URI="https://github.com/nodejs/node"
-	SLOT="0"
-else
-	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
-	SLOT="0/$(ver_cut 1)"
-	KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x64-macos"
-	S="${WORKDIR}/node-v${PV}"
-fi
-
-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 )"
-
-RESTRICT="!test? ( test )"
-
-RDEPEND=">=app-arch/brotli-1.0.9
-	>=dev-libs/libuv-1.40.0:=
-	>=net-dns/c-ares-1.17.0
-	>=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}-12.22.1-jinja_collections_abc.patch
-	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
-	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
-	"${FILESDIR}"/${PN}-16.1.0-test-repl-history-navigation.patch
-	"${FILESDIR}"/${PN}-16.1.0-ppc64-segfault.patch #785751, drop after it stops applying
-)
-
-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
-			if tc-is-gcc; then
-				if [[ $(gcc-major-version) -ge 11 ]]; then
-					# Bug #787158
-					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
-				fi
-			else
-				# configure.py will abort on this later if we do not
-				die "${PN} only supports LTO for gcc"
-			fi
-		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
-
-	# 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 )
-
-	# All this test does is check if the npm CLI produces warnings of any sort,
-	# failing if it does. Overkill, much? Especially given one possible warning
-	# is that there is a newer version of npm available upstream (yes, it does
-	# use the network if available), thus making it a real possibility for this
-	# test to begin failing one day even though it was fine before.
-	rm -f test/parallel/test-release-npm.js
-
-	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
-		keepdir /etc/npm
-
-		# Install bash completion for `npm`
-		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
-
-		# 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() {
-	# parallel/test-fs-mkdir is known to fail with FEATURES=usersandbox
-	if has usersandbox ${FEATURES}; then
-		ewarn "You are emerging ${P} with 'usersandbox' enabled." \
-			"Expect some test failures or emerge with 'FEATURES=-usersandbox'!"
-	fi
-
-	out/${BUILDTYPE}/cctest || die
-	"${EPYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -J message parallel sequential || die
-}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2021-06-24 11:15 Marek Szuba
  0 siblings, 0 replies; 36+ messages in thread
From: Marek Szuba @ 2021-06-24 11:15 UTC (permalink / raw
  To: gentoo-commits

commit:     8343d8dbc07ef7749636b6954a0dc6749536e434
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Thu Jun 24 11:15:17 2021 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Thu Jun 24 11:15:17 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8343d8db

net-libs/nodejs: add 16.4.0, drop 16.3.0

Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   2 +-
 .../files/nodejs-16.1.0-ppc64-segfault.patch       | 119 ---------------------
 .../{nodejs-16.3.0.ebuild => nodejs-16.4.0.ebuild} |   1 -
 3 files changed, 1 insertion(+), 121 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 17ecdcf2898..8bfd4716c99 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -2,4 +2,4 @@ DIST node-v12.22.1.tar.xz 23650180 BLAKE2B 90b0a8ab3842483fea0c776e0245e63539a98
 DIST node-v14.16.1.tar.xz 33297064 BLAKE2B 0927434c63cd248e90a4002b50c7a0fd68a5527a4cd7424b451840ddf0c403ba452979b195e598cc3b323e24233248a74a1274519ce8cd3a2f4e71dc7a8f3dcb SHA512 d4f5fbab69592ae555613b2186090b85a458d2211b6035989aee2617bfd0f6768ca767ec45ce12756a9c452d00af7237edee3b1ae526049e9fcd01f8f67680c0
 DIST node-v14.17.0.tar.xz 33484212 BLAKE2B 0ad045b7e0b96f564f42cef703338fece2167cb8bfe32840b765b137e01491a43a9c31ce290a3379ffa834ddfe4e2e1f42f95d4d0014240151b06313e0339383 SHA512 7a7683523904580462077c8bf3ee9640f1b674c7df55655049ca50ca3cfdb2973b13088f2b65e4eccf4df2641cd9c86c9716bcd160a5d5863a969cb1e88de093
 DIST node-v14.17.1.tar.xz 33580416 BLAKE2B da5234087945327fc7f3a666a8869426ec5adff3b31b800c59135d9937507bcca7be3c8ca6720c2593b45ec6a9b49c30f71dadbcc03dc0a68c082e3f1746e6df SHA512 354f9f215a4915ca3dbccdbb90c14fb8bfb8b0ed8ece4f95106d7b068affdeab65a79db0beb2c7d6af03dc15567edc5250629deedd38a9de7d581f76716315f8
-DIST node-v16.3.0.tar.xz 33801084 BLAKE2B aa1f2fc6639ccb995252e483b68e1b425a9ad47cd148f5536fad168e94b0582819df511f797b3a278fd54d45e45f64dc701a997c2f17ad72d94d8b02d590cf81 SHA512 f25243521869ee9d99c2490150f8f9361b1603e497364ec559917d5c76e4a857e6c25c90d54b11e5a9d16fabb85e12b052ea768f3c2977ff18e96d33f60d9eff
+DIST node-v16.4.0.tar.xz 33597252 BLAKE2B c43543057f58ed706e525db9956cb258ace88026c9ef1c87d85f07bc02bb382482e9044748b6c865d913ef167544f089e9c5c11fb00c2f0fa7ca9e6bf8d06de8 SHA512 c4e12d8e50c26f21170e998a209d060acfac792bf2a5970efc482f431f483841d40427aafe72a63d5b2bd2cd8d5d1fd19678105ab9b1265f68de6359d98fa1a3

diff --git a/net-libs/nodejs/files/nodejs-16.1.0-ppc64-segfault.patch b/net-libs/nodejs/files/nodejs-16.1.0-ppc64-segfault.patch
deleted file mode 100644
index 5ddd1fe7d08..00000000000
--- a/net-libs/nodejs/files/nodejs-16.1.0-ppc64-segfault.patch
+++ /dev/null
@@ -1,119 +0,0 @@
-From ca4bf75504d07db5e1e66ec5c867cd76c90268af Mon Sep 17 00:00:00 2001
-From: Junliang Yan <jyan@ca.ibm.ca>
-Date: Tue, 11 May 2021 08:57:03 -0400
-Subject: [PATCH] ppc: Prevent trampoline emission on deoptimization table generation
-
-The deoptimization table needs to be continuously, so we need to block
-trampoline pool emission during the whole process.
-
-bug: v8:11759
-Change-Id: Ie5e0ffe27dc8e6cdb18985dc2cf26bdadeff318f
-Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2881918
-Commit-Queue: Junliang Yan <junyan@redhat.com>
-Reviewed-by: Jakob Gruber <jgruber@chromium.org>
-Cr-Commit-Position: refs/heads/master@{#74506}
-X-Gentoo-bug: https://bugs.gentoo.org/785751
-Backported by gyakovlev@gentoo.org
----
-
-diff --git a/src/codegen/ppc/assembler-ppc.h b/src/codegen/ppc/assembler-ppc.h
-index 794b917..ae04118 100644
---- a/deps/v8/src/codegen/ppc/assembler-ppc.h
-+++ b/deps/v8/src/codegen/ppc/assembler-ppc.h
-@@ -195,6 +195,12 @@
- 
-   void MaybeEmitOutOfLineConstantPool() { EmitConstantPool(); }
- 
-+  inline void CheckTrampolinePoolQuick(int extra_space = 0) {
-+    if (pc_offset() >= next_trampoline_check_ - extra_space) {
-+      CheckTrampolinePool();
-+    }
-+  }
-+
-   // Label operations & relative jumps (PPUM Appendix D)
-   //
-   // Takes a branch opcode (cc) and a label (L) and generates
-@@ -1334,12 +1340,6 @@
-   }
- 
-   inline void UntrackBranch();
--  void CheckTrampolinePoolQuick() {
--    if (pc_offset() >= next_trampoline_check_) {
--      CheckTrampolinePool();
--    }
--  }
--
-   // Instruction generation
-   void a_form(Instr instr, DoubleRegister frt, DoubleRegister fra,
-               DoubleRegister frb, RCBit r);
-diff --git a/src/compiler/backend/code-generator.cc b/src/compiler/backend/code-generator.cc
-index 023e697..62e57fe 100644
---- a/deps/v8/src/compiler/backend/code-generator.cc
-+++ b/deps/v8/src/compiler/backend/code-generator.cc
-@@ -416,23 +416,29 @@
-     std::sort(deoptimization_exits_.begin(), deoptimization_exits_.end(), cmp);
-   }
- 
--  for (DeoptimizationExit* exit : deoptimization_exits_) {
--    if (exit->emitted()) continue;
--    if (Deoptimizer::kSupportsFixedDeoptExitSizes) {
--      exit->set_deoptimization_id(next_deoptimization_id_++);
--    }
--    result_ = AssembleDeoptimizerCall(exit);
--    if (result_ != kSuccess) return;
-+  {
-+#ifdef V8_TARGET_ARCH_PPC64
-+    v8::internal::Assembler::BlockTrampolinePoolScope block_trampoline_pool(
-+        tasm());
-+#endif
-+    for (DeoptimizationExit* exit : deoptimization_exits_) {
-+      if (exit->emitted()) continue;
-+      if (Deoptimizer::kSupportsFixedDeoptExitSizes) {
-+        exit->set_deoptimization_id(next_deoptimization_id_++);
-+      }
-+      result_ = AssembleDeoptimizerCall(exit);
-+      if (result_ != kSuccess) return;
- 
--    // UpdateDeoptimizationInfo expects lazy deopts to be visited in pc_offset
--    // order, which is always the case since they are added to
--    // deoptimization_exits_ in that order, and the optional sort operation
--    // above preserves that order.
--    if (exit->kind() == DeoptimizeKind::kLazy) {
--      int trampoline_pc = exit->label()->pos();
--      last_updated = safepoints()->UpdateDeoptimizationInfo(
--          exit->pc_offset(), trampoline_pc, last_updated,
--          exit->deoptimization_id());
-+      // UpdateDeoptimizationInfo expects lazy deopts to be visited in pc_offset
-+      // order, which is always the case since they are added to
-+      // deoptimization_exits_ in that order, and the optional sort operation
-+      // above preserves that order.
-+      if (exit->kind() == DeoptimizeKind::kLazy) {
-+        int trampoline_pc = exit->label()->pos();
-+        last_updated = safepoints()->UpdateDeoptimizationInfo(
-+            exit->pc_offset(), trampoline_pc, last_updated,
-+            exit->deoptimization_id());
-+      }
-     }
-   }
- 
-diff --git a/src/compiler/backend/ppc/code-generator-ppc.cc b/src/compiler/backend/ppc/code-generator-ppc.cc
-index 3e4e94a..0281376 100644
---- a/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
-+++ b/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
-@@ -4296,7 +4296,15 @@
- 
- void CodeGenerator::PrepareForDeoptimizationExits(
-     ZoneDeque<DeoptimizationExit*>* exits) {
--  // __ EmitConstantPool();
-+  int total_size = 0;
-+  for (DeoptimizationExit* exit : deoptimization_exits_) {
-+    total_size += (exit->kind() == DeoptimizeKind::kLazy)
-+                      ? Deoptimizer::kLazyDeoptExitSize
-+                      : Deoptimizer::kNonLazyDeoptExitSize;
-+  }
-+
-+  __ CheckTrampolinePoolQuick(total_size);
-+  DCHECK(Deoptimizer::kSupportsFixedDeoptExitSizes);
- }
- 
- void CodeGenerator::AssembleMove(InstructionOperand* source,

diff --git a/net-libs/nodejs/nodejs-16.3.0.ebuild b/net-libs/nodejs/nodejs-16.4.0.ebuild
similarity index 98%
rename from net-libs/nodejs/nodejs-16.3.0.ebuild
rename to net-libs/nodejs/nodejs-16.4.0.ebuild
index f4ae0ff1f25..f4221d00ab4 100644
--- a/net-libs/nodejs/nodejs-16.3.0.ebuild
+++ b/net-libs/nodejs/nodejs-16.4.0.ebuild
@@ -50,7 +50,6 @@ PATCHES=(
 	"${FILESDIR}"/${PN}-12.22.1-jinja_collections_abc.patch
 	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
 	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
-	"${FILESDIR}"/${PN}-16.1.0-ppc64-segfault.patch #785751, drop after it stops applying
 )
 
 pkg_pretend() {


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2022-03-17 21:39 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2022-03-17 21:39 UTC (permalink / raw
  To: gentoo-commits

commit:     b6286012b3486b92a400cd116512f807a9b20dcb
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Thu Mar 17 21:39:19 2022 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Thu Mar 17 21:39:19 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b6286012

net-libs/nodejs: add 12.22.10

Bug: https://bugs.gentoo.org/831037
Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 +
 .../files/nodejs-12.22.10-global-npm-config.patch  |  20 ++
 net-libs/nodejs/nodejs-12.22.10.ebuild             | 249 +++++++++++++++++++++
 3 files changed, 270 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 4877d0318846..880e390b294b 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,3 +1,4 @@
+DIST node-v12.22.10.tar.xz 24089580 BLAKE2B 0ecf0b2ed64cba1bbcab287ccf7e524bd08ce787399d01fb792fd5232983289403a85810bc6eccd090b6d15796c48dc6ea3baf0cb3154e392dc343da53086b81 SHA512 da984e98856ef89eb259346d9d1eae60ff3d255d964f3b09d59851a9c21c86acd0c56b9c888f61423de07afab1c09946c00856c832a1f1a8abc4c671c31e23b1
 DIST node-v12.22.5.tar.xz 23654908 BLAKE2B ca4f304e31f091ae656142035851d6e4427d8b2ddd2a69506dec96efbb1269a19a08e9ab8d44dfe10f8429bc239e4102f3f030adb25e9c41901c7d94b53e88c8 SHA512 80f3c673a1f2af7fffd6aaa556c06b8225034c8413e1a738c19d491aff1b3e6ed388df66ecbff88e4bfbefe1013dac7e3beb301456c2099b6a954ba468b21883
 DIST node-v12.22.6.tar.xz 23664904 BLAKE2B 04dd4fd4cbe39642a1c3dd8639a4d9e3362055f56bc2565303d0095cda1655033ba4e0ce5a969647d2be73df13ddbcccc4907825a94a41b45c0723b3c02ca980 SHA512 d107f1ff7073d2db9f0198f14b0523870e9b262c71055de2e03fba54f87bc98a57dad43d902c0b349957df21de71dc066133d4831eb7eb07f4e548d0ac724fb2
 DIST node-v12.22.7.tar.xz 23661696 BLAKE2B aa162e2aee98568c207b11a27651cefdf6444568ad0c0dc602d63a6767fc7d00d10e93626168b334d6fe1774fc8da420ed05b9d2ce485f0ec3544d992bfb5b83 SHA512 7697b409537114abf14a3847fffd8952fd35f54569bfa84ba527f231ac1defced5d11fe7bc39ff8ec7cccb282d584ff50a33bcbba16474c6a125808a29104222

diff --git a/net-libs/nodejs/files/nodejs-12.22.10-global-npm-config.patch b/net-libs/nodejs/files/nodejs-12.22.10-global-npm-config.patch
new file mode 100644
index 000000000000..09d9dbe47be0
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-12.22.10-global-npm-config.patch
@@ -0,0 +1,20 @@
+diff --git a/deps/npm/lib/config/core.js b/deps/npm/lib/config/core.js
+index 36420b3450..0afb0b6792 100644
+--- a/deps/npm/lib/config/core.js
++++ b/deps/npm/lib/config/core.js
+@@ -151,11 +151,10 @@ function load_ (builtin, rc, cli, cb) {
+     // Eg, `npm config get globalconfig --prefix ~/local` should
+     // return `~/local/etc/npmrc`
+     // annoying humans and their expectations!
+-    if (conf.get('prefix')) {
+-      var etc = path.resolve(conf.get('prefix'), 'etc')
+-      defaults.globalconfig = path.resolve(etc, 'npmrc')
+-      defaults.globalignorefile = path.resolve(etc, 'npmignore')
+-    }
++    // gentoo deviates wrt global config; store in /etc/npm
++    var globalconfig = path.resolve('/etc', 'npm')
++    defaults.globalconfig = path.resolve(globalconfig, 'npmrc')
++    defaults.globalignorefile = path.resolve(globalconfig, 'npmignore')
+ 
+     conf.addFile(conf.get('globalconfig'), 'global')
+ 

diff --git a/net-libs/nodejs/nodejs-12.22.10.ebuild b/net-libs/nodejs/nodejs-12.22.10.ebuild
new file mode 100644
index 000000000000..f0d3207ee367
--- /dev/null
+++ b/net-libs/nodejs/nodejs-12.22.10.ebuild
@@ -0,0 +1,249 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+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/"
+LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
+
+if [[ ${PV} == *9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/nodejs/node"
+	SLOT="0"
+else
+	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
+	SLOT="0/$(ver_cut 1)"
+	KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 -riscv ~x86 ~amd64-linux ~x64-macos"
+	S="${WORKDIR}/node-v${PV}"
+fi
+
+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 )
+"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	>=app-arch/brotli-1.0.9:=
+	>=dev-libs/libuv-1.39.0:=
+	>=net-dns/c-ares-1.17.2:=
+	>=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=
+		<dev-libs/openssl-3.0.0_beta1:0=
+	)
+"
+BDEPEND="
+	${PYTHON_DEPS}
+	sys-apps/coreutils
+	virtual/pkgconfig
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )
+"
+DEPEND="
+	${RDEPEND}
+"
+PATCHES=(
+	"${FILESDIR}"/${P}-global-npm-config.patch
+	"${FILESDIR}"/${PN}-12.20.1-fix_ppc64_crashes.patch
+	"${FILESDIR}"/${PN}-12.22.1-jinja_collections_abc.patch
+	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
+	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
+	"${FILESDIR}"/${PN}-99999999-llhttp.patch
+)
+
+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
+			if tc-is-gcc; then
+				if [[ $(gcc-major-version) -ge 11 ]]; then
+					# Bug #787158
+					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
+				fi
+			else
+				# configure.py will abort on this later if we do not
+				die "${PN} only supports LTO for gcc"
+			fi
+		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
+
+	# Known-to-fail test of a deprecated, legacy HTTP parser. Just don't bother.
+	rm -f test/parallel/test-http-transfer-encoding-smuggling-legacy.js
+
+	# 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() {
+	if has usersandbox ${FEATURES}; then
+		rm -f "${S}"/test/parallel/test-fs-mkdir.js
+		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
+			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
+	fi
+
+	out/${BUILDTYPE}/cctest || die
+	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -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>"
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2022-05-04 17:57 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2022-05-04 17:57 UTC (permalink / raw
  To: gentoo-commits

commit:     f50edf9044e26c33da7c46d40be1081bfa88728a
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Wed May  4 17:43:40 2022 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Wed May  4 17:57:39 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f50edf90

net-libs/nodejs: add 18.1.0

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 +
 .../nodejs/files/nodejs-18.0.0-paxmarking.patch    | 113 ++++++++++
 net-libs/nodejs/nodejs-18.1.0.ebuild               | 230 +++++++++++++++++++++
 3 files changed, 344 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index b7f49695e375..5717aa7e1f63 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -6,3 +6,4 @@ DIST node-v14.17.6.tar.xz 33606464 BLAKE2B c2c449e5eaf8214d7ed4bfab8db0208034cee
 DIST node-v14.19.0.tar.xz 34486868 BLAKE2B 12e571a366c1d4b2475ef258e338f516bb81e9c08f7e6b7f951decbf371028cdcf32c72181d8504d0890496eaecce0d6b23437b8dad6c6e498d30bf6636bd1e7 SHA512 80573fa3a0882c1f2a40b991f187f49714748ca4c56c78133e2d2be0322f201816eb059a1a7d38ea8a925229c1b1324d0ffc28ff4002d0115bfae44fe87efe97
 DIST node-v16.14.2.tar.xz 34332624 BLAKE2B 756895f81ecabbacf30b1e513890d100192c367443a5d041cd3e383985acb6fae189213f44b7a533b43d1b759d5a2677a5ee787c72d3abdb480879d6d24cc95e SHA512 b97274f6e0d63f19e01497c43af36e6561f019e7b0b5b4f6ea19d0fbe2cb4d3c514c06f49e237d1e327936db03c3f437ae0d0b2f830a35f1b7c3a723fbe2a1be
 DIST node-v18.0.0.tar.xz 36826840 BLAKE2B 658b6a4872779c648b1c10b952403892a4ea846525737daba222aeb7d1467f797345c2e07bfb28320d593810617541b893dd37006dcbd13e5e69313455045ff0 SHA512 801ee56e22490453f259ab92bfcd1b13da3f9510fb70078da1e680d0a27971d4ee4b4b4344b2a969d230e661fd9a8b35e9104c5fe0a594222be3a20583a59f3e
+DIST node-v18.1.0.tar.xz 36841136 BLAKE2B 77cc028f61391c483cf9bdff09a2101790119257ceee5b6702347aee771c7ed9656458f482bceb89d9921a598b9e2134ef6c424e6c879934dce9bcc85fbb3552 SHA512 edaf830b90b74ff7e8d1098f7f09cff91dc60738bfc612f6847bd7ac283ca76453f624057f64ba3ddcc86804bfbd652eaf8eae1398118220fd54fbf9c0a0e49c

diff --git a/net-libs/nodejs/files/nodejs-18.0.0-paxmarking.patch b/net-libs/nodejs/files/nodejs-18.0.0-paxmarking.patch
new file mode 100644
index 000000000000..c778d1729384
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-18.0.0-paxmarking.patch
@@ -0,0 +1,113 @@
+diff -urNp node-v15.8.0-orig/node.gyp node-v15.8.0-dwok/node.gyp
+--- node-v15.8.0-orig/node.gyp	2021-02-24 22:21:44.202911780 +0100
++++ node-v15.8.0-dwok/node.gyp	2021-02-24 22:25:34.298281739 +0100
+@@ -55,7 +55,9 @@
+       'deps/undici/undici.js',
+     ],
+     'node_mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot<(EXECUTABLE_SUFFIX)',
++    'node_mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'mkcodecache_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache<(EXECUTABLE_SUFFIX)',
++    'mkcodecache_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache_u<(EXECUTABLE_SUFFIX)',
+     'conditions': [
+       ['GENERATOR == "ninja"', {
+         'node_text_start_object_path': 'src/large_pages/node_text_start.node_text_start.o'
+@@ -293,10 +295,24 @@
+           ],
+           'actions': [
+             {
++              'action_name': 'run_pax_mkcodecache',
++              'inputs': [
++                '<(mkcodecache_exec)',
++              ],
++              'outputs': [
++                '<(mkcodecache_u_exec)',
++              ],
++              'action': [
++                'bash',
++                '-c',
++                'mv <(mkcodecache_exec) <(mkcodecache_u_exec) && paxmark.sh m <(mkcodecache_u_exec)',
++              ],
++            },
++            {
+               'action_name': 'run_mkcodecache',
+               'process_outputs_as_sources': 1,
+               'inputs': [
+-                '<(mkcodecache_exec)',
++                '<(mkcodecache_u_exec)',
+               ],
+               'outputs': [
+                 '<(SHARED_INTERMEDIATE_DIR)/node_code_cache.cc',
+@@ -340,10 +356,24 @@
+             }, {
+               'actions': [
+                 {
++                  'action_name': 'run_pax_mksnapshot',
++                  'inputs': [
++                    '<(node_mksnapshot_exec)',
++                  ],
++                  'outputs': [
++                    '<(node_mksnapshot_u_exec)',
++                  ],
++                  'action': [
++                    'bash',
++                    '-c',
++                    'mv <(node_mksnapshot_exec) <(node_mksnapshot_u_exec) && paxmark.sh m <(node_mksnapshot_u_exec)',
++                  ],
++                },
++                {
+                   'action_name': 'node_mksnapshot',
+                   'process_outputs_as_sources': 1,
+                   'inputs': [
+-                    '<(node_mksnapshot_exec)',
++                    '<(node_mksnapshot_u_exec)',
+                   ],
+                   'outputs': [
+                     '<(SHARED_INTERMEDIATE_DIR)/node_snapshot.cc',
+diff -urNp node-v15.8.0-orig/tools/v8_gypfiles/v8.gyp node-v15.8.0-dwok/tools/v8_gypfiles/v8.gyp
+--- node-v15.8.0-orig/tools/v8_gypfiles/v8.gyp	2021-02-24 22:21:44.654910571 +0100
++++ node-v15.8.0-dwok/tools/v8_gypfiles/v8.gyp	2021-02-24 22:25:54.834224791 +0100
+@@ -9,6 +9,7 @@
+     'v8_vector_stores%': 0,
+     'v8_embed_script%': "",
+     'mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
++    'mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'v8_os_page_size%': 0,
+     'generate_bytecode_output_root': '<(SHARED_INTERMEDIATE_DIR)/generate-bytecode-output-root',
+     'generate_bytecode_builtins_list_output': '<(generate_bytecode_output_root)/builtins-generated/bytecodes-builtins-list.h',
+@@ -1413,7 +1414,7 @@
+       ],
+     },  # bytecode_builtins_list_generator
+     {
+-      'target_name': 'mksnapshot',
++      'target_name': 'mksnapshot_u',
+       'type': 'executable',
+       'dependencies': [
+         'v8_base_without_compiler',
+@@ -1432,6 +1433,27 @@
+           'toolsets': ['host'],
+         }],
+       ],
++    },  # mksnapshot_u
++    {
++      'target_name': 'mksnapshot',
++      'type': 'none',
++      'dependencies': ['mksnapshot_u'],
++      'actions': [
++        {
++          'action_name': 'paxmark_mksnapshot',
++          'inputs': [
++            '<(mksnapshot_u_exec)',
++          ],
++          'outputs': [
++            '<(mksnapshot_exec)',
++          ],
++          'action': [
++            'bash',
++            '-c',
++            'cp <(mksnapshot_u_exec) <(mksnapshot_exec) && paxmark.sh m <(mksnapshot_exec)'
++          ],
++        },
++      ],
+     },  # mksnapshot
+     {
+       'target_name': 'torque',

diff --git a/net-libs/nodejs/nodejs-18.1.0.ebuild b/net-libs/nodejs/nodejs-18.1.0.ebuild
new file mode 100644
index 000000000000..f546bf353cfc
--- /dev/null
+++ b/net-libs/nodejs/nodejs-18.1.0.ebuild
@@ -0,0 +1,230 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+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/"
+LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
+
+if [[ ${PV} == *9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/nodejs/node"
+	SLOT="0"
+else
+	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
+	SLOT="0/$(ver_cut 1)"
+	KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~riscv ~x86 ~amd64-linux ~x64-macos"
+	S="${WORKDIR}/node-v${PV}"
+fi
+
+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 )"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND=">=app-arch/brotli-1.0.9:=
+	>=dev-libs/libuv-1.40.0:=
+	>=net-dns/c-ares-1.17.2:=
+	>=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}-12.22.5-shared_c-ares_nameser_h.patch
+	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
+)
+
+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
+			if tc-is-gcc; then
+				if [[ $(gcc-major-version) -ge 11 ]]; then
+					# Bug #787158
+					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
+				fi
+			fi
+		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
+
+	# 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}-18.0.0-paxmarking.patch )
+
+	# All this test does is check if the npm CLI produces warnings of any sort,
+	# failing if it does. Overkill, much? Especially given one possible warning
+	# is that there is a newer version of npm available upstream (yes, it does
+	# use the network if available), thus making it a real possibility for this
+	# test to begin failing one day even though it was fine before.
+	rm -f test/parallel/test-release-npm.js
+
+	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";;
+		lp64*) myarch="riscv64";;
+		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
+		keepdir /etc/npm
+
+		# Install bash completion for `npm`
+		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
+
+		# 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() {
+	if has usersandbox ${FEATURES}; then
+		rm -f "${S}"/test/parallel/test-fs-mkdir.js
+		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
+			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
+	fi
+
+	out/${BUILDTYPE}/cctest || die
+	"${EPYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -J message parallel sequential || die
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2022-05-04 18:25 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2022-05-04 18:25 UTC (permalink / raw
  To: gentoo-commits

commit:     92041b5ba9b80d6b6e2a493dd45468c82fdbd393
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Wed May  4 18:24:55 2022 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Wed May  4 18:25:40 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=92041b5b

net-libs/nodejs: update paxmarking patch for nodejs 16.x

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 .../nodejs/files/nodejs-16.4.2-paxmarking.patch    | 113 +++++++++++++++++++++
 net-libs/nodejs/nodejs-16.14.2.ebuild              |   2 +-
 2 files changed, 114 insertions(+), 1 deletion(-)

diff --git a/net-libs/nodejs/files/nodejs-16.4.2-paxmarking.patch b/net-libs/nodejs/files/nodejs-16.4.2-paxmarking.patch
new file mode 100644
index 000000000000..41abd1f1917f
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-16.4.2-paxmarking.patch
@@ -0,0 +1,113 @@
+diff -urNp node-v15.8.0-orig/node.gyp node-v15.8.0-dwok/node.gyp
+--- node-v15.8.0-orig/node.gyp	2021-02-24 22:21:44.202911780 +0100
++++ node-v15.8.0-dwok/node.gyp	2021-02-24 22:25:34.298281739 +0100
+@@ -53,7 +53,9 @@
+       'deps/cjs-module-lexer/dist/lexer.js',
+     ],
+     'node_mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot<(EXECUTABLE_SUFFIX)',
++    'node_mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'mkcodecache_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache<(EXECUTABLE_SUFFIX)',
++    'mkcodecache_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache_u<(EXECUTABLE_SUFFIX)',
+     'conditions': [
+       ['GENERATOR == "ninja"', {
+         'node_text_start_object_path': 'src/large_pages/node_text_start.node_text_start.o'
+@@ -291,10 +293,24 @@
+           ],
+           'actions': [
+             {
++              'action_name': 'run_pax_mkcodecache',
++              'inputs': [
++                '<(mkcodecache_exec)',
++              ],
++              'outputs': [
++                '<(mkcodecache_u_exec)',
++              ],
++              'action': [
++                'bash',
++                '-c',
++                'mv <(mkcodecache_exec) <(mkcodecache_u_exec) && paxmark.sh m <(mkcodecache_u_exec)',
++              ],
++            },
++            {
+               'action_name': 'run_mkcodecache',
+               'process_outputs_as_sources': 1,
+               'inputs': [
+-                '<(mkcodecache_exec)',
++                '<(mkcodecache_u_exec)',
+               ],
+               'outputs': [
+                 '<(SHARED_INTERMEDIATE_DIR)/node_code_cache.cc',
+@@ -316,10 +332,24 @@
+           ],
+           'actions': [
+             {
++              'action_name': 'run_pax_mksnapshot',
++              'inputs': [
++                '<(node_mksnapshot_exec)',
++              ],
++              'outputs': [
++                '<(node_mksnapshot_u_exec)',
++              ],
++              'action': [
++                'bash',
++                '-c',
++                'mv <(node_mksnapshot_exec) <(node_mksnapshot_u_exec) && paxmark.sh m <(node_mksnapshot_u_exec)',
++              ],
++            },
++            {
+               'action_name': 'node_mksnapshot',
+               'process_outputs_as_sources': 1,
+               'inputs': [
+-                '<(node_mksnapshot_exec)',
++                '<(node_mksnapshot_u_exec)',
+               ],
+               'outputs': [
+                 '<(SHARED_INTERMEDIATE_DIR)/node_snapshot.cc',
+diff -urNp node-v15.8.0-orig/tools/v8_gypfiles/v8.gyp node-v15.8.0-dwok/tools/v8_gypfiles/v8.gyp
+--- node-v15.8.0-orig/tools/v8_gypfiles/v8.gyp	2021-02-24 22:21:44.654910571 +0100
++++ node-v15.8.0-dwok/tools/v8_gypfiles/v8.gyp	2021-02-24 22:25:54.834224791 +0100
+@@ -9,6 +9,7 @@
+     'v8_vector_stores%': 0,
+     'v8_embed_script%': "",
+     'mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
++    'mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'v8_os_page_size%': 0,
+     'generate_bytecode_output_root': '<(SHARED_INTERMEDIATE_DIR)/generate-bytecode-output-root',
+     'generate_bytecode_builtins_list_output': '<(generate_bytecode_output_root)/builtins-generated/bytecodes-builtins-list.h',
+@@ -1430,7 +1431,7 @@
+       ],
+     },  # bytecode_builtins_list_generator
+     {
+-      'target_name': 'mksnapshot',
++      'target_name': 'mksnapshot_u',
+       'type': 'executable',
+       'dependencies': [
+         'v8_base_without_compiler',
+@@ -1449,6 +1450,27 @@
+           'toolsets': ['host'],
+         }],
+       ],
++    },  # mksnapshot_u
++    {
++      'target_name': 'mksnapshot',
++      'type': 'none',
++      'dependencies': ['mksnapshot_u'],
++      'actions': [
++        {
++          'action_name': 'paxmark_mksnapshot',
++          'inputs': [
++            '<(mksnapshot_u_exec)',
++          ],
++          'outputs': [
++            '<(mksnapshot_exec)',
++          ],
++          'action': [
++            'bash',
++            '-c',
++            'cp <(mksnapshot_u_exec) <(mksnapshot_exec) && paxmark.sh m <(mksnapshot_exec)'
++          ],
++        },
++      ],
+     },  # mksnapshot
+     {
+       'target_name': 'torque',

diff --git a/net-libs/nodejs/nodejs-16.14.2.ebuild b/net-libs/nodejs/nodejs-16.14.2.ebuild
index 2a2901aecff5..d5a7de09fe13 100644
--- a/net-libs/nodejs/nodejs-16.14.2.ebuild
+++ b/net-libs/nodejs/nodejs-16.14.2.ebuild
@@ -96,7 +96,7 @@ src_prepare() {
 	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 )
+	use pax-kernel && PATCHES+=( "${FILESDIR}"/${PN}-16.4.2-paxmarking.patch )
 
 	# All this test does is check if the npm CLI produces warnings of any sort,
 	# failing if it does. Overkill, much? Especially given one possible warning


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2022-05-04 18:50 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2022-05-04 18:50 UTC (permalink / raw
  To: gentoo-commits

commit:     d790231b88ab650ac50f754719fa515128ce1119
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Wed May  4 18:49:11 2022 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Wed May  4 18:49:30 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d790231b

net-libs/nodejs: drop 12.22.5-r1, 12.22.6, 12.22.10

Nodejs 12.x is no longer supported upstream.
Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   3 -
 .../files/nodejs-12.20.1-fix_ppc64_crashes.patch   |  44 ----
 .../nodejs-12.22.1-jinja_collections_abc.patch     |  95 --------
 net-libs/nodejs/nodejs-12.22.10.ebuild             | 249 ---------------------
 net-libs/nodejs/nodejs-12.22.5-r1.ebuild           | 249 ---------------------
 net-libs/nodejs/nodejs-12.22.6.ebuild              | 249 ---------------------
 6 files changed, 889 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 0b7285ce5651..0c6c3c7600cc 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,6 +1,3 @@
-DIST node-v12.22.10.tar.xz 24089580 BLAKE2B 0ecf0b2ed64cba1bbcab287ccf7e524bd08ce787399d01fb792fd5232983289403a85810bc6eccd090b6d15796c48dc6ea3baf0cb3154e392dc343da53086b81 SHA512 da984e98856ef89eb259346d9d1eae60ff3d255d964f3b09d59851a9c21c86acd0c56b9c888f61423de07afab1c09946c00856c832a1f1a8abc4c671c31e23b1
-DIST node-v12.22.5.tar.xz 23654908 BLAKE2B ca4f304e31f091ae656142035851d6e4427d8b2ddd2a69506dec96efbb1269a19a08e9ab8d44dfe10f8429bc239e4102f3f030adb25e9c41901c7d94b53e88c8 SHA512 80f3c673a1f2af7fffd6aaa556c06b8225034c8413e1a738c19d491aff1b3e6ed388df66ecbff88e4bfbefe1013dac7e3beb301456c2099b6a954ba468b21883
-DIST node-v12.22.6.tar.xz 23664904 BLAKE2B 04dd4fd4cbe39642a1c3dd8639a4d9e3362055f56bc2565303d0095cda1655033ba4e0ce5a969647d2be73df13ddbcccc4907825a94a41b45c0723b3c02ca980 SHA512 d107f1ff7073d2db9f0198f14b0523870e9b262c71055de2e03fba54f87bc98a57dad43d902c0b349957df21de71dc066133d4831eb7eb07f4e548d0ac724fb2
 DIST node-v14.17.5.tar.xz 33585724 BLAKE2B cf79397caad8c81e4096f344f9fdb88d8ecea44b97fe208256dfd4afb750ecdf52142a2dc0430285b9d5117bdd43fa5ce42b4418926eec4d2c7f0a5f5d1a1539 SHA512 9d62c8946d05862d96a13a71b241a097b9f592a9e5f7362c81d8f3c74e7c5546a308b4c74bef34a66cafeef5d1a87d9d3e5ae8bb87d470c1ecf5abb8de0dedb5
 DIST node-v14.17.6.tar.xz 33606464 BLAKE2B c2c449e5eaf8214d7ed4bfab8db0208034cee1d08ef0e1fca478c30fc5cf95be037eb141080dbcfbe4fc58ef734457747dcbd0fe585a0536f9c0bec495435f25 SHA512 581c5698112426042fbf54fa793e56a30cae0c54ce8f23af6ac20d73c69a4f1166c5410f357c5a7b0409a773f99e3b9291e4afffd53b3c0e00569725dc4c47d3
 DIST node-v14.19.0.tar.xz 34486868 BLAKE2B 12e571a366c1d4b2475ef258e338f516bb81e9c08f7e6b7f951decbf371028cdcf32c72181d8504d0890496eaecce0d6b23437b8dad6c6e498d30bf6636bd1e7 SHA512 80573fa3a0882c1f2a40b991f187f49714748ca4c56c78133e2d2be0322f201816eb059a1a7d38ea8a925229c1b1324d0ffc28ff4002d0115bfae44fe87efe97

diff --git a/net-libs/nodejs/files/nodejs-12.20.1-fix_ppc64_crashes.patch b/net-libs/nodejs/files/nodejs-12.20.1-fix_ppc64_crashes.patch
deleted file mode 100644
index 0982d3c81c2a..000000000000
--- a/net-libs/nodejs/files/nodejs-12.20.1-fix_ppc64_crashes.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-Backport of https://github.com/nodejs/node/pull/33866 to nodejs-12
-
---- a/deps/v8/src/compiler/backend/instruction-selector.cc
-+++ b/deps/v8/src/compiler/backend/instruction-selector.cc
-@@ -2788,7 +2788,7 @@
-   switch (call_descriptor->kind()) {
-     case CallDescriptor::kCallAddress: {
-       int misc_field = static_cast<int>(call_descriptor->ParameterCount());
--#if defined(_AIX)
-+#if ABI_USES_FUNCTION_DESCRIPTORS
-       // Highest misc_field bit is used on AIX to indicate if a CFunction call
-       // has function descriptor or not.
-       misc_field |= call_descriptor->HasFunctionDescriptor()
---- a/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
-+++ b/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
-@@ -1026,7 +1026,7 @@
-       Label start_call;
-       bool isWasmCapiFunction =
-           linkage()->GetIncomingDescriptor()->IsWasmCapiFunction();
--#if defined(_AIX)
-+#if ABI_USES_FUNCTION_DESCRIPTORS
-       // AIX/PPC64BE Linux uses a function descriptor
-       int kNumParametersMask = kHasFunctionDescriptorBitMask - 1;
-       num_parameters = kNumParametersMask & misc_field;
---- a/deps/v8/src/execution/simulator.h
-+++ b/deps/v8/src/execution/simulator.h
-@@ -122,7 +122,7 @@
- 
-   DISABLE_CFI_ICALL Return Call(Args... args) {
-     // When running without a simulator we call the entry directly.
--#if V8_OS_AIX
-+#if ABI_USES_FUNCTION_DESCRIPTORS
-     // AIX ABI requires function descriptors (FD).  Artificially create a pseudo
-     // FD to ensure correct dispatch to generated code.  The 'volatile'
-     // declaration is required to avoid the compiler from not observing the
-@@ -134,7 +134,7 @@
-     return fn(args...);
- #else
-     return fn_ptr_(args...);
--#endif  // V8_OS_AIX
-+#endif  // ABI_USES_FUNCTION_DESCRIPTORS
-   }
- #endif  // USE_SIMULATOR
- 

diff --git a/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch b/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch
deleted file mode 100644
index 5f0df09b6e2e..000000000000
--- a/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch
+++ /dev/null
@@ -1,95 +0,0 @@
---- a/deps/v8/third_party/jinja2/tests.py
-+++ b/deps/v8/third_party/jinja2/tests.py
-@@ -10,7 +10,7 @@
- """
- import operator
- import re
--from collections import Mapping
-+from collections.abc import Mapping
- from jinja2.runtime import Undefined
- from jinja2._compat import text_type, string_types, integer_types
- import decimal
---- a/deps/v8/third_party/jinja2/runtime.py
-+++ b/deps/v8/third_party/jinja2/runtime.py
-@@ -315,7 +315,7 @@ class Context(with_metaclass(ContextMeta)):
- 
- # register the context as mapping if possible
- try:
--    from collections import Mapping
-+    from collections.abc import Mapping
-     Mapping.register(Context)
- except ImportError:
-     pass
---- a/deps/v8/third_party/jinja2/sandbox.py
-+++ b/deps/v8/third_party/jinja2/sandbox.py
-@@ -14,7 +14,7 @@
- """
- import types
- import operator
--from collections import Mapping
-+from collections.abc import Mapping
- from jinja2.environment import Environment
- from jinja2.exceptions import SecurityError
- from jinja2._compat import string_types, PY2
-@@ -79,7 +79,7 @@ except ImportError:
-     pass
- 
- #: register Python 2.6 abstract base classes
--from collections import MutableSet, MutableMapping, MutableSequence
-+from collections.abc import MutableSet, MutableMapping, MutableSequence
- _mutable_set_types += (MutableSet,)
- _mutable_mapping_types += (MutableMapping,)
- _mutable_sequence_types += (MutableSequence,)
---- a/deps/v8/third_party/jinja2/utils.py
-+++ b/deps/v8/third_party/jinja2/utils.py
-@@ -482,7 +482,7 @@ class LRUCache(object):
- 
- # register the LRU cache as mutable mapping if possible
- try:
--    from collections import MutableMapping
-+    from collections.abc import MutableMapping
-     MutableMapping.register(LRUCache)
- except ImportError:
-     pass
---- a/tools/inspector_protocol/jinja2/runtime.py
-+++ b/tools/inspector_protocol/jinja2/runtime.py
-@@ -315,7 +315,7 @@ class Context(with_metaclass(ContextMeta)):
- 
- # register the context as mapping if possible
- try:
--    from collections import Mapping
-+    from collections.abc import Mapping
-     Mapping.register(Context)
- except ImportError:
-     pass
---- a/tools/inspector_protocol/jinja2/sandbox.py
-+++ b/tools/inspector_protocol/jinja2/sandbox.py
-@@ -14,7 +14,7 @@
- """
- import types
- import operator
--from collections import Mapping
-+from collections.abc import Mapping
- from jinja2.environment import Environment
- from jinja2.exceptions import SecurityError
- from jinja2._compat import string_types, PY2
-@@ -79,7 +79,7 @@ except ImportError:
-     pass
- 
- #: register Python 2.6 abstract base classes
--from collections import MutableSet, MutableMapping, MutableSequence
-+from collections.abc import MutableSet, MutableMapping, MutableSequence
- _mutable_set_types += (MutableSet,)
- _mutable_mapping_types += (MutableMapping,)
- _mutable_sequence_types += (MutableSequence,)
---- a/tools/inspector_protocol/jinja2/tests.py
-+++ b/tools/inspector_protocol/jinja2/tests.py
-@@ -10,7 +10,7 @@
- """
- import operator
- import re
--from collections import Mapping
-+from collections.abc import Mapping
- from jinja2.runtime import Undefined
- from jinja2._compat import text_type, string_types, integer_types
- import decimal

diff --git a/net-libs/nodejs/nodejs-12.22.10.ebuild b/net-libs/nodejs/nodejs-12.22.10.ebuild
deleted file mode 100644
index 4638f6304808..000000000000
--- a/net-libs/nodejs/nodejs-12.22.10.ebuild
+++ /dev/null
@@ -1,249 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{8..10} )
-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/"
-LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
-
-if [[ ${PV} == *9999 ]]; then
-	inherit git-r3
-	EGIT_REPO_URI="https://github.com/nodejs/node"
-	SLOT="0"
-else
-	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
-	SLOT="0/$(ver_cut 1)"
-	KEYWORDS="amd64 ~arm arm64 ppc64 -riscv x86 ~amd64-linux ~x64-macos"
-	S="${WORKDIR}/node-v${PV}"
-fi
-
-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 )
-"
-
-RESTRICT="!test? ( test )"
-
-RDEPEND="
-	>=app-arch/brotli-1.0.9:=
-	>=dev-libs/libuv-1.39.0:=
-	>=net-dns/c-ares-1.17.2:=
-	>=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=
-		<dev-libs/openssl-3.0.0_beta1:0=
-	)
-"
-BDEPEND="
-	${PYTHON_DEPS}
-	sys-apps/coreutils
-	virtual/pkgconfig
-	systemtap? ( dev-util/systemtap )
-	test? ( net-misc/curl )
-"
-DEPEND="
-	${RDEPEND}
-"
-PATCHES=(
-	"${FILESDIR}"/${P}-global-npm-config.patch
-	"${FILESDIR}"/${PN}-12.20.1-fix_ppc64_crashes.patch
-	"${FILESDIR}"/${PN}-12.22.1-jinja_collections_abc.patch
-	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
-	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
-	"${FILESDIR}"/${PN}-99999999-llhttp.patch
-)
-
-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
-			if tc-is-gcc; then
-				if [[ $(gcc-major-version) -ge 11 ]]; then
-					# Bug #787158
-					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
-				fi
-			else
-				# configure.py will abort on this later if we do not
-				die "${PN} only supports LTO for gcc"
-			fi
-		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
-
-	# Known-to-fail test of a deprecated, legacy HTTP parser. Just don't bother.
-	rm -f test/parallel/test-http-transfer-encoding-smuggling-legacy.js
-
-	# 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() {
-	if has usersandbox ${FEATURES}; then
-		rm -f "${S}"/test/parallel/test-fs-mkdir.js
-		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
-			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
-	fi
-
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -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.22.5-r1.ebuild b/net-libs/nodejs/nodejs-12.22.5-r1.ebuild
deleted file mode 100644
index 1e716cbf5e85..000000000000
--- a/net-libs/nodejs/nodejs-12.22.5-r1.ebuild
+++ /dev/null
@@ -1,249 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python3_{8..10} )
-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/"
-LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
-
-if [[ ${PV} == *9999 ]]; then
-	inherit git-r3
-	EGIT_REPO_URI="https://github.com/nodejs/node"
-	SLOT="0"
-else
-	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
-	SLOT="0/$(ver_cut 1)"
-	KEYWORDS="amd64 arm arm64 ppc64 -riscv x86 ~amd64-linux ~x64-macos"
-	S="${WORKDIR}/node-v${PV}"
-fi
-
-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 )
-"
-
-RESTRICT="!test? ( test )"
-
-RDEPEND="
-	>=app-arch/brotli-1.0.9:=
-	>=dev-libs/libuv-1.39.0:=
-	>=net-dns/c-ares-1.17.2:=
-	>=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=
-		<dev-libs/openssl-3.0.0_beta1: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-jinja_collections_abc.patch
-	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
-	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
-	"${FILESDIR}"/${PN}-99999999-llhttp.patch
-)
-
-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
-			if tc-is-gcc; then
-				if [[ $(gcc-major-version) -ge 11 ]]; then
-					# Bug #787158
-					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
-				fi
-			else
-				# configure.py will abort on this later if we do not
-				die "${PN} only supports LTO for gcc"
-			fi
-		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
-
-	# Known-to-fail test of a deprecated, legacy HTTP parser. Just don't bother.
-	rm -f test/parallel/test-http-transfer-encoding-smuggling-legacy.js
-
-	# 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() {
-	if has usersandbox ${FEATURES}; then
-		rm -f "${S}"/test/parallel/test-fs-mkdir.js
-		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
-			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
-	fi
-
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -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.22.6.ebuild b/net-libs/nodejs/nodejs-12.22.6.ebuild
deleted file mode 100644
index fc7f6f38aaa1..000000000000
--- a/net-libs/nodejs/nodejs-12.22.6.ebuild
+++ /dev/null
@@ -1,249 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{8..10} )
-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/"
-LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
-
-if [[ ${PV} == *9999 ]]; then
-	inherit git-r3
-	EGIT_REPO_URI="https://github.com/nodejs/node"
-	SLOT="0"
-else
-	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
-	SLOT="0/$(ver_cut 1)"
-	KEYWORDS="amd64 arm arm64 ppc64 -riscv x86 ~amd64-linux ~x64-macos"
-	S="${WORKDIR}/node-v${PV}"
-fi
-
-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 )
-"
-
-RESTRICT="!test? ( test )"
-
-RDEPEND="
-	>=app-arch/brotli-1.0.9:=
-	>=dev-libs/libuv-1.39.0:=
-	>=net-dns/c-ares-1.17.2:=
-	>=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=
-		<dev-libs/openssl-3.0.0_beta1: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-jinja_collections_abc.patch
-	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
-	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
-	"${FILESDIR}"/${PN}-99999999-llhttp.patch
-)
-
-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
-			if tc-is-gcc; then
-				if [[ $(gcc-major-version) -ge 11 ]]; then
-					# Bug #787158
-					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
-				fi
-			else
-				# configure.py will abort on this later if we do not
-				die "${PN} only supports LTO for gcc"
-			fi
-		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
-
-	# Known-to-fail test of a deprecated, legacy HTTP parser. Just don't bother.
-	rm -f test/parallel/test-http-transfer-encoding-smuggling-legacy.js
-
-	# 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() {
-	if has usersandbox ${FEATURES}; then
-		rm -f "${S}"/test/parallel/test-fs-mkdir.js
-		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
-			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
-	fi
-
-	out/${BUILDTYPE}/cctest || die
-	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -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>"
-}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2022-05-04 19:02 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2022-05-04 19:02 UTC (permalink / raw
  To: gentoo-commits

commit:     06150adeff078a4cefa44939362f24059dbabfc2
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Wed May  4 19:00:49 2022 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Wed May  4 19:01:47 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=06150ade

Revert "net-libs/nodejs: drop 12.22.5-r1, 12.22.6, 12.22.10"

This reverts commit d790231b88ab650ac50f754719fa515128ce1119.
let's wait for node 18 to go stable.

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   3 +
 .../files/nodejs-12.20.1-fix_ppc64_crashes.patch   |  44 ++++
 .../nodejs-12.22.1-jinja_collections_abc.patch     |  95 ++++++++
 net-libs/nodejs/nodejs-12.22.10.ebuild             | 249 +++++++++++++++++++++
 net-libs/nodejs/nodejs-12.22.5-r1.ebuild           | 249 +++++++++++++++++++++
 net-libs/nodejs/nodejs-12.22.6.ebuild              | 249 +++++++++++++++++++++
 6 files changed, 889 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 0c6c3c7600cc..0b7285ce5651 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,3 +1,6 @@
+DIST node-v12.22.10.tar.xz 24089580 BLAKE2B 0ecf0b2ed64cba1bbcab287ccf7e524bd08ce787399d01fb792fd5232983289403a85810bc6eccd090b6d15796c48dc6ea3baf0cb3154e392dc343da53086b81 SHA512 da984e98856ef89eb259346d9d1eae60ff3d255d964f3b09d59851a9c21c86acd0c56b9c888f61423de07afab1c09946c00856c832a1f1a8abc4c671c31e23b1
+DIST node-v12.22.5.tar.xz 23654908 BLAKE2B ca4f304e31f091ae656142035851d6e4427d8b2ddd2a69506dec96efbb1269a19a08e9ab8d44dfe10f8429bc239e4102f3f030adb25e9c41901c7d94b53e88c8 SHA512 80f3c673a1f2af7fffd6aaa556c06b8225034c8413e1a738c19d491aff1b3e6ed388df66ecbff88e4bfbefe1013dac7e3beb301456c2099b6a954ba468b21883
+DIST node-v12.22.6.tar.xz 23664904 BLAKE2B 04dd4fd4cbe39642a1c3dd8639a4d9e3362055f56bc2565303d0095cda1655033ba4e0ce5a969647d2be73df13ddbcccc4907825a94a41b45c0723b3c02ca980 SHA512 d107f1ff7073d2db9f0198f14b0523870e9b262c71055de2e03fba54f87bc98a57dad43d902c0b349957df21de71dc066133d4831eb7eb07f4e548d0ac724fb2
 DIST node-v14.17.5.tar.xz 33585724 BLAKE2B cf79397caad8c81e4096f344f9fdb88d8ecea44b97fe208256dfd4afb750ecdf52142a2dc0430285b9d5117bdd43fa5ce42b4418926eec4d2c7f0a5f5d1a1539 SHA512 9d62c8946d05862d96a13a71b241a097b9f592a9e5f7362c81d8f3c74e7c5546a308b4c74bef34a66cafeef5d1a87d9d3e5ae8bb87d470c1ecf5abb8de0dedb5
 DIST node-v14.17.6.tar.xz 33606464 BLAKE2B c2c449e5eaf8214d7ed4bfab8db0208034cee1d08ef0e1fca478c30fc5cf95be037eb141080dbcfbe4fc58ef734457747dcbd0fe585a0536f9c0bec495435f25 SHA512 581c5698112426042fbf54fa793e56a30cae0c54ce8f23af6ac20d73c69a4f1166c5410f357c5a7b0409a773f99e3b9291e4afffd53b3c0e00569725dc4c47d3
 DIST node-v14.19.0.tar.xz 34486868 BLAKE2B 12e571a366c1d4b2475ef258e338f516bb81e9c08f7e6b7f951decbf371028cdcf32c72181d8504d0890496eaecce0d6b23437b8dad6c6e498d30bf6636bd1e7 SHA512 80573fa3a0882c1f2a40b991f187f49714748ca4c56c78133e2d2be0322f201816eb059a1a7d38ea8a925229c1b1324d0ffc28ff4002d0115bfae44fe87efe97

diff --git a/net-libs/nodejs/files/nodejs-12.20.1-fix_ppc64_crashes.patch b/net-libs/nodejs/files/nodejs-12.20.1-fix_ppc64_crashes.patch
new file mode 100644
index 000000000000..0982d3c81c2a
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-12.20.1-fix_ppc64_crashes.patch
@@ -0,0 +1,44 @@
+Backport of https://github.com/nodejs/node/pull/33866 to nodejs-12
+
+--- a/deps/v8/src/compiler/backend/instruction-selector.cc
++++ b/deps/v8/src/compiler/backend/instruction-selector.cc
+@@ -2788,7 +2788,7 @@
+   switch (call_descriptor->kind()) {
+     case CallDescriptor::kCallAddress: {
+       int misc_field = static_cast<int>(call_descriptor->ParameterCount());
+-#if defined(_AIX)
++#if ABI_USES_FUNCTION_DESCRIPTORS
+       // Highest misc_field bit is used on AIX to indicate if a CFunction call
+       // has function descriptor or not.
+       misc_field |= call_descriptor->HasFunctionDescriptor()
+--- a/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
++++ b/deps/v8/src/compiler/backend/ppc/code-generator-ppc.cc
+@@ -1026,7 +1026,7 @@
+       Label start_call;
+       bool isWasmCapiFunction =
+           linkage()->GetIncomingDescriptor()->IsWasmCapiFunction();
+-#if defined(_AIX)
++#if ABI_USES_FUNCTION_DESCRIPTORS
+       // AIX/PPC64BE Linux uses a function descriptor
+       int kNumParametersMask = kHasFunctionDescriptorBitMask - 1;
+       num_parameters = kNumParametersMask & misc_field;
+--- a/deps/v8/src/execution/simulator.h
++++ b/deps/v8/src/execution/simulator.h
+@@ -122,7 +122,7 @@
+ 
+   DISABLE_CFI_ICALL Return Call(Args... args) {
+     // When running without a simulator we call the entry directly.
+-#if V8_OS_AIX
++#if ABI_USES_FUNCTION_DESCRIPTORS
+     // AIX ABI requires function descriptors (FD).  Artificially create a pseudo
+     // FD to ensure correct dispatch to generated code.  The 'volatile'
+     // declaration is required to avoid the compiler from not observing the
+@@ -134,7 +134,7 @@
+     return fn(args...);
+ #else
+     return fn_ptr_(args...);
+-#endif  // V8_OS_AIX
++#endif  // ABI_USES_FUNCTION_DESCRIPTORS
+   }
+ #endif  // USE_SIMULATOR
+ 

diff --git a/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch b/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch
new file mode 100644
index 000000000000..5f0df09b6e2e
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch
@@ -0,0 +1,95 @@
+--- a/deps/v8/third_party/jinja2/tests.py
++++ b/deps/v8/third_party/jinja2/tests.py
+@@ -10,7 +10,7 @@
+ """
+ import operator
+ import re
+-from collections import Mapping
++from collections.abc import Mapping
+ from jinja2.runtime import Undefined
+ from jinja2._compat import text_type, string_types, integer_types
+ import decimal
+--- a/deps/v8/third_party/jinja2/runtime.py
++++ b/deps/v8/third_party/jinja2/runtime.py
+@@ -315,7 +315,7 @@ class Context(with_metaclass(ContextMeta)):
+ 
+ # register the context as mapping if possible
+ try:
+-    from collections import Mapping
++    from collections.abc import Mapping
+     Mapping.register(Context)
+ except ImportError:
+     pass
+--- a/deps/v8/third_party/jinja2/sandbox.py
++++ b/deps/v8/third_party/jinja2/sandbox.py
+@@ -14,7 +14,7 @@
+ """
+ import types
+ import operator
+-from collections import Mapping
++from collections.abc import Mapping
+ from jinja2.environment import Environment
+ from jinja2.exceptions import SecurityError
+ from jinja2._compat import string_types, PY2
+@@ -79,7 +79,7 @@ except ImportError:
+     pass
+ 
+ #: register Python 2.6 abstract base classes
+-from collections import MutableSet, MutableMapping, MutableSequence
++from collections.abc import MutableSet, MutableMapping, MutableSequence
+ _mutable_set_types += (MutableSet,)
+ _mutable_mapping_types += (MutableMapping,)
+ _mutable_sequence_types += (MutableSequence,)
+--- a/deps/v8/third_party/jinja2/utils.py
++++ b/deps/v8/third_party/jinja2/utils.py
+@@ -482,7 +482,7 @@ class LRUCache(object):
+ 
+ # register the LRU cache as mutable mapping if possible
+ try:
+-    from collections import MutableMapping
++    from collections.abc import MutableMapping
+     MutableMapping.register(LRUCache)
+ except ImportError:
+     pass
+--- a/tools/inspector_protocol/jinja2/runtime.py
++++ b/tools/inspector_protocol/jinja2/runtime.py
+@@ -315,7 +315,7 @@ class Context(with_metaclass(ContextMeta)):
+ 
+ # register the context as mapping if possible
+ try:
+-    from collections import Mapping
++    from collections.abc import Mapping
+     Mapping.register(Context)
+ except ImportError:
+     pass
+--- a/tools/inspector_protocol/jinja2/sandbox.py
++++ b/tools/inspector_protocol/jinja2/sandbox.py
+@@ -14,7 +14,7 @@
+ """
+ import types
+ import operator
+-from collections import Mapping
++from collections.abc import Mapping
+ from jinja2.environment import Environment
+ from jinja2.exceptions import SecurityError
+ from jinja2._compat import string_types, PY2
+@@ -79,7 +79,7 @@ except ImportError:
+     pass
+ 
+ #: register Python 2.6 abstract base classes
+-from collections import MutableSet, MutableMapping, MutableSequence
++from collections.abc import MutableSet, MutableMapping, MutableSequence
+ _mutable_set_types += (MutableSet,)
+ _mutable_mapping_types += (MutableMapping,)
+ _mutable_sequence_types += (MutableSequence,)
+--- a/tools/inspector_protocol/jinja2/tests.py
++++ b/tools/inspector_protocol/jinja2/tests.py
+@@ -10,7 +10,7 @@
+ """
+ import operator
+ import re
+-from collections import Mapping
++from collections.abc import Mapping
+ from jinja2.runtime import Undefined
+ from jinja2._compat import text_type, string_types, integer_types
+ import decimal

diff --git a/net-libs/nodejs/nodejs-12.22.10.ebuild b/net-libs/nodejs/nodejs-12.22.10.ebuild
new file mode 100644
index 000000000000..4638f6304808
--- /dev/null
+++ b/net-libs/nodejs/nodejs-12.22.10.ebuild
@@ -0,0 +1,249 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+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/"
+LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
+
+if [[ ${PV} == *9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/nodejs/node"
+	SLOT="0"
+else
+	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
+	SLOT="0/$(ver_cut 1)"
+	KEYWORDS="amd64 ~arm arm64 ppc64 -riscv x86 ~amd64-linux ~x64-macos"
+	S="${WORKDIR}/node-v${PV}"
+fi
+
+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 )
+"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	>=app-arch/brotli-1.0.9:=
+	>=dev-libs/libuv-1.39.0:=
+	>=net-dns/c-ares-1.17.2:=
+	>=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=
+		<dev-libs/openssl-3.0.0_beta1:0=
+	)
+"
+BDEPEND="
+	${PYTHON_DEPS}
+	sys-apps/coreutils
+	virtual/pkgconfig
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )
+"
+DEPEND="
+	${RDEPEND}
+"
+PATCHES=(
+	"${FILESDIR}"/${P}-global-npm-config.patch
+	"${FILESDIR}"/${PN}-12.20.1-fix_ppc64_crashes.patch
+	"${FILESDIR}"/${PN}-12.22.1-jinja_collections_abc.patch
+	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
+	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
+	"${FILESDIR}"/${PN}-99999999-llhttp.patch
+)
+
+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
+			if tc-is-gcc; then
+				if [[ $(gcc-major-version) -ge 11 ]]; then
+					# Bug #787158
+					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
+				fi
+			else
+				# configure.py will abort on this later if we do not
+				die "${PN} only supports LTO for gcc"
+			fi
+		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
+
+	# Known-to-fail test of a deprecated, legacy HTTP parser. Just don't bother.
+	rm -f test/parallel/test-http-transfer-encoding-smuggling-legacy.js
+
+	# 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() {
+	if has usersandbox ${FEATURES}; then
+		rm -f "${S}"/test/parallel/test-fs-mkdir.js
+		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
+			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
+	fi
+
+	out/${BUILDTYPE}/cctest || die
+	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -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.22.5-r1.ebuild b/net-libs/nodejs/nodejs-12.22.5-r1.ebuild
new file mode 100644
index 000000000000..1e716cbf5e85
--- /dev/null
+++ b/net-libs/nodejs/nodejs-12.22.5-r1.ebuild
@@ -0,0 +1,249 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{8..10} )
+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/"
+LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
+
+if [[ ${PV} == *9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/nodejs/node"
+	SLOT="0"
+else
+	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
+	SLOT="0/$(ver_cut 1)"
+	KEYWORDS="amd64 arm arm64 ppc64 -riscv x86 ~amd64-linux ~x64-macos"
+	S="${WORKDIR}/node-v${PV}"
+fi
+
+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 )
+"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	>=app-arch/brotli-1.0.9:=
+	>=dev-libs/libuv-1.39.0:=
+	>=net-dns/c-ares-1.17.2:=
+	>=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=
+		<dev-libs/openssl-3.0.0_beta1: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-jinja_collections_abc.patch
+	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
+	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
+	"${FILESDIR}"/${PN}-99999999-llhttp.patch
+)
+
+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
+			if tc-is-gcc; then
+				if [[ $(gcc-major-version) -ge 11 ]]; then
+					# Bug #787158
+					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
+				fi
+			else
+				# configure.py will abort on this later if we do not
+				die "${PN} only supports LTO for gcc"
+			fi
+		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
+
+	# Known-to-fail test of a deprecated, legacy HTTP parser. Just don't bother.
+	rm -f test/parallel/test-http-transfer-encoding-smuggling-legacy.js
+
+	# 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() {
+	if has usersandbox ${FEATURES}; then
+		rm -f "${S}"/test/parallel/test-fs-mkdir.js
+		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
+			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
+	fi
+
+	out/${BUILDTYPE}/cctest || die
+	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -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.22.6.ebuild b/net-libs/nodejs/nodejs-12.22.6.ebuild
new file mode 100644
index 000000000000..fc7f6f38aaa1
--- /dev/null
+++ b/net-libs/nodejs/nodejs-12.22.6.ebuild
@@ -0,0 +1,249 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+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/"
+LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
+
+if [[ ${PV} == *9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/nodejs/node"
+	SLOT="0"
+else
+	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
+	SLOT="0/$(ver_cut 1)"
+	KEYWORDS="amd64 arm arm64 ppc64 -riscv x86 ~amd64-linux ~x64-macos"
+	S="${WORKDIR}/node-v${PV}"
+fi
+
+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 )
+"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	>=app-arch/brotli-1.0.9:=
+	>=dev-libs/libuv-1.39.0:=
+	>=net-dns/c-ares-1.17.2:=
+	>=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=
+		<dev-libs/openssl-3.0.0_beta1: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-jinja_collections_abc.patch
+	"${FILESDIR}"/${PN}-12.22.1-uvwasi_shared_libuv.patch
+	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
+	"${FILESDIR}"/${PN}-99999999-llhttp.patch
+)
+
+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
+			if tc-is-gcc; then
+				if [[ $(gcc-major-version) -ge 11 ]]; then
+					# Bug #787158
+					die "LTO builds of ${PN} using gcc-11+ currently fail tests and produce runtime errors. Either switch to gcc-10 or unset USE=lto for this ebuild"
+				fi
+			else
+				# configure.py will abort on this later if we do not
+				die "${PN} only supports LTO for gcc"
+			fi
+		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
+
+	# Known-to-fail test of a deprecated, legacy HTTP parser. Just don't bother.
+	rm -f test/parallel/test-http-transfer-encoding-smuggling-legacy.js
+
+	# 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() {
+	if has usersandbox ${FEATURES}; then
+		rm -f "${S}"/test/parallel/test-fs-mkdir.js
+		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
+			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
+	fi
+
+	out/${BUILDTYPE}/cctest || die
+	"${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -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>"
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2022-06-11 21:04 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2022-06-11 21:04 UTC (permalink / raw
  To: gentoo-commits

commit:     1cd2102cc5fc36973c064aa19da9e0d6d82d9d8d
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Sat Jun 11 21:00:35 2022 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Sat Jun 11 21:03:19 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1cd2102c

net-libs/nodejs: update 18.3.0 pax marking patch

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 .../nodejs/files/nodejs-18.3.0-paxmarking.patch    | 85 ++++++++++++++++++++++
 net-libs/nodejs/nodejs-18.3.0.ebuild               |  2 +-
 2 files changed, 86 insertions(+), 1 deletion(-)

diff --git a/net-libs/nodejs/files/nodejs-18.3.0-paxmarking.patch b/net-libs/nodejs/files/nodejs-18.3.0-paxmarking.patch
new file mode 100644
index 000000000000..fd7ef431045e
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-18.3.0-paxmarking.patch
@@ -0,0 +1,85 @@
+diff -urNp node-v15.8.0-orig/node.gyp node-v15.8.0-dwok/node.gyp
+--- node-v15.8.0-orig/node.gyp	2021-02-24 22:21:44.202911780 +0100
++++ node-v15.8.0-dwok/node.gyp	2021-02-24 22:25:34.298281739 +0100
+@@ -55,6 +55,7 @@
+       'deps/undici/undici.js',
+     ],
+     'node_mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot<(EXECUTABLE_SUFFIX)',
++    'node_mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'conditions': [
+       ['GENERATOR == "ninja"', {
+         'node_text_start_object_path': 'src/large_pages/node_text_start.node_text_start.o'
+@@ -331,10 +332,24 @@
+             }, {
+               'actions': [
+                 {
++                  'action_name': 'run_pax_mksnapshot',
++                  'inputs': [
++                    '<(node_mksnapshot_exec)',
++                  ],
++                  'outputs': [
++                    '<(node_mksnapshot_u_exec)',
++                  ],
++                  'action': [
++                    'bash',
++                    '-c',
++                    'mv <(node_mksnapshot_exec) <(node_mksnapshot_u_exec) && paxmark.sh m <(node_mksnapshot_u_exec)',
++                  ],
++                },
++                {
+                   'action_name': 'node_mksnapshot',
+                   'process_outputs_as_sources': 1,
+                   'inputs': [
+-                    '<(node_mksnapshot_exec)',
++                    '<(node_mksnapshot_u_exec)',
+                   ],
+                   'outputs': [
+                     '<(SHARED_INTERMEDIATE_DIR)/node_snapshot.cc',
+diff -urNp node-v15.8.0-orig/tools/v8_gypfiles/v8.gyp node-v15.8.0-dwok/tools/v8_gypfiles/v8.gyp
+--- node-v15.8.0-orig/tools/v8_gypfiles/v8.gyp	2021-02-24 22:21:44.654910571 +0100
++++ node-v15.8.0-dwok/tools/v8_gypfiles/v8.gyp	2021-02-24 22:25:54.834224791 +0100
+@@ -9,6 +9,7 @@
+     'v8_vector_stores%': 0,
+     'v8_embed_script%': "",
+     'mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
++    'mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'v8_os_page_size%': 0,
+     'generate_bytecode_output_root': '<(SHARED_INTERMEDIATE_DIR)/generate-bytecode-output-root',
+     'generate_bytecode_builtins_list_output': '<(generate_bytecode_output_root)/builtins-generated/bytecodes-builtins-list.h',
+@@ -1413,7 +1414,7 @@
+       ],
+     },  # bytecode_builtins_list_generator
+     {
+-      'target_name': 'mksnapshot',
++      'target_name': 'mksnapshot_u',
+       'type': 'executable',
+       'dependencies': [
+         'v8_base_without_compiler',
+@@ -1432,6 +1433,27 @@
+           'toolsets': ['host'],
+         }],
+       ],
++    },  # mksnapshot_u
++    {
++      'target_name': 'mksnapshot',
++      'type': 'none',
++      'dependencies': ['mksnapshot_u'],
++      'actions': [
++        {
++          'action_name': 'paxmark_mksnapshot',
++          'inputs': [
++            '<(mksnapshot_u_exec)',
++          ],
++          'outputs': [
++            '<(mksnapshot_exec)',
++          ],
++          'action': [
++            'bash',
++            '-c',
++            'cp <(mksnapshot_u_exec) <(mksnapshot_exec) && paxmark.sh m <(mksnapshot_exec)'
++          ],
++        },
++      ],
+     },  # mksnapshot
+     {
+       'target_name': 'torque',

diff --git a/net-libs/nodejs/nodejs-18.3.0.ebuild b/net-libs/nodejs/nodejs-18.3.0.ebuild
index ca608fd9201a..ab8116548114 100644
--- a/net-libs/nodejs/nodejs-18.3.0.ebuild
+++ b/net-libs/nodejs/nodejs-18.3.0.ebuild
@@ -85,7 +85,7 @@ src_prepare() {
 	fi
 
 	# We need to disable mprotect on two files when it builds Bug 694100.
-	use pax-kernel && PATCHES+=( "${FILESDIR}"/${PN}-18.0.0-paxmarking.patch )
+	use pax-kernel && PATCHES+=( "${FILESDIR}"/${PN}-18.3.0-paxmarking.patch )
 
 	# All this test does is check if the npm CLI produces warnings of any sort,
 	# failing if it does. Overkill, much? Especially given one possible warning


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2022-09-14  6:14 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2022-09-14  6:14 UTC (permalink / raw
  To: gentoo-commits

commit:     b8ed541d56fe430d8c9d88924de1700db65d37fe
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Wed Sep 14 06:11:19 2022 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Wed Sep 14 06:14:20 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b8ed541d

net-libs/nodejs: add 18.9.0

Closes: https://github.com/gentoo/gentoo/pull/27242
Bug: https://bugs.gentoo.org/869992
Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 +
 .../files/nodejs-18.9.0-clang-fix-libatomic.patch  |  16 ++
 net-libs/nodejs/nodejs-18.9.0.ebuild               | 246 +++++++++++++++++++++
 3 files changed, 263 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index ba40dcfe845a..e666bf77bd2f 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -3,3 +3,4 @@ DIST node-v16.16.0.tar.xz 35039712 BLAKE2B e4cf7debda3d32b515d60d11ac7ebd788fdab
 DIST node-v16.17.0.tar.xz 35664964 BLAKE2B 490bcb65440a81d356f6351c45b19a4022cd55834b8b90da9eed2006042ab73732d581d58983b34b12ddef618d3e99fe760ef93447a2201268e2ab86466d3bb1 SHA512 8906ee337562b6f0b1614aa57084499ffd3bdfe8f8e706de8fed98baed5a92f691c534528b98f6321cf8a1eaaed6b45a938f28bd08167fbd75bfeb432ca03181
 DIST node-v18.6.0.tar.xz 37189620 BLAKE2B 15a8a874f39db7de576d3ba81fddcb8072cb170ebb12308d2ade2efb9c8200c561671f453371a16db82d4c0f02522a28f6ae01216d11be40df94b53b184828b3 SHA512 d682e25a71ffbef90e2cb3c55e22dbd548952c4de24d48c47206afd270fd17c7bda95b3241840bf6a470f28d2389f3c6fddbb812ad17cf1d36262ff25fcda859
 DIST node-v18.7.0.tar.xz 36945328 BLAKE2B 8ec945347ba396f7c65f544325690abdece4aa82ce1dae63e56662c78f445845f3f858a803ee2b130444f44cd38f4e1d8f5df0240d5a0c5124a38cbab42daafc SHA512 3da56b25f304b4e205c27a59f2e442e7216e494465e4cce9f51ffd3f7c7da3ab3519c4b7d1eb41a754b86ecfa1d138d270578aa3908b4fd42cc5dbfd389a6798
+DIST node-v18.9.0.tar.xz 38309908 BLAKE2B 87ce3e45c6450bc686fe800a9c39a6c0cb5c01279c3052431455c29e0fc0b244de122dd899a43da1e8291fe60457847d307c7193c4e69f2d6f6b8824f4555daf SHA512 60bf98bc5011876429c9a687141b916fc6023ba21f1a641fef2f11d53218db24f442542382495455d2f107d708fcd04994e239a9bbfb52f070935c9048089e81

diff --git a/net-libs/nodejs/files/nodejs-18.9.0-clang-fix-libatomic.patch b/net-libs/nodejs/files/nodejs-18.9.0-clang-fix-libatomic.patch
new file mode 100644
index 000000000000..5296ed1318b0
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-18.9.0-clang-fix-libatomic.patch
@@ -0,0 +1,16 @@
+https://bugs.gentoo.org/869992
+
+diff --git a/node.gyp b/node.gyp
+index 347d82d2e1..8c4ffea256 100644
+--- a/node.gyp
++++ b/node.gyp
+@@ -117,9 +117,6 @@
+           '-Wl,-bnoerrmsg',
+         ],
+       }],
+-      ['OS == "linux" and llvm_version != "0.0"', {
+-        'libraries': ['-latomic'],
+-      }],
+     ],
+   },
+

diff --git a/net-libs/nodejs/nodejs-18.9.0.ebuild b/net-libs/nodejs/nodejs-18.9.0.ebuild
new file mode 100644
index 000000000000..03af59cf2a80
--- /dev/null
+++ b/net-libs/nodejs/nodejs-18.9.0.ebuild
@@ -0,0 +1,246 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CONFIG_CHECK="~ADVISE_SYSCALLS"
+PYTHON_COMPAT=( python3_{8..11} )
+PYTHON_REQ_USE="threads(+)"
+
+inherit bash-completion-r1 check-reqs flag-o-matic linux-info pax-utils python-any-r1 toolchain-funcs xdg-utils
+
+DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine"
+HOMEPAGE="https://nodejs.org/"
+LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
+
+if [[ ${PV} == *9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/nodejs/node"
+	SLOT="0"
+else
+	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
+	SLOT="0/$(ver_cut 1)"
+	KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc64 ~riscv ~x86 ~amd64-linux ~x64-macos"
+	S="${WORKDIR}/node-v${PV}"
+fi
+
+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 )"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND=">=app-arch/brotli-1.0.9:=
+	>=dev-libs/libuv-1.40.0:=
+	>=net-dns/c-ares-1.17.2:=
+	>=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}-12.22.5-shared_c-ares_nameser_h.patch
+	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
+	"${FILESDIR}"/${P}-clang-fix-libatomic.patch
+)
+
+# These are measured on a loong machine with -ggdb on, and only checked
+# if debugging flags are present in CFLAGS.
+#
+# The final link consumed a little more than 7GiB alone, so 8GiB is the lower
+# limit for memory usage. Disk usage was 19.1GiB for the build directory and
+# 1.2GiB for the installed image, so we leave some room for architectures with
+# fatter binaries and set the disk requirement to 22GiB.
+CHECKREQS_MEMORY="8G"
+CHECKREQS_DISK_BUILD="22G"
+
+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 is-flagq "-g*" && ! is-flagq "-g*0" ; then
+			einfo "Checking for sufficient disk space and memory to build ${PN} with debugging CFLAGS"
+			check-reqs_pkg_pretend
+		fi
+	fi
+}
+
+pkg_setup() {
+	python-any-r1_pkg_setup
+	linux-info_pkg_setup
+}
+
+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
+
+	# 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}-18.3.0-paxmarking.patch )
+
+	# All this test does is check if the npm CLI produces warnings of any sort,
+	# failing if it does. Overkill, much? Especially given one possible warning
+	# is that there is a newer version of npm available upstream (yes, it does
+	# use the network if available), thus making it a real possibility for this
+	# test to begin failing one day even though it was fine before.
+	rm -f test/parallel/test-release-npm.js
+
+	default
+}
+
+src_configure() {
+	xdg_environment_reset
+
+	# LTO compiler flags are handled by configure.py itself
+	filter-flags '-flto*'
+	# nodejs unconditionally links to libatomic #869992
+	append-atomic-flags
+
+	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 "${ARCH}:${ABI}" in
+		*:amd64) myarch="x64";;
+		*:arm) myarch="arm";;
+		*:arm64) myarch="arm64";;
+		loong:lp64*) myarch="loong64";;
+		riscv:lp64*) myarch="riscv64";;
+		*: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
+		keepdir /etc/npm
+
+		# Install bash completion for `npm`
+		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
+
+		# 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() {
+	if has usersandbox ${FEATURES}; then
+		rm -f "${S}"/test/parallel/test-fs-mkdir.js
+		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
+			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
+	fi
+
+	out/${BUILDTYPE}/cctest || die
+	"${EPYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -J message parallel sequential || die
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2022-09-16 16:16 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2022-09-16 16:16 UTC (permalink / raw
  To: gentoo-commits

commit:     7dc748f875d8f1a7bda9d0b8c00d45ad4be2d58d
Author:     matoro <matoro <AT> users <DOT> noreply <DOT> github <DOT> com>
AuthorDate: Thu Sep 15 18:46:37 2022 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Fri Sep 16 16:15:16 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7dc748f8

net-libs/nodejs: delete libatomic patch + force libgcc as support lib

Upstream behavior is correct wrt libatomic (unconditionally adding it)
due to their use of atomic_is_lock_free which is yet to be added to
compiler-rt (stuck in review hell at https://reviews.llvm.org/D85044).

This necessitates forcing libgcc as support lib.  Linking to libatomic
from gcc is dynamic, so sys-devel/gcc has to go in RDEPEND.  Clang can
be forced to use libgcc with --rtlib=libgcc, even with
USE=default-compiler-rt (which is the original cuase of the bug in
question).

Closes: https://bugs.gentoo.org/869992
Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 .../nodejs/files/nodejs-18.9.0-clang-fix-libatomic.patch | 16 ----------------
 net-libs/nodejs/nodejs-18.9.0.ebuild                     | 10 +++++++---
 2 files changed, 7 insertions(+), 19 deletions(-)

diff --git a/net-libs/nodejs/files/nodejs-18.9.0-clang-fix-libatomic.patch b/net-libs/nodejs/files/nodejs-18.9.0-clang-fix-libatomic.patch
deleted file mode 100644
index 5296ed1318b0..000000000000
--- a/net-libs/nodejs/files/nodejs-18.9.0-clang-fix-libatomic.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-https://bugs.gentoo.org/869992
-
-diff --git a/node.gyp b/node.gyp
-index 347d82d2e1..8c4ffea256 100644
---- a/node.gyp
-+++ b/node.gyp
-@@ -117,9 +117,6 @@
-           '-Wl,-bnoerrmsg',
-         ],
-       }],
--      ['OS == "linux" and llvm_version != "0.0"', {
--        'libraries': ['-latomic'],
--      }],
-     ],
-   },
-

diff --git a/net-libs/nodejs/nodejs-18.9.0.ebuild b/net-libs/nodejs/nodejs-18.9.0.ebuild
index 03af59cf2a80..6c803a2495ee 100644
--- a/net-libs/nodejs/nodejs-18.9.0.ebuild
+++ b/net-libs/nodejs/nodejs-18.9.0.ebuild
@@ -38,7 +38,8 @@ RDEPEND=">=app-arch/brotli-1.0.9:=
 	>=net-libs/nghttp2-1.41.0:=
 	sys-libs/zlib
 	system-icu? ( >=dev-libs/icu-67:= )
-	system-ssl? ( >=dev-libs/openssl-1.1.1:0= )"
+	system-ssl? ( >=dev-libs/openssl-1.1.1:0= )
+	sys-devel/gcc:*"
 BDEPEND="${PYTHON_DEPS}
 	sys-apps/coreutils
 	virtual/pkgconfig
@@ -50,7 +51,6 @@ DEPEND="${RDEPEND}"
 PATCHES=(
 	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
 	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
-	"${FILESDIR}"/${P}-clang-fix-libatomic.patch
 )
 
 # These are measured on a loong machine with -ggdb on, and only checked
@@ -127,7 +127,11 @@ src_configure() {
 	# LTO compiler flags are handled by configure.py itself
 	filter-flags '-flto*'
 	# nodejs unconditionally links to libatomic #869992
-	append-atomic-flags
+	# specifically it requires __atomic_is_lock_free which
+	# is not yet implemented by sys-libs/compiler-rt (see
+	# https://reviews.llvm.org/D85044?id=287068), therefore
+	# we depend on gcc and force using libgcc as the support lib
+	tc-is-clang && append-ldflags "--rtlib=libgcc --unwindlib=libgcc"
 
 	local myconf=(
 		--shared-brotli


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2022-10-28 15:57 Sam James
  0 siblings, 0 replies; 36+ messages in thread
From: Sam James @ 2022-10-28 15:57 UTC (permalink / raw
  To: gentoo-commits

commit:     a5c7606a4cf5173622127ea833cdf7880aa786a9
Author:     WANG Xuerui <xen0n <AT> gentoo <DOT> org>
AuthorDate: Wed Oct  5 08:39:01 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Oct 28 15:57:12 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a5c7606a

net-libs/nodejs: fix build on gcc-13

Closes: https://bugs.gentoo.org/865981
Closes: https://github.com/gentoo/gentoo/pull/27654
Signed-off-by: WANG Xuerui <xen0n <AT> gentoo.org>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-libs/nodejs/files/nodejs-gcc-13.patch | 27 +++++++++++++++++++++++++++
 net-libs/nodejs/nodejs-14.20.1.ebuild     |  1 +
 net-libs/nodejs/nodejs-16.17.1.ebuild     |  1 +
 net-libs/nodejs/nodejs-18.10.0.ebuild     |  1 +
 net-libs/nodejs/nodejs-18.9.1.ebuild      |  1 +
 5 files changed, 31 insertions(+)

diff --git a/net-libs/nodejs/files/nodejs-gcc-13.patch b/net-libs/nodejs/files/nodejs-gcc-13.patch
new file mode 100644
index 000000000000..13427a6b7407
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-gcc-13.patch
@@ -0,0 +1,27 @@
+https://chromium-review.googlesource.com/c/v8/v8/+/3934140
+adjusted to layout of the node project
+From: WANG Xuerui <git@xen0n.name>
+Date: Tue, 4 Oct 2022 17:21:03 +0800
+Subject: [PATCH] [base] Fix build with gcc-13
+
+See https://gcc.gnu.org/gcc-13/porting_to.html#header-dep-changes.
+--- a/deps/v8/src/base/logging.h
++++ b/deps/v8/src/base/logging.h
+@@ -5,6 +5,7 @@
+ #ifndef V8_BASE_LOGGING_H_
+ #define V8_BASE_LOGGING_H_
+ 
++#include <cstdint>
+ #include <cstring>
+ #include <sstream>
+ #include <string>
+--- a/deps/v8/src/inspector/v8-string-conversions.h
++++ b/deps/v8/src/inspector/v8-string-conversions.h
+@@ -5,6 +5,7 @@
+ #ifndef V8_INSPECTOR_V8_STRING_CONVERSIONS_H_
+ #define V8_INSPECTOR_V8_STRING_CONVERSIONS_H_
+ 
++#include <cstdint>
+ #include <string>
+ 
+ // Conversion routines between UT8 and UTF16, used by string-16.{h,cc}. You may

diff --git a/net-libs/nodejs/nodejs-14.20.1.ebuild b/net-libs/nodejs/nodejs-14.20.1.ebuild
index ec4700ccab22..c2dfc7980d1c 100644
--- a/net-libs/nodejs/nodejs-14.20.1.ebuild
+++ b/net-libs/nodejs/nodejs-14.20.1.ebuild
@@ -55,6 +55,7 @@ PATCHES=(
 	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
 	"${FILESDIR}"/${PN}-14.15.0-fix_ppc64_crashes.patch
 	"${FILESDIR}"/${PN}-14.19.0-global-npm-config.patch
+	"${FILESDIR}"/${PN}-gcc-13.patch
 )
 
 pkg_pretend() {

diff --git a/net-libs/nodejs/nodejs-16.17.1.ebuild b/net-libs/nodejs/nodejs-16.17.1.ebuild
index c1fd507566a4..9492c22083ac 100644
--- a/net-libs/nodejs/nodejs-16.17.1.ebuild
+++ b/net-libs/nodejs/nodejs-16.17.1.ebuild
@@ -51,6 +51,7 @@ DEPEND="${RDEPEND}"
 PATCHES=(
 	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
 	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
+	"${FILESDIR}"/${PN}-gcc-13.patch
 )
 
 pkg_pretend() {

diff --git a/net-libs/nodejs/nodejs-18.10.0.ebuild b/net-libs/nodejs/nodejs-18.10.0.ebuild
index 3ffd13f46228..fec5881c4739 100644
--- a/net-libs/nodejs/nodejs-18.10.0.ebuild
+++ b/net-libs/nodejs/nodejs-18.10.0.ebuild
@@ -51,6 +51,7 @@ DEPEND="${RDEPEND}"
 PATCHES=(
 	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
 	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
+	"${FILESDIR}"/${PN}-gcc-13.patch
 )
 
 # These are measured on a loong machine with -ggdb on, and only checked

diff --git a/net-libs/nodejs/nodejs-18.9.1.ebuild b/net-libs/nodejs/nodejs-18.9.1.ebuild
index 9d98aef6f3b6..c4fe0dccc534 100644
--- a/net-libs/nodejs/nodejs-18.9.1.ebuild
+++ b/net-libs/nodejs/nodejs-18.9.1.ebuild
@@ -51,6 +51,7 @@ DEPEND="${RDEPEND}"
 PATCHES=(
 	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
 	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
+	"${FILESDIR}"/${PN}-gcc-13.patch
 )
 
 # These are measured on a loong machine with -ggdb on, and only checked


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2023-03-05 23:18 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2023-03-05 23:18 UTC (permalink / raw
  To: gentoo-commits

commit:     713b1cd96ba4dabedac15b5ba2596a434d28fba2
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Sun Mar  5 23:11:15 2023 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Sun Mar  5 23:18:47 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=713b1cd9

net-libs/nodejs: drop local copy of ares_nameser.h

This has been added to the public API of c-ares for a while.
All versions of nodejs build with this patch dropped.

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 .../nodejs-12.22.5-shared_c-ares_nameser_h.patch   | 534 ---------------------
 net-libs/nodejs/nodejs-14.21.3.ebuild              |   1 -
 net-libs/nodejs/nodejs-16.19.1.ebuild              |   1 -
 net-libs/nodejs/nodejs-18.14.2.ebuild              |   4 -
 net-libs/nodejs/nodejs-99999999.ebuild             |   4 -
 5 files changed, 544 deletions(-)

diff --git a/net-libs/nodejs/files/nodejs-12.22.5-shared_c-ares_nameser_h.patch b/net-libs/nodejs/files/nodejs-12.22.5-shared_c-ares_nameser_h.patch
deleted file mode 100644
index f90084c2bb2e..000000000000
--- a/net-libs/nodejs/files/nodejs-12.22.5-shared_c-ares_nameser_h.patch
+++ /dev/null
@@ -1,534 +0,0 @@
-From aff98a5667c22794e2eaf658f6dfbee54cdd4a3b Mon Sep 17 00:00:00 2001
-From: Felix Yan <felixonmars@archlinux.org>
-Date: Thu, 12 Aug 2021 02:44:43 +0800
-Subject: [PATCH 1/2] deps: fix building with system c-ares on Linux
-
-The change in #39724 breaks building with system c-ares
-(`--shared-cares`):
-```
-In file included from ../src/cares_wrap.cc:25:
-../src/cares_wrap.h:25:11: fatal error: ares_nameser.h: No such file or
-directory
-   25 | # include <ares_nameser.h>
-      |           ^~~~~~~~~~~~~~~~
-```
-
-Since `ares_nameser.h` isn't available with a default system c-ares
-installation, let's copy it as our private header here.
-
-Tested to build fine on Arch Linux with shared c-ares.
----
- src/ares_nameser.h | 482 +++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 482 insertions(+)
- create mode 100644 src/ares_nameser.h
-
-diff --git a/src/ares_nameser.h b/src/ares_nameser.h
-new file mode 100644
-index 000000000000..5270e5a3a6a0
---- /dev/null
-+++ b/src/ares_nameser.h
-@@ -0,0 +1,482 @@
-+
-+#ifndef ARES_NAMESER_H
-+#define ARES_NAMESER_H
-+
-+#ifdef HAVE_ARPA_NAMESER_H
-+#  include <arpa/nameser.h>
-+#endif
-+#ifdef HAVE_ARPA_NAMESER_COMPAT_H
-+#  include <arpa/nameser_compat.h>
-+#endif
-+
-+/* ============================================================================
-+ * arpa/nameser.h may or may not provide ALL of the below defines, so check
-+ * each one individually and set if not
-+ * ============================================================================
-+ */
-+
-+#ifndef NS_PACKETSZ
-+#  define NS_PACKETSZ     512   /* maximum packet size */
-+#endif
-+
-+#ifndef NS_MAXDNAME
-+#  define NS_MAXDNAME     256   /* maximum domain name */
-+#endif
-+
-+#ifndef NS_MAXCDNAME
-+#  define NS_MAXCDNAME    255   /* maximum compressed domain name */
-+#endif
-+
-+#ifndef NS_MAXLABEL
-+#  define NS_MAXLABEL     63
-+#endif
-+
-+#ifndef NS_HFIXEDSZ
-+#  define NS_HFIXEDSZ     12    /* #/bytes of fixed data in header */
-+#endif
-+
-+#ifndef NS_QFIXEDSZ
-+#  define NS_QFIXEDSZ     4     /* #/bytes of fixed data in query */
-+#endif
-+
-+#ifndef NS_RRFIXEDSZ
-+#  define NS_RRFIXEDSZ    10    /* #/bytes of fixed data in r record */
-+#endif
-+
-+#ifndef NS_INT16SZ
-+#  define NS_INT16SZ      2
-+#endif
-+
-+#ifndef NS_INADDRSZ
-+#  define NS_INADDRSZ     4
-+#endif
-+
-+#ifndef NS_IN6ADDRSZ
-+#  define NS_IN6ADDRSZ    16
-+#endif
-+
-+#ifndef NS_CMPRSFLGS
-+#  define NS_CMPRSFLGS    0xc0  /* Flag bits indicating name compression. */
-+#endif
-+
-+#ifndef NS_DEFAULTPORT
-+#  define NS_DEFAULTPORT  53    /* For both TCP and UDP. */
-+#endif
-+
-+/* ============================================================================
-+ * arpa/nameser.h should provide these enumerations always, so if not found,
-+ * provide them
-+ * ============================================================================
-+ */
-+#ifndef HAVE_ARPA_NAMESER_H
-+
-+typedef enum __ns_class {
-+    ns_c_invalid = 0,       /* Cookie. */
-+    ns_c_in = 1,            /* Internet. */
-+    ns_c_2 = 2,             /* unallocated/unsupported. */
-+    ns_c_chaos = 3,         /* MIT Chaos-net. */
-+    ns_c_hs = 4,            /* MIT Hesiod. */
-+    /* Query class values which do not appear in resource records */
-+    ns_c_none = 254,        /* for prereq. sections in update requests */
-+    ns_c_any = 255,         /* Wildcard match. */
-+    ns_c_max = 65536
-+} ns_class;
-+
-+typedef enum __ns_type {
-+    ns_t_invalid = 0,       /* Cookie. */
-+    ns_t_a = 1,             /* Host address. */
-+    ns_t_ns = 2,            /* Authoritative server. */
-+    ns_t_md = 3,            /* Mail destination. */
-+    ns_t_mf = 4,            /* Mail forwarder. */
-+    ns_t_cname = 5,         /* Canonical name. */
-+    ns_t_soa = 6,           /* Start of authority zone. */
-+    ns_t_mb = 7,            /* Mailbox domain name. */
-+    ns_t_mg = 8,            /* Mail group member. */
-+    ns_t_mr = 9,            /* Mail rename name. */
-+    ns_t_null = 10,         /* Null resource record. */
-+    ns_t_wks = 11,          /* Well known service. */
-+    ns_t_ptr = 12,          /* Domain name pointer. */
-+    ns_t_hinfo = 13,        /* Host information. */
-+    ns_t_minfo = 14,        /* Mailbox information. */
-+    ns_t_mx = 15,           /* Mail routing information. */
-+    ns_t_txt = 16,          /* Text strings. */
-+    ns_t_rp = 17,           /* Responsible person. */
-+    ns_t_afsdb = 18,        /* AFS cell database. */
-+    ns_t_x25 = 19,          /* X_25 calling address. */
-+    ns_t_isdn = 20,         /* ISDN calling address. */
-+    ns_t_rt = 21,           /* Router. */
-+    ns_t_nsap = 22,         /* NSAP address. */
-+    ns_t_nsap_ptr = 23,     /* Reverse NSAP lookup (deprecated). */
-+    ns_t_sig = 24,          /* Security signature. */
-+    ns_t_key = 25,          /* Security key. */
-+    ns_t_px = 26,           /* X.400 mail mapping. */
-+    ns_t_gpos = 27,         /* Geographical position (withdrawn). */
-+    ns_t_aaaa = 28,         /* Ip6 Address. */
-+    ns_t_loc = 29,          /* Location Information. */
-+    ns_t_nxt = 30,          /* Next domain (security). */
-+    ns_t_eid = 31,          /* Endpoint identifier. */
-+    ns_t_nimloc = 32,       /* Nimrod Locator. */
-+    ns_t_srv = 33,          /* Server Selection. */
-+    ns_t_atma = 34,         /* ATM Address */
-+    ns_t_naptr = 35,        /* Naming Authority PoinTeR */
-+    ns_t_kx = 36,           /* Key Exchange */
-+    ns_t_cert = 37,         /* Certification record */
-+    ns_t_a6 = 38,           /* IPv6 address (deprecates AAAA) */
-+    ns_t_dname = 39,        /* Non-terminal DNAME (for IPv6) */
-+    ns_t_sink = 40,         /* Kitchen sink (experimentatl) */
-+    ns_t_opt = 41,          /* EDNS0 option (meta-RR) */
-+    ns_t_apl = 42,          /* Address prefix list (RFC3123) */
-+    ns_t_ds = 43,           /* Delegation Signer (RFC4034) */
-+    ns_t_sshfp = 44,        /* SSH Key Fingerprint (RFC4255) */
-+    ns_t_rrsig = 46,        /* Resource Record Signature (RFC4034) */
-+    ns_t_nsec = 47,         /* Next Secure (RFC4034) */
-+    ns_t_dnskey = 48,       /* DNS Public Key (RFC4034) */
-+    ns_t_tkey = 249,        /* Transaction key */
-+    ns_t_tsig = 250,        /* Transaction signature. */
-+    ns_t_ixfr = 251,        /* Incremental zone transfer. */
-+    ns_t_axfr = 252,        /* Transfer zone of authority. */
-+    ns_t_mailb = 253,       /* Transfer mailbox records. */
-+    ns_t_maila = 254,       /* Transfer mail agent records. */
-+    ns_t_any = 255,         /* Wildcard match. */
-+    ns_t_zxfr = 256,        /* BIND-specific, nonstandard. */
-+    ns_t_caa = 257,         /* Certification Authority Authorization. */
-+    ns_t_max = 65536
-+} ns_type;
-+
-+typedef enum __ns_opcode {
-+    ns_o_query = 0,         /* Standard query. */
-+    ns_o_iquery = 1,        /* Inverse query (deprecated/unsupported). */
-+    ns_o_status = 2,        /* Name server status query (unsupported). */
-+                                /* Opcode 3 is undefined/reserved. */
-+    ns_o_notify = 4,        /* Zone change notification. */
-+    ns_o_update = 5,        /* Zone update message. */
-+    ns_o_max = 6
-+} ns_opcode;
-+
-+typedef enum __ns_rcode {
-+    ns_r_noerror = 0,       /* No error occurred. */
-+    ns_r_formerr = 1,       /* Format error. */
-+    ns_r_servfail = 2,      /* Server failure. */
-+    ns_r_nxdomain = 3,      /* Name error. */
-+    ns_r_notimpl = 4,       /* Unimplemented. */
-+    ns_r_refused = 5,       /* Operation refused. */
-+    /* these are for BIND_UPDATE */
-+    ns_r_yxdomain = 6,      /* Name exists */
-+    ns_r_yxrrset = 7,       /* RRset exists */
-+    ns_r_nxrrset = 8,       /* RRset does not exist */
-+    ns_r_notauth = 9,       /* Not authoritative for zone */
-+    ns_r_notzone = 10,      /* Zone of record different from zone section */
-+    ns_r_max = 11,
-+    /* The following are TSIG extended errors */
-+    ns_r_badsig = 16,
-+    ns_r_badkey = 17,
-+    ns_r_badtime = 18
-+} ns_rcode;
-+
-+#endif /* HAVE_ARPA_NAMESER_H */
-+
-+
-+/* ============================================================================
-+ * arpa/nameser_compat.h typically sets these.  However on some systems
-+ * arpa/nameser.h does, but may not set all of them.  Lets conditionally
-+ * define each
-+ * ============================================================================
-+ */
-+
-+#ifndef PACKETSZ
-+#  define PACKETSZ         NS_PACKETSZ
-+#endif
-+
-+#ifndef MAXDNAME
-+#  define MAXDNAME         NS_MAXDNAME
-+#endif
-+
-+#ifndef MAXCDNAME
-+#  define MAXCDNAME        NS_MAXCDNAME
-+#endif
-+
-+#ifndef MAXLABEL
-+#  define MAXLABEL         NS_MAXLABEL
-+#endif
-+
-+#ifndef HFIXEDSZ
-+#  define HFIXEDSZ         NS_HFIXEDSZ
-+#endif
-+
-+#ifndef QFIXEDSZ
-+#  define QFIXEDSZ         NS_QFIXEDSZ
-+#endif
-+
-+#ifndef RRFIXEDSZ
-+#  define RRFIXEDSZ        NS_RRFIXEDSZ
-+#endif
-+
-+#ifndef INDIR_MASK
-+#  define INDIR_MASK       NS_CMPRSFLGS
-+#endif
-+
-+#ifndef NAMESERVER_PORT
-+#  define NAMESERVER_PORT  NS_DEFAULTPORT
-+#endif
-+
-+
-+/* opcodes */
-+#ifndef O_QUERY
-+#  define O_QUERY 0  /* ns_o_query */
-+#endif
-+#ifndef O_IQUERY
-+#  define O_IQUERY 1 /* ns_o_iquery */
-+#endif
-+#ifndef O_STATUS
-+#  define O_STATUS 2 /* ns_o_status */
-+#endif
-+#ifndef O_NOTIFY
-+#  define O_NOTIFY 4 /* ns_o_notify */
-+#endif
-+#ifndef O_UPDATE
-+#  define O_UPDATE 5 /* ns_o_update */
-+#endif
-+
-+
-+/* response codes */
-+#ifndef SERVFAIL
-+#  define SERVFAIL        ns_r_servfail
-+#endif
-+#ifndef NOTIMP
-+#  define NOTIMP          ns_r_notimpl
-+#endif
-+#ifndef REFUSED
-+#  define REFUSED         ns_r_refused
-+#endif
-+#if defined(_WIN32) && !defined(HAVE_ARPA_NAMESER_COMPAT_H) && defined(NOERROR)
-+#  undef NOERROR /* it seems this is already defined in winerror.h */
-+#endif
-+#ifndef NOERROR
-+#  define NOERROR         ns_r_noerror
-+#endif
-+#ifndef FORMERR
-+#  define FORMERR         ns_r_formerr
-+#endif
-+#ifndef NXDOMAIN
-+#  define NXDOMAIN        ns_r_nxdomain
-+#endif
-+/* Non-standard response codes, use numeric values */
-+#ifndef YXDOMAIN
-+#  define YXDOMAIN        6 /* ns_r_yxdomain */
-+#endif
-+#ifndef YXRRSET
-+#  define YXRRSET         7 /* ns_r_yxrrset */
-+#endif
-+#ifndef NXRRSET
-+#  define NXRRSET         8 /* ns_r_nxrrset */
-+#endif
-+#ifndef NOTAUTH
-+#  define NOTAUTH         9 /* ns_r_notauth */
-+#endif
-+#ifndef NOTZONE
-+#  define NOTZONE         10 /* ns_r_notzone */
-+#endif
-+#ifndef TSIG_BADSIG
-+#  define TSIG_BADSIG     16 /* ns_r_badsig */
-+#endif
-+#ifndef TSIG_BADKEY
-+#  define TSIG_BADKEY     17 /* ns_r_badkey */
-+#endif
-+#ifndef TSIG_BADTIME
-+#  define TSIG_BADTIME    18 /* ns_r_badtime */
-+#endif
-+
-+
-+/* classes */
-+#ifndef C_IN
-+#  define C_IN            1 /* ns_c_in */
-+#endif
-+#ifndef C_CHAOS
-+#  define C_CHAOS         3 /* ns_c_chaos */
-+#endif
-+#ifndef C_HS
-+#  define C_HS            4 /* ns_c_hs */
-+#endif
-+#ifndef C_NONE
-+#  define C_NONE          254 /* ns_c_none */
-+#endif
-+#ifndef C_ANY
-+#  define C_ANY           255 /*  ns_c_any */
-+#endif
-+
-+
-+/* types */
-+#ifndef T_A
-+#  define T_A             1   /* ns_t_a */
-+#endif
-+#ifndef T_NS
-+#  define T_NS            2   /* ns_t_ns */
-+#endif
-+#ifndef T_MD
-+#  define T_MD            3   /* ns_t_md */
-+#endif
-+#ifndef T_MF
-+#  define T_MF            4   /* ns_t_mf */
-+#endif
-+#ifndef T_CNAME
-+#  define T_CNAME         5   /* ns_t_cname */
-+#endif
-+#ifndef T_SOA
-+#  define T_SOA           6   /* ns_t_soa */
-+#endif
-+#ifndef T_MB
-+#  define T_MB            7   /* ns_t_mb */
-+#endif
-+#ifndef T_MG
-+#  define T_MG            8   /* ns_t_mg */
-+#endif
-+#ifndef T_MR
-+#  define T_MR            9   /* ns_t_mr */
-+#endif
-+#ifndef T_NULL
-+#  define T_NULL          10  /* ns_t_null */
-+#endif
-+#ifndef T_WKS
-+#  define T_WKS           11  /* ns_t_wks */
-+#endif
-+#ifndef T_PTR
-+#  define T_PTR           12  /* ns_t_ptr */
-+#endif
-+#ifndef T_HINFO
-+#  define T_HINFO         13  /* ns_t_hinfo */
-+#endif
-+#ifndef T_MINFO
-+#  define T_MINFO         14  /* ns_t_minfo */
-+#endif
-+#ifndef T_MX
-+#  define T_MX            15  /* ns_t_mx */
-+#endif
-+#ifndef T_TXT
-+#  define T_TXT           16  /* ns_t_txt */
-+#endif
-+#ifndef T_RP
-+#  define T_RP            17  /* ns_t_rp */
-+#endif
-+#ifndef T_AFSDB
-+#  define T_AFSDB         18  /* ns_t_afsdb */
-+#endif
-+#ifndef T_X25
-+#  define T_X25           19  /* ns_t_x25 */
-+#endif
-+#ifndef T_ISDN
-+#  define T_ISDN          20  /* ns_t_isdn */
-+#endif
-+#ifndef T_RT
-+#  define T_RT            21  /* ns_t_rt */
-+#endif
-+#ifndef T_NSAP
-+#  define T_NSAP          22  /* ns_t_nsap */
-+#endif
-+#ifndef T_NSAP_PTR
-+#  define T_NSAP_PTR      23  /* ns_t_nsap_ptr */
-+#endif
-+#ifndef T_SIG
-+#  define T_SIG           24  /* ns_t_sig */
-+#endif
-+#ifndef T_KEY
-+#  define T_KEY           25  /* ns_t_key */
-+#endif
-+#ifndef T_PX
-+#  define T_PX            26  /* ns_t_px */
-+#endif
-+#ifndef T_GPOS
-+#  define T_GPOS          27  /* ns_t_gpos */
-+#endif
-+#ifndef T_AAAA
-+#  define T_AAAA          28  /* ns_t_aaaa */
-+#endif
-+#ifndef T_LOC
-+#  define T_LOC           29  /* ns_t_loc */
-+#endif
-+#ifndef T_NXT
-+#  define T_NXT           30  /* ns_t_nxt */
-+#endif
-+#ifndef T_EID
-+#  define T_EID           31  /* ns_t_eid */
-+#endif
-+#ifndef T_NIMLOC
-+#  define T_NIMLOC        32  /* ns_t_nimloc */
-+#endif
-+#ifndef T_SRV
-+#  define T_SRV           33  /* ns_t_srv */
-+#endif
-+#ifndef T_ATMA
-+#  define T_ATMA          34  /* ns_t_atma */
-+#endif
-+#ifndef T_NAPTR
-+#  define T_NAPTR         35  /* ns_t_naptr */
-+#endif
-+#ifndef T_KX
-+#  define T_KX            36  /* ns_t_kx */
-+#endif
-+#ifndef T_CERT
-+#  define T_CERT          37  /* ns_t_cert */
-+#endif
-+#ifndef T_A6
-+#  define T_A6            38  /* ns_t_a6 */
-+#endif
-+#ifndef T_DNAME
-+#  define T_DNAME         39  /* ns_t_dname */
-+#endif
-+#ifndef T_SINK
-+#  define T_SINK          40  /* ns_t_sink */
-+#endif
-+#ifndef T_OPT
-+#  define T_OPT           41  /* ns_t_opt */
-+#endif
-+#ifndef T_APL
-+#  define T_APL           42  /* ns_t_apl */
-+#endif
-+#ifndef T_DS
-+#  define T_DS            43  /* ns_t_ds */
-+#endif
-+#ifndef T_SSHFP
-+#  define T_SSHFP         44  /* ns_t_sshfp */
-+#endif
-+#ifndef T_RRSIG
-+#  define T_RRSIG         46  /* ns_t_rrsig */
-+#endif
-+#ifndef T_NSEC
-+#  define T_NSEC          47  /* ns_t_nsec */
-+#endif
-+#ifndef T_DNSKEY
-+#  define T_DNSKEY        48  /* ns_t_dnskey */
-+#endif
-+#ifndef T_TKEY
-+#  define T_TKEY          249 /* ns_t_tkey */
-+#endif
-+#ifndef T_TSIG
-+#  define T_TSIG          250 /* ns_t_tsig */
-+#endif
-+#ifndef T_IXFR
-+#  define T_IXFR          251 /* ns_t_ixfr */
-+#endif
-+#ifndef T_AXFR
-+#  define T_AXFR          252 /* ns_t_axfr */
-+#endif
-+#ifndef T_MAILB
-+#  define T_MAILB         253 /* ns_t_mailb */
-+#endif
-+#ifndef T_MAILA
-+#  define T_MAILA         254 /* ns_t_maila */
-+#endif
-+#ifndef T_ANY
-+#  define T_ANY           255 /* ns_t_any */
-+#endif
-+#ifndef T_ZXFR
-+#  define T_ZXFR          256 /* ns_t_zxfr */
-+#endif
-+#ifndef T_CAA
-+#  define T_CAA           257 /* ns_t_caa */
-+#endif
-+#ifndef T_MAX
-+#  define T_MAX         65536 /* ns_t_max */
-+#endif
-+
-+
-+#endif /* ARES_NAMESER_H */
-
-From db4643979ee676b3a3d6cdf2fb597d399cf8013f Mon Sep 17 00:00:00 2001
-From: Felix Yan <felixonmars@archlinux.org>
-Date: Fri, 13 Aug 2021 00:01:59 +0800
-Subject: [PATCH 2/2] build: ignore cpplint for third-party ares_nameser.h
-
----
- Makefile | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/Makefile b/Makefile
-index ec4c774748cd..c418995c53c1 100644
---- a/Makefile
-+++ b/Makefile
-@@ -1289,6 +1289,7 @@ jslint-ci: lint-js-ci
- LINT_CPP_ADDON_DOC_FILES_GLOB = test/addons/??_*/*.cc test/addons/??_*/*.h
- LINT_CPP_ADDON_DOC_FILES = $(wildcard $(LINT_CPP_ADDON_DOC_FILES_GLOB))
- LINT_CPP_EXCLUDE ?=
-+LINT_CPP_EXCLUDE += src/ares_nameser.h
- LINT_CPP_EXCLUDE += src/node_root_certs.h
- LINT_CPP_EXCLUDE += $(LINT_CPP_ADDON_DOC_FILES)
- LINT_CPP_EXCLUDE += $(wildcard test/js-native-api/??_*/*.cc test/js-native-api/??_*/*.h test/node-api/??_*/*.cc test/node-api/??_*/*.h)

diff --git a/net-libs/nodejs/nodejs-14.21.3.ebuild b/net-libs/nodejs/nodejs-14.21.3.ebuild
index 7543fd8dcedc..d58d6df5cedf 100644
--- a/net-libs/nodejs/nodejs-14.21.3.ebuild
+++ b/net-libs/nodejs/nodejs-14.21.3.ebuild
@@ -52,7 +52,6 @@ BDEPEND="${PYTHON_DEPS}
 DEPEND="${RDEPEND}"
 
 PATCHES=(
-	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
 	"${FILESDIR}"/${PN}-14.15.0-fix_ppc64_crashes.patch
 	"${FILESDIR}"/${PN}-14.19.0-global-npm-config.patch
 	"${FILESDIR}"/${PN}-gcc-13.patch

diff --git a/net-libs/nodejs/nodejs-16.19.1.ebuild b/net-libs/nodejs/nodejs-16.19.1.ebuild
index aad6661508fa..c3744f846e98 100644
--- a/net-libs/nodejs/nodejs-16.19.1.ebuild
+++ b/net-libs/nodejs/nodejs-16.19.1.ebuild
@@ -49,7 +49,6 @@ BDEPEND="${PYTHON_DEPS}
 DEPEND="${RDEPEND}"
 
 PATCHES=(
-	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
 	"${FILESDIR}"/${PN}-15.2.0-global-npm-config.patch
 	"${FILESDIR}"/${PN}-gcc-13.patch
 )

diff --git a/net-libs/nodejs/nodejs-18.14.2.ebuild b/net-libs/nodejs/nodejs-18.14.2.ebuild
index bb51f9d7af75..fe52fcfba5ed 100644
--- a/net-libs/nodejs/nodejs-18.14.2.ebuild
+++ b/net-libs/nodejs/nodejs-18.14.2.ebuild
@@ -48,10 +48,6 @@ BDEPEND="${PYTHON_DEPS}
 	pax-kernel? ( sys-apps/elfix )"
 DEPEND="${RDEPEND}"
 
-PATCHES=(
-	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
-)
-
 # These are measured on a loong machine with -ggdb on, and only checked
 # if debugging flags are present in CFLAGS.
 #

diff --git a/net-libs/nodejs/nodejs-99999999.ebuild b/net-libs/nodejs/nodejs-99999999.ebuild
index 77822a99f225..ef61e71e60d6 100644
--- a/net-libs/nodejs/nodejs-99999999.ebuild
+++ b/net-libs/nodejs/nodejs-99999999.ebuild
@@ -48,10 +48,6 @@ BDEPEND="${PYTHON_DEPS}
 	pax-kernel? ( sys-apps/elfix )"
 DEPEND="${RDEPEND}"
 
-PATCHES=(
-	"${FILESDIR}"/${PN}-12.22.5-shared_c-ares_nameser_h.patch
-)
-
 # These are measured on a loong machine with -ggdb on, and only checked
 # if debugging flags are present in CFLAGS.
 #


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2023-04-17 17:20 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2023-04-17 17:20 UTC (permalink / raw
  To: gentoo-commits

commit:     4c17ce92a321b3bed25618d464998482a3877125
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Mon Apr 17 17:19:46 2023 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Mon Apr 17 17:20:11 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4c17ce92

net-libs/nodejs: add 18.16.0

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 +
 .../nodejs/files/nodejs-18.16.0-paxmarking.patch   | 101 ++++++++
 net-libs/nodejs/nodejs-18.16.0.ebuild              | 255 +++++++++++++++++++++
 3 files changed, 357 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 16aeb4845923..e89465ec5597 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -3,3 +3,4 @@ DIST node-v16.19.1.tar.xz 35465252 BLAKE2B 717cf15ab6fa5a2a643138959c4e539ef5417
 DIST node-v16.20.0.tar.xz 35546884 BLAKE2B 5bdb1fb7365e07f13d0a58a8d052d11efaadcf1b0792af0517b78b1ecf01e50eabe26e31588ae410ee63b7494a4eb9d23f70d4dd157a452d0bbf8bd548865255 SHA512 b155acdff0244307afcc334844f113b5c321f7764ebb69326d60a6a79d0e0d38d55257a38b815f5933aa4071e6a788e01c466476ef012cec648c84d74adda406
 DIST node-v18.14.2.tar.xz 40330824 BLAKE2B d18cf6a23f091633e5298727eeee15dec65ca83e688ff9fbed78385102aa44707ff4b33bcb034f6d10aab9a81a646ad7e8c28a239de151b816ff7072977df0de SHA512 72bb788b40d83bc42850dd9e2d00ffc06d9bcb17d24280d4721038038d1632846f859864328c849498255d1095296402b9b3c6b8910bbd399f7f516a43b9c86f
 DIST node-v18.15.0.tar.xz 40355624 BLAKE2B 56337de0b6e3c2421e6d9add81d30ada821525e0bb05fc977c91b7162f6dc075610ec53af50d6596cab6c0f647d61fb243896b25f0a768eeeefedf1a8bde1c05 SHA512 e41fcda469809186fd724ef4691e25f4a5bd81357ee99acf3d7faa1190a69c19cb62bd14aea199ca6f8b5cf9687af7d898cdf605ea2414d2c04db87ddb3b4dc8
+DIST node-v18.16.0.tar.xz 40467860 BLAKE2B b16749c0212f3aa196ec9fc0f999a023adeb9031b3332939330ba5a3edb5bc2ed6dc21bf861509696e19ed0cc5d5c54bb882018f0e54eb1ad8e9b0ba3bb64bff SHA512 608ce5db97ce2d851f381c7991f635c5e0927ae79037649b482c7e197479341b7c6560644e25f4d65ece8aa80c5763a0e044349a5be210fa33fbbf97a96462bd

diff --git a/net-libs/nodejs/files/nodejs-18.16.0-paxmarking.patch b/net-libs/nodejs/files/nodejs-18.16.0-paxmarking.patch
new file mode 100644
index 000000000000..9decb13ec47b
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-18.16.0-paxmarking.patch
@@ -0,0 +1,101 @@
+From 4c910c45a73c61f908f85661a1568a614afde081 Mon Sep 17 00:00:00 2001
+From: William Hubbs <w.d.hubbs@gmail.com>
+Date: Mon, 17 Apr 2023 11:43:17 -0500
+Subject: [PATCH] pax marking
+
+---
+ node.gyp                 | 17 ++++++++++++++++-
+ tools/v8_gypfiles/v8.gyp | 24 +++++++++++++++++++++++-
+ 2 files changed, 39 insertions(+), 2 deletions(-)
+
+diff --git a/node.gyp b/node.gyp
+index cf52281bb4..80352dfcc5 100644
+--- a/node.gyp
++++ b/node.gyp
+@@ -54,6 +54,7 @@
+       '<@(node_builtin_shareable_builtins)',
+     ],
+     'node_mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot<(EXECUTABLE_SUFFIX)',
++    'node_mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'conditions': [
+       ['GENERATOR == "ninja"', {
+         'node_text_start_object_path': 'src/large_pages/node_text_start.node_text_start.o'
+@@ -337,11 +338,25 @@
+               ],
+             }, {
+               'actions': [
++                {
++                  'action_name': 'run_pax_mksnapshot',
++                  'inputs': [
++                    '<(node_mksnapshot_exec)',
++                  ],
++                  'outputs': [
++                    '<(node_mksnapshot_u_exec)',
++                  ],
++                  'action': [
++                    'bash',
++                    '-c',
++                    'mv <(node_mksnapshot_exec) <(node_mksnapshot_u_exec) && paxmark.sh m <(node_mksnapshot_u_exec)',
++                  ],
++                },
+                 {
+                   'action_name': 'node_mksnapshot',
+                   'process_outputs_as_sources': 1,
+                   'inputs': [
+-                    '<(node_mksnapshot_exec)',
++                    '<(node_mksnapshot_u_exec)',
+                   ],
+                   'outputs': [
+                     '<(SHARED_INTERMEDIATE_DIR)/node_snapshot.cc',
+diff --git a/tools/v8_gypfiles/v8.gyp b/tools/v8_gypfiles/v8.gyp
+index a721ffb41a..4a52a1f822 100644
+--- a/tools/v8_gypfiles/v8.gyp
++++ b/tools/v8_gypfiles/v8.gyp
+@@ -9,6 +9,7 @@
+     'v8_vector_stores%': 0,
+     'v8_embed_script%': "",
+     'mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
++    'mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'v8_os_page_size%': 0,
+     'generate_bytecode_output_root': '<(SHARED_INTERMEDIATE_DIR)/generate-bytecode-output-root',
+     'generate_bytecode_builtins_list_output': '<(generate_bytecode_output_root)/builtins-generated/bytecodes-builtins-list.h',
+@@ -1419,7 +1420,7 @@
+       ],
+     },  # bytecode_builtins_list_generator
+     {
+-      'target_name': 'mksnapshot',
++      'target_name': 'mksnapshot_u',
+       'type': 'executable',
+       'dependencies': [
+         'v8_base_without_compiler',
+@@ -1446,6 +1447,27 @@
+           ],
+         }],
+       ],
++    },  # mksnapshot_u
++    {
++      'target_name': 'mksnapshot',
++      'type': 'none',
++      'dependencies': ['mksnapshot_u'],
++      'actions': [
++        {
++          'action_name': 'paxmark_mksnapshot',
++          'inputs': [
++            '<(mksnapshot_u_exec)',
++          ],
++          'outputs': [
++            '<(mksnapshot_exec)',
++          ],
++          'action': [
++            'bash',
++            '-c',
++            'cp <(mksnapshot_u_exec) <(mksnapshot_exec) && paxmark.sh m <(mksnapshot_exec)'
++          ],
++        },
++      ],
+     },  # mksnapshot
+     {
+       'target_name': 'torque',
+-- 
+2.39.2
+

diff --git a/net-libs/nodejs/nodejs-18.16.0.ebuild b/net-libs/nodejs/nodejs-18.16.0.ebuild
new file mode 100644
index 000000000000..aa505edb748c
--- /dev/null
+++ b/net-libs/nodejs/nodejs-18.16.0.ebuild
@@ -0,0 +1,255 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CONFIG_CHECK="~ADVISE_SYSCALLS"
+PYTHON_COMPAT=( python3_{9..11} )
+PYTHON_REQ_USE="threads(+)"
+
+inherit bash-completion-r1 check-reqs flag-o-matic linux-info pax-utils python-any-r1 toolchain-funcs xdg-utils
+
+DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine"
+HOMEPAGE="https://nodejs.org/"
+LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
+
+if [[ ${PV} == *9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/nodejs/node"
+	SLOT="0"
+else
+	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
+	SLOT="0/$(ver_cut 1)"
+	KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc64 ~riscv ~x86 ~amd64-linux ~x64-macos"
+	S="${WORKDIR}/node-v${PV}"
+fi
+
+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 )"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND=">=app-arch/brotli-1.0.9:=
+	>=dev-libs/libuv-1.44.0:=
+	>=net-dns/c-ares-1.17.2:=
+	>=net-libs/nghttp2-1.41.0:=
+	sys-libs/zlib
+	system-icu? ( >=dev-libs/icu-67:= )
+	system-ssl? ( >=dev-libs/openssl-1.1.1:0= )
+	sys-devel/gcc:*"
+BDEPEND="${PYTHON_DEPS}
+	sys-apps/coreutils
+	virtual/pkgconfig
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )
+	pax-kernel? ( sys-apps/elfix )"
+DEPEND="${RDEPEND}"
+
+# These are measured on a loong machine with -ggdb on, and only checked
+# if debugging flags are present in CFLAGS.
+#
+# The final link consumed a little more than 7GiB alone, so 8GiB is the lower
+# limit for memory usage. Disk usage was 19.1GiB for the build directory and
+# 1.2GiB for the installed image, so we leave some room for architectures with
+# fatter binaries and set the disk requirement to 22GiB.
+CHECKREQS_MEMORY="8G"
+CHECKREQS_DISK_BUILD="22G"
+
+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 is-flagq "-g*" && ! is-flagq "-g*0" ; then
+			einfo "Checking for sufficient disk space and memory to build ${PN} with debugging CFLAGS"
+			check-reqs_pkg_pretend
+		fi
+	fi
+}
+
+pkg_setup() {
+	python-any-r1_pkg_setup
+	linux-info_pkg_setup
+}
+
+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
+
+	# 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}"/${P}-paxmarking.patch )
+
+	# All this test does is check if the npm CLI produces warnings of any sort,
+	# failing if it does. Overkill, much? Especially given one possible warning
+	# is that there is a newer version of npm available upstream (yes, it does
+	# use the network if available), thus making it a real possibility for this
+	# test to begin failing one day even though it was fine before.
+	rm -f test/parallel/test-release-npm.js
+
+	default
+}
+
+src_configure() {
+	xdg_environment_reset
+
+	# LTO compiler flags are handled by configure.py itself
+	filter-flags '-flto*'
+	# nodejs unconditionally links to libatomic #869992
+	# specifically it requires __atomic_is_lock_free which
+	# is not yet implemented by sys-libs/compiler-rt (see
+	# https://reviews.llvm.org/D85044?id=287068), therefore
+	# we depend on gcc and force using libgcc as the support lib
+	tc-is-clang && append-ldflags "--rtlib=libgcc --unwindlib=libgcc"
+
+	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 "${ARCH}:${ABI}" in
+		*:amd64) myarch="x64";;
+		*:arm) myarch="arm";;
+		*:arm64) myarch="arm64";;
+		loong:lp64*) myarch="loong64";;
+		riscv:lp64*) myarch="riscv64";;
+		*: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
+		keepdir /etc/npm
+		echo "NPM_CONFIG_GLOBALCONFIG=${EPREFIX}/etc/npm/npmrc" > "${T}"/50npm
+		doenvd "${T}"/50npm
+
+		# Install bash completion for `npm`
+		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
+
+		# 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() {
+	rm -f "${S}"/tests/parallel/test-dns-setserver-when-querying.js
+	if has usersandbox ${FEATURES}; then
+		rm -f "${S}"/test/parallel/test-fs-mkdir.js
+		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
+			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
+	fi
+
+	out/${BUILDTYPE}/cctest || die
+	"${EPYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -J message parallel sequential || die
+}
+
+pkg_postinst() {
+	if use npm; then
+		ewarn "remember to run: source /etc/profile if you plan to use nodejs"
+		ewarn "	in your current shell"
+	fi
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2023-04-27  2:04 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2023-04-27  2:04 UTC (permalink / raw
  To: gentoo-commits

commit:     07af95b423429ec4067d3d012b378f32d6699f53
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Thu Apr 27 02:02:58 2023 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Thu Apr 27 02:04:09 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=07af95b4

net-libs/nodejs: add 20.0.0

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 +
 .../nodejs/files/nodejs-fix-incomplete-type.patch  |  44 ++++
 net-libs/nodejs/nodejs-20.0.0.ebuild               | 259 +++++++++++++++++++++
 3 files changed, 304 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index e89465ec5597..06474cb6818a 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -4,3 +4,4 @@ DIST node-v16.20.0.tar.xz 35546884 BLAKE2B 5bdb1fb7365e07f13d0a58a8d052d11efaadc
 DIST node-v18.14.2.tar.xz 40330824 BLAKE2B d18cf6a23f091633e5298727eeee15dec65ca83e688ff9fbed78385102aa44707ff4b33bcb034f6d10aab9a81a646ad7e8c28a239de151b816ff7072977df0de SHA512 72bb788b40d83bc42850dd9e2d00ffc06d9bcb17d24280d4721038038d1632846f859864328c849498255d1095296402b9b3c6b8910bbd399f7f516a43b9c86f
 DIST node-v18.15.0.tar.xz 40355624 BLAKE2B 56337de0b6e3c2421e6d9add81d30ada821525e0bb05fc977c91b7162f6dc075610ec53af50d6596cab6c0f647d61fb243896b25f0a768eeeefedf1a8bde1c05 SHA512 e41fcda469809186fd724ef4691e25f4a5bd81357ee99acf3d7faa1190a69c19cb62bd14aea199ca6f8b5cf9687af7d898cdf605ea2414d2c04db87ddb3b4dc8
 DIST node-v18.16.0.tar.xz 40467860 BLAKE2B b16749c0212f3aa196ec9fc0f999a023adeb9031b3332939330ba5a3edb5bc2ed6dc21bf861509696e19ed0cc5d5c54bb882018f0e54eb1ad8e9b0ba3bb64bff SHA512 608ce5db97ce2d851f381c7991f635c5e0927ae79037649b482c7e197479341b7c6560644e25f4d65ece8aa80c5763a0e044349a5be210fa33fbbf97a96462bd
+DIST node-v20.0.0.tar.xz 41279796 BLAKE2B 1df8785ca22dea15c6c1f19ec2d3b3d704f9cda6cf13d6e8e8fbbf853515871f18a11a4bbe5ed765434f6f5606975c5254e1826f2e506165ff937ef16d326262 SHA512 cda981227398c1a9023a2212c0d5351eadfedd19d58776dcc470e3ba0213a178b626c37d48fa52548ddd5a70d26a18b66c266856321a0af9ada2b1eac7ee9fd8

diff --git a/net-libs/nodejs/files/nodejs-fix-incomplete-type.patch b/net-libs/nodejs/files/nodejs-fix-incomplete-type.patch
new file mode 100644
index 000000000000..e204421597d0
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-fix-incomplete-type.patch
@@ -0,0 +1,44 @@
+From 0164c09d4025df2bd1a42f14de29166aa0e7ac7a Mon Sep 17 00:00:00 2001
+From: Richard Lau <rlau@redhat.com>
+Date: Wed, 26 Apr 2023 15:46:00 -0400
+Subject: [PATCH] deps: V8: cherry-pick c5ab3e4f0c5a
+
+Original commit message:
+
+    libstdc++: fix incomplete type in v8::internal::is_subtype<T, U>
+
+    Using std::convertible with incomplete types is UB. However, till
+    GCC 12 it was accepted and std::convertible returned false.
+    This fails now for e.g. v8::internal::WasmArray. Use
+    std::disjunction and std::conjunction instead which are short-
+    circuiting, because std::is_base_of<T, T> is already true.
+
+    Bug: chromium:957519
+    Change-Id: Ia26643dbdf0fb00d5586c71ae6b18e8d0f3cf96e
+    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4394663
+    Commit-Queue: Stephan Hartmann <stha09@googlemail.com>
+    Reviewed-by: Clemens Backes <clemensb@chromium.org>
+    Cr-Commit-Position: refs/heads/main@{#86904}
+
+Refs: https://github.com/v8/v8/commit/c5ab3e4f0c5a3ce880941184ef8447c27cd19a93
+---
+ common.gypi                 | 2 +-
+ deps/v8/src/codegen/tnode.h | 5 +++--
+ 2 files changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/deps/v8/src/codegen/tnode.h b/deps/v8/src/codegen/tnode.h
+index cd7bd8db98c24..7629e89ad693f 100644
+--- a/deps/v8/src/codegen/tnode.h
++++ b/deps/v8/src/codegen/tnode.h
+@@ -269,8 +269,9 @@ using BuiltinPtr = Smi;
+ template <class T, class U>
+ struct is_subtype {
+   static const bool value =
+-      std::is_base_of<U, T>::value || (std::is_same<U, MaybeObject>::value &&
+-                                       std::is_convertible<T, Object>::value);
++      std::disjunction<std::is_base_of<U, T>,
++                       std::conjunction<std::is_same<U, MaybeObject>,
++                                        std::is_convertible<T, Object>>>::value;
+ };
+ template <class T1, class T2, class U>
+ struct is_subtype<UnionT<T1, T2>, U> {

diff --git a/net-libs/nodejs/nodejs-20.0.0.ebuild b/net-libs/nodejs/nodejs-20.0.0.ebuild
new file mode 100644
index 000000000000..5a4561402129
--- /dev/null
+++ b/net-libs/nodejs/nodejs-20.0.0.ebuild
@@ -0,0 +1,259 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CONFIG_CHECK="~ADVISE_SYSCALLS"
+PYTHON_COMPAT=( python3_{9..11} )
+PYTHON_REQ_USE="threads(+)"
+
+inherit bash-completion-r1 check-reqs flag-o-matic linux-info pax-utils python-any-r1 toolchain-funcs xdg-utils
+
+DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine"
+HOMEPAGE="https://nodejs.org/"
+LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
+
+if [[ ${PV} == *9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/nodejs/node"
+	SLOT="0"
+else
+	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
+	SLOT="0/$(ver_cut 1)"
+	KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc64 ~riscv ~x86 ~amd64-linux ~x64-macos"
+	S="${WORKDIR}/node-v${PV}"
+fi
+
+IUSE="cpu_flags_x86_sse2 debug doc +icu inspector lto +npm pax-kernel +snapshot +ssl +system-icu +system-ssl test"
+REQUIRED_USE="inspector? ( icu ssl )
+	npm? ( ssl )
+	system-icu? ( icu )
+	system-ssl? ( ssl )"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND=">=app-arch/brotli-1.0.9:=
+	>=dev-libs/libuv-1.44.0:=
+	>=net-dns/c-ares-1.17.2:=
+	>=net-libs/nghttp2-1.41.0:=
+	sys-libs/zlib
+	system-icu? ( >=dev-libs/icu-67:= )
+	system-ssl? ( >=dev-libs/openssl-1.1.1:0= )
+	sys-devel/gcc:*"
+BDEPEND="${PYTHON_DEPS}
+	sys-apps/coreutils
+	virtual/pkgconfig
+	test? ( net-misc/curl )
+	pax-kernel? ( sys-apps/elfix )"
+DEPEND="${RDEPEND}"
+
+# These are measured on a loong machine with -ggdb on, and only checked
+# if debugging flags are present in CFLAGS.
+#
+# The final link consumed a little more than 7GiB alone, so 8GiB is the lower
+# limit for memory usage. Disk usage was 19.1GiB for the build directory and
+# 1.2GiB for the installed image, so we leave some room for architectures with
+# fatter binaries and set the disk requirement to 22GiB.
+CHECKREQS_MEMORY="8G"
+CHECKREQS_DISK_BUILD="22G"
+
+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 is-flagq "-g*" && ! is-flagq "-g*0" ; then
+			einfo "Checking for sufficient disk space and memory to build ${PN} with debugging CFLAGS"
+			check-reqs_pkg_pretend
+		fi
+	fi
+}
+
+pkg_setup() {
+	python-any-r1_pkg_setup
+	linux-info_pkg_setup
+}
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-fix-incomplete-type.patch
+)
+
+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
+
+	# 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}-18.16.0-paxmarking.patch )
+
+	# All this test does is check if the npm CLI produces warnings of any sort,
+	# failing if it does. Overkill, much? Especially given one possible warning
+	# is that there is a newer version of npm available upstream (yes, it does
+	# use the network if available), thus making it a real possibility for this
+	# test to begin failing one day even though it was fine before.
+	rm -f test/parallel/test-release-npm.js
+
+	default
+}
+
+src_configure() {
+	xdg_environment_reset
+
+	# LTO compiler flags are handled by configure.py itself
+	filter-flags '-flto*'
+	# nodejs unconditionally links to libatomic #869992
+	# specifically it requires __atomic_is_lock_free which
+	# is not yet implemented by sys-libs/compiler-rt (see
+	# https://reviews.llvm.org/D85044?id=287068), therefore
+	# we depend on gcc and force using libgcc as the support lib
+	tc-is-clang && append-ldflags "--rtlib=libgcc --unwindlib=libgcc"
+
+	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 "${ARCH}:${ABI}" in
+		*:amd64) myarch="x64";;
+		*:arm) myarch="arm";;
+		*:arm64) myarch="arm64";;
+		loong:lp64*) myarch="loong64";;
+		riscv:lp64*) myarch="riscv64";;
+		*: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} \
+		"${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
+		keepdir /etc/npm
+		echo "NPM_CONFIG_GLOBALCONFIG=${EPREFIX}/etc/npm/npmrc" > "${T}"/50npm
+		doenvd "${T}"/50npm
+
+		# Install bash completion for `npm`
+		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
+
+		# 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() {
+	rm \
+		"${S}"/test/parallel/test-dns-setserver-when-querying.js \
+		"${S}"/test/parallel/test-strace-openat-openssl.js || die
+	if has usersandbox ${FEATURES}; then
+		rm -f "${S}"/test/parallel/test-fs-mkdir.js
+		ewarn "You are emerging ${PN} with 'usersandbox' enabled. Excluding tests known to fail in this mode." \
+			"For full test coverage, emerge =${CATEGORY}/${PF} with 'FEATURES=-usersandbox'."
+	fi
+
+	out/${BUILDTYPE}/cctest || die
+	"${EPYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -J message parallel sequential || die
+}
+
+pkg_postinst() {
+	if use npm; then
+		ewarn "remember to run: source /etc/profile if you plan to use nodejs"
+		ewarn "	in your current shell"
+	fi
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2023-09-07 15:51 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2023-09-07 15:51 UTC (permalink / raw
  To: gentoo-commits

commit:     aaf869ad9019596fbadff1c4ebcb59e0960afae5
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Thu Sep  7 15:42:09 2023 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Thu Sep  7 15:49:01 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=aaf869ad

net-libs/nodejs: drop 18.16.0

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 -
 .../nodejs/files/nodejs-fix-incomplete-type.patch  |  44 ----
 net-libs/nodejs/nodejs-18.16.0.ebuild              | 256 ---------------------
 3 files changed, 301 deletions(-)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index 5bf28d6ef508..fc9312231a84 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,5 +1,4 @@
 DIST node-v16.20.2.tar.xz 36834468 BLAKE2B 88bd0d91a6b69f7e5fba2b087684b07b8986fd1492f51f6fdccc02f043970303808c0cc1eeda29670aacddd4234ec3181752c916fefee060624b0462dff8cbcf SHA512 c7953630b7d0eb832ab5a4b839c07e6505cf5f4e37853f59cd0ffc6b8742ac2ecaba20bfb47d8995ef88f3c7005bb456c1eb70cb2fc6b6fc506e1d8b81f25cb4
-DIST node-v18.16.0.tar.xz 40467860 BLAKE2B b16749c0212f3aa196ec9fc0f999a023adeb9031b3332939330ba5a3edb5bc2ed6dc21bf861509696e19ed0cc5d5c54bb882018f0e54eb1ad8e9b0ba3bb64bff SHA512 608ce5db97ce2d851f381c7991f635c5e0927ae79037649b482c7e197479341b7c6560644e25f4d65ece8aa80c5763a0e044349a5be210fa33fbbf97a96462bd
 DIST node-v18.17.1.tar.xz 40788836 BLAKE2B 50e0dc0eecd68620ffa7457319e71124bbba302f6acff79286a30cf97442fb09a96cf8781456bafd5c2e497ba88cf392c141f0e221683da421b87f653b1ad7ca SHA512 fd6f586447ecd44ac6738da1cf7d54e74bd33ffd1ee1acc2e0e1bdaf0031bcaef85751d3dd590bb278eb502daf9c77f0763b5a181a30ee4cf537aef254629622
 DIST node-v20.2.0.tar.xz 41778040 BLAKE2B 362b0ee89fe822722caeeb4b918550637bfb10791de75d872da334cb1123b744c351b5822b05abf4d36a0449badc5232ab1d73896dd5ce7755d10b226f0b9f52 SHA512 bf780e79bf6c7f766beb7734c7af45edc62094aba4c608f5519b130ff263e52ece925f85a4ee5740e962d16020070ef00933f6c74e771d948f23525c223da48e
 DIST node-v20.5.1.tar.xz 41532256 BLAKE2B b26fbe8be7e3330b69ae0f630cabba7dee7879ae829c2c743491d26d9623c3170de85e4e7c0629993257935841978343c1ded2870ece24365784581c8be0143b SHA512 2828930bf2df0769ec7116fc6b89c7069294426b937ce38543426e0108a8c953301c523eb03419e35a993773895d74b28838bec96ffc01ab0e138a4b2a52737d

diff --git a/net-libs/nodejs/files/nodejs-fix-incomplete-type.patch b/net-libs/nodejs/files/nodejs-fix-incomplete-type.patch
deleted file mode 100644
index e204421597d0..000000000000
--- a/net-libs/nodejs/files/nodejs-fix-incomplete-type.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 0164c09d4025df2bd1a42f14de29166aa0e7ac7a Mon Sep 17 00:00:00 2001
-From: Richard Lau <rlau@redhat.com>
-Date: Wed, 26 Apr 2023 15:46:00 -0400
-Subject: [PATCH] deps: V8: cherry-pick c5ab3e4f0c5a
-
-Original commit message:
-
-    libstdc++: fix incomplete type in v8::internal::is_subtype<T, U>
-
-    Using std::convertible with incomplete types is UB. However, till
-    GCC 12 it was accepted and std::convertible returned false.
-    This fails now for e.g. v8::internal::WasmArray. Use
-    std::disjunction and std::conjunction instead which are short-
-    circuiting, because std::is_base_of<T, T> is already true.
-
-    Bug: chromium:957519
-    Change-Id: Ia26643dbdf0fb00d5586c71ae6b18e8d0f3cf96e
-    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4394663
-    Commit-Queue: Stephan Hartmann <stha09@googlemail.com>
-    Reviewed-by: Clemens Backes <clemensb@chromium.org>
-    Cr-Commit-Position: refs/heads/main@{#86904}
-
-Refs: https://github.com/v8/v8/commit/c5ab3e4f0c5a3ce880941184ef8447c27cd19a93
----
- common.gypi                 | 2 +-
- deps/v8/src/codegen/tnode.h | 5 +++--
- 2 files changed, 4 insertions(+), 3 deletions(-)
-
-diff --git a/deps/v8/src/codegen/tnode.h b/deps/v8/src/codegen/tnode.h
-index cd7bd8db98c24..7629e89ad693f 100644
---- a/deps/v8/src/codegen/tnode.h
-+++ b/deps/v8/src/codegen/tnode.h
-@@ -269,8 +269,9 @@ using BuiltinPtr = Smi;
- template <class T, class U>
- struct is_subtype {
-   static const bool value =
--      std::is_base_of<U, T>::value || (std::is_same<U, MaybeObject>::value &&
--                                       std::is_convertible<T, Object>::value);
-+      std::disjunction<std::is_base_of<U, T>,
-+                       std::conjunction<std::is_same<U, MaybeObject>,
-+                                        std::is_convertible<T, Object>>>::value;
- };
- template <class T1, class T2, class U>
- struct is_subtype<UnionT<T1, T2>, U> {

diff --git a/net-libs/nodejs/nodejs-18.16.0.ebuild b/net-libs/nodejs/nodejs-18.16.0.ebuild
deleted file mode 100644
index c5e3710c3393..000000000000
--- a/net-libs/nodejs/nodejs-18.16.0.ebuild
+++ /dev/null
@@ -1,256 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-CONFIG_CHECK="~ADVISE_SYSCALLS"
-PYTHON_COMPAT=( python3_{9..11} )
-PYTHON_REQ_USE="threads(+)"
-
-inherit bash-completion-r1 check-reqs flag-o-matic linux-info pax-utils python-any-r1 toolchain-funcs xdg-utils
-
-DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine"
-HOMEPAGE="https://nodejs.org/"
-LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
-
-if [[ ${PV} == *9999 ]]; then
-	inherit git-r3
-	EGIT_REPO_URI="https://github.com/nodejs/node"
-	SLOT="0"
-else
-	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
-	SLOT="0/$(ver_cut 1)"
-	KEYWORDS="amd64 arm arm64 ~loong ppc64 ~riscv x86 ~amd64-linux ~x64-macos"
-	S="${WORKDIR}/node-v${PV}"
-fi
-
-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 )"
-
-RESTRICT="!test? ( test )"
-
-RDEPEND=">=app-arch/brotli-1.0.9:=
-	>=dev-libs/libuv-1.44.0:=
-	>=net-dns/c-ares-1.18.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= )
-	sys-devel/gcc:*"
-BDEPEND="${PYTHON_DEPS}
-	sys-apps/coreutils
-	virtual/pkgconfig
-	systemtap? ( dev-util/systemtap )
-	test? ( net-misc/curl )
-	pax-kernel? ( sys-apps/elfix )"
-DEPEND="${RDEPEND}"
-
-# These are measured on a loong machine with -ggdb on, and only checked
-# if debugging flags are present in CFLAGS.
-#
-# The final link consumed a little more than 7GiB alone, so 8GiB is the lower
-# limit for memory usage. Disk usage was 19.1GiB for the build directory and
-# 1.2GiB for the installed image, so we leave some room for architectures with
-# fatter binaries and set the disk requirement to 22GiB.
-CHECKREQS_MEMORY="8G"
-CHECKREQS_DISK_BUILD="22G"
-
-PATCHES=(
-	"${FILESDIR}"/${PN}-fix-incomplete-type.patch
-)
-
-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 is-flagq "-g*" && ! is-flagq "-g*0" ; then
-			einfo "Checking for sufficient disk space and memory to build ${PN} with debugging CFLAGS"
-			check-reqs_pkg_pretend
-		fi
-	fi
-}
-
-pkg_setup() {
-	python-any-r1_pkg_setup
-	linux-info_pkg_setup
-}
-
-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
-
-	# 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}"/${P}-paxmarking.patch )
-
-	default
-}
-
-src_configure() {
-	xdg_environment_reset
-
-	# LTO compiler flags are handled by configure.py itself
-	filter-lto
-	# nodejs unconditionally links to libatomic #869992
-	# specifically it requires __atomic_is_lock_free which
-	# is not yet implemented by sys-libs/compiler-rt (see
-	# https://reviews.llvm.org/D85044?id=287068), therefore
-	# we depend on gcc and force using libgcc as the support lib
-	tc-is-clang && append-ldflags "--rtlib=libgcc --unwindlib=libgcc"
-
-	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 "${ARCH}:${ABI}" in
-		*:amd64) myarch="x64";;
-		*:arm) myarch="arm";;
-		*:arm64) myarch="arm64";;
-		loong:lp64*) myarch="loong64";;
-		riscv:lp64*) myarch="riscv64";;
-		*: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
-		keepdir /etc/npm
-		echo "NPM_CONFIG_GLOBALCONFIG=${EPREFIX}/etc/npm/npmrc" > "${T}"/50npm
-		doenvd "${T}"/50npm
-
-		# Install bash completion for `npm`
-		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
-
-		# 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() {
-	local drop_tests=(
-		test/parallel/test-dns-setserver-when-querying.js
-		test/parallel/test-fs-mkdir.js
-		test/parallel/test-fs-utimes-y2K38.js
-		test/parallel/test-release-npm.js
-		test/parallel/test-socket-write-after-fin-error.js
-		test/parallel/test-strace-openat-openssl.js
-		test/sequential/test-util-debug.js
-	)
-	rm "${drop_tests[@]}" || die "disabling tests failed"
-
-	out/${BUILDTYPE}/cctest || die
-	"${EPYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -J message parallel sequential || die
-}
-
-pkg_postinst() {
-	if use npm; then
-		ewarn "remember to run: source /etc/profile if you plan to use nodejs"
-		ewarn "	in your current shell"
-	fi
-}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2023-09-14 22:45 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2023-09-14 22:45 UTC (permalink / raw
  To: gentoo-commits

commit:     ee50f94201794f6e06f67526dd06c73f6249f5b6
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Thu Sep 14 22:40:27 2023 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Thu Sep 14 22:45:38 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ee50f942

net-libs/nodejs: fix pax-marking patch for 20.6.1

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 .../nodejs/files/nodejs-20.6.0-paxmarking.patch    | 88 ++++++++++++++++++++++
 net-libs/nodejs/nodejs-20.6.1.ebuild               |  2 +-
 2 files changed, 89 insertions(+), 1 deletion(-)

diff --git a/net-libs/nodejs/files/nodejs-20.6.0-paxmarking.patch b/net-libs/nodejs/files/nodejs-20.6.0-paxmarking.patch
new file mode 100644
index 000000000000..32fbe2d1d00a
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-20.6.0-paxmarking.patch
@@ -0,0 +1,88 @@
+diff --git a/node.gyp b/node.gyp
+index 49e39c3ce8..767ebc4e5f 100644
+--- a/node.gyp
++++ b/node.gyp
+@@ -369,6 +369,7 @@
+       'src/quic/transportparams.h',
+     ],
+     'node_mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot<(EXECUTABLE_SUFFIX)',
++    'node_mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'node_js2c_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_js2c<(EXECUTABLE_SUFFIX)',
+     'conditions': [
+       ['GENERATOR == "ninja"', {
+@@ -626,11 +627,25 @@
+           'conditions': [
+             ['node_snapshot_main!=""', {
+               'actions': [
++                {
++                  'action_name': 'run_pax_mksnapshot',
++                  'inputs': [
++                    '<(node_mksnapshot_exec)',
++                  ],
++                  'outputs': [
++                    '<(node_mksnapshot_u_exec)',
++                  ],
++                  'action': [
++                    'bash',
++                    '-c',
++                    'mv <(node_mksnapshot_exec) <(node_mksnapshot_u_exec) && paxmark.sh m <(node_mksnapshot_u_exec)',
++                  ],
++                },
+                 {
+                   'action_name': 'node_mksnapshot',
+                   'process_outputs_as_sources': 1,
+                   'inputs': [
+-                    '<(node_mksnapshot_exec)',
++                    '<(node_mksnapshot_u_exec)',
+                     '<(node_snapshot_main)',
+                   ],
+                   'outputs': [
+diff --git a/tools/v8_gypfiles/v8.gyp b/tools/v8_gypfiles/v8.gyp
+index f822c056e5..8b2820abf7 100644
+--- a/tools/v8_gypfiles/v8.gyp
++++ b/tools/v8_gypfiles/v8.gyp
+@@ -9,6 +9,7 @@
+     'v8_vector_stores%': 0,
+     'v8_embed_script%': "",
+     'mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
++    'mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'v8_os_page_size%': 0,
+     'generate_bytecode_output_root': '<(SHARED_INTERMEDIATE_DIR)/generate-bytecode-output-root',
+     'generate_bytecode_builtins_list_output': '<(generate_bytecode_output_root)/builtins-generated/bytecodes-builtins-list.h',
+@@ -1520,7 +1521,7 @@
+       ],
+     },  # bytecode_builtins_list_generator
+     {
+-      'target_name': 'mksnapshot',
++      'target_name': 'mksnapshot_u',
+       'type': 'executable',
+       'dependencies': [
+         'v8_base_without_compiler',
+@@ -1545,6 +1546,27 @@
+           'ldflags': [ '-fno-lto' ],
+         }],
+       ],
++    },  # mksnapshot_u
++    {
++      'target_name': 'mksnapshot',
++      'type': 'none',
++      'dependencies': ['mksnapshot_u'],
++      'actions': [
++        {
++          'action_name': 'paxmark_mksnapshot',
++          'inputs': [
++            '<(mksnapshot_u_exec)',
++          ],
++          'outputs': [
++            '<(mksnapshot_exec)',
++          ],
++          'action': [
++            'bash',
++            '-c',
++            'cp <(mksnapshot_u_exec) <(mksnapshot_exec) && paxmark.sh m <(mksnapshot_exec)'
++          ],
++        },
++      ],
+     },  # mksnapshot
+     {
+       'target_name': 'torque',

diff --git a/net-libs/nodejs/nodejs-20.6.1.ebuild b/net-libs/nodejs/nodejs-20.6.1.ebuild
index a70dfde5f996..ad9c3ca7ca9d 100644
--- a/net-libs/nodejs/nodejs-20.6.1.ebuild
+++ b/net-libs/nodejs/nodejs-20.6.1.ebuild
@@ -108,7 +108,7 @@ src_prepare() {
 	fi
 
 	# We need to disable mprotect on two files when it builds Bug 694100.
-	use pax-kernel && PATCHES+=( "${FILESDIR}"/${PN}-18.16.0-paxmarking.patch )
+	use pax-kernel && PATCHES+=( "${FILESDIR}"/${PN}-20.6.0-paxmarking.patch )
 
 	default
 }


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2023-11-02 21:57 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2023-11-02 21:57 UTC (permalink / raw
  To: gentoo-commits

commit:     104857383c91f4de3d3d69db471d484b18789ed2
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Thu Nov  2 21:56:00 2023 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Thu Nov  2 21:57:13 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=10485738

net-libs/nodejs: restore 16.20.2

This is needed for now because of www-apps/kibana-bin

Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/Manifest                           |   1 +
 .../nodejs/files/nodejs-16.4.2-paxmarking.patch    | 113 ++++++++++
 net-libs/nodejs/nodejs-16.20.2.ebuild              | 234 +++++++++++++++++++++
 3 files changed, 348 insertions(+)

diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
index ad818c2e3af1..e19984278cbd 100644
--- a/net-libs/nodejs/Manifest
+++ b/net-libs/nodejs/Manifest
@@ -1,3 +1,4 @@
+DIST node-v16.20.2.tar.xz 36834468 BLAKE2B 88bd0d91a6b69f7e5fba2b087684b07b8986fd1492f51f6fdccc02f043970303808c0cc1eeda29670aacddd4234ec3181752c916fefee060624b0462dff8cbcf SHA512 c7953630b7d0eb832ab5a4b839c07e6505cf5f4e37853f59cd0ffc6b8742ac2ecaba20bfb47d8995ef88f3c7005bb456c1eb70cb2fc6b6fc506e1d8b81f25cb4
 DIST node-v18.17.1.tar.xz 40788836 BLAKE2B 50e0dc0eecd68620ffa7457319e71124bbba302f6acff79286a30cf97442fb09a96cf8781456bafd5c2e497ba88cf392c141f0e221683da421b87f653b1ad7ca SHA512 fd6f586447ecd44ac6738da1cf7d54e74bd33ffd1ee1acc2e0e1bdaf0031bcaef85751d3dd590bb278eb502daf9c77f0763b5a181a30ee4cf537aef254629622
 DIST node-v18.18.0.tar.xz 40813264 BLAKE2B 6cea11a663e5df730faef9125a80e730da83fdccebf8c4f454435ee622207803d59132b5d8e112741702103a6814a491b29bb9f22ddec60fba204236a763b95e SHA512 c10fb40902fc290cc069e86659ff4c7768215f80a7016402915cae7731bfd69aa901b7dc813d480f86fc39a850960f600ddde342d67b9bb570a3d2424b04f733
 DIST node-v18.18.2.tar.xz 40834428 BLAKE2B b2fcedd79fc8ca6a5b9236614874b9840d4df5f37f5ecfa5599a177b237543788eb985e8828f7a028f5fbca17aa0c4879393b956d08dce13bd04ec9e253aa48e SHA512 00af3c737d735a320481d764f1c23b1348c0454f2b9700cadb10e087feb47c75e7e9344277bb3149305c3e08ff69d9b17b0da81b1b9d9e978fd830c67858ce92

diff --git a/net-libs/nodejs/files/nodejs-16.4.2-paxmarking.patch b/net-libs/nodejs/files/nodejs-16.4.2-paxmarking.patch
new file mode 100644
index 000000000000..41abd1f1917f
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-16.4.2-paxmarking.patch
@@ -0,0 +1,113 @@
+diff -urNp node-v15.8.0-orig/node.gyp node-v15.8.0-dwok/node.gyp
+--- node-v15.8.0-orig/node.gyp	2021-02-24 22:21:44.202911780 +0100
++++ node-v15.8.0-dwok/node.gyp	2021-02-24 22:25:34.298281739 +0100
+@@ -53,7 +53,9 @@
+       'deps/cjs-module-lexer/dist/lexer.js',
+     ],
+     'node_mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot<(EXECUTABLE_SUFFIX)',
++    'node_mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)node_mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'mkcodecache_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache<(EXECUTABLE_SUFFIX)',
++    'mkcodecache_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mkcodecache_u<(EXECUTABLE_SUFFIX)',
+     'conditions': [
+       ['GENERATOR == "ninja"', {
+         'node_text_start_object_path': 'src/large_pages/node_text_start.node_text_start.o'
+@@ -291,10 +293,24 @@
+           ],
+           'actions': [
+             {
++              'action_name': 'run_pax_mkcodecache',
++              'inputs': [
++                '<(mkcodecache_exec)',
++              ],
++              'outputs': [
++                '<(mkcodecache_u_exec)',
++              ],
++              'action': [
++                'bash',
++                '-c',
++                'mv <(mkcodecache_exec) <(mkcodecache_u_exec) && paxmark.sh m <(mkcodecache_u_exec)',
++              ],
++            },
++            {
+               'action_name': 'run_mkcodecache',
+               'process_outputs_as_sources': 1,
+               'inputs': [
+-                '<(mkcodecache_exec)',
++                '<(mkcodecache_u_exec)',
+               ],
+               'outputs': [
+                 '<(SHARED_INTERMEDIATE_DIR)/node_code_cache.cc',
+@@ -316,10 +332,24 @@
+           ],
+           'actions': [
+             {
++              'action_name': 'run_pax_mksnapshot',
++              'inputs': [
++                '<(node_mksnapshot_exec)',
++              ],
++              'outputs': [
++                '<(node_mksnapshot_u_exec)',
++              ],
++              'action': [
++                'bash',
++                '-c',
++                'mv <(node_mksnapshot_exec) <(node_mksnapshot_u_exec) && paxmark.sh m <(node_mksnapshot_u_exec)',
++              ],
++            },
++            {
+               'action_name': 'node_mksnapshot',
+               'process_outputs_as_sources': 1,
+               'inputs': [
+-                '<(node_mksnapshot_exec)',
++                '<(node_mksnapshot_u_exec)',
+               ],
+               'outputs': [
+                 '<(SHARED_INTERMEDIATE_DIR)/node_snapshot.cc',
+diff -urNp node-v15.8.0-orig/tools/v8_gypfiles/v8.gyp node-v15.8.0-dwok/tools/v8_gypfiles/v8.gyp
+--- node-v15.8.0-orig/tools/v8_gypfiles/v8.gyp	2021-02-24 22:21:44.654910571 +0100
++++ node-v15.8.0-dwok/tools/v8_gypfiles/v8.gyp	2021-02-24 22:25:54.834224791 +0100
+@@ -9,6 +9,7 @@
+     'v8_vector_stores%': 0,
+     'v8_embed_script%': "",
+     'mksnapshot_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
++    'mksnapshot_u_exec': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot_u<(EXECUTABLE_SUFFIX)',
+     'v8_os_page_size%': 0,
+     'generate_bytecode_output_root': '<(SHARED_INTERMEDIATE_DIR)/generate-bytecode-output-root',
+     'generate_bytecode_builtins_list_output': '<(generate_bytecode_output_root)/builtins-generated/bytecodes-builtins-list.h',
+@@ -1430,7 +1431,7 @@
+       ],
+     },  # bytecode_builtins_list_generator
+     {
+-      'target_name': 'mksnapshot',
++      'target_name': 'mksnapshot_u',
+       'type': 'executable',
+       'dependencies': [
+         'v8_base_without_compiler',
+@@ -1449,6 +1450,27 @@
+           'toolsets': ['host'],
+         }],
+       ],
++    },  # mksnapshot_u
++    {
++      'target_name': 'mksnapshot',
++      'type': 'none',
++      'dependencies': ['mksnapshot_u'],
++      'actions': [
++        {
++          'action_name': 'paxmark_mksnapshot',
++          'inputs': [
++            '<(mksnapshot_u_exec)',
++          ],
++          'outputs': [
++            '<(mksnapshot_exec)',
++          ],
++          'action': [
++            'bash',
++            '-c',
++            'cp <(mksnapshot_u_exec) <(mksnapshot_exec) && paxmark.sh m <(mksnapshot_exec)'
++          ],
++        },
++      ],
+     },  # mksnapshot
+     {
+       'target_name': 'torque',

diff --git a/net-libs/nodejs/nodejs-16.20.2.ebuild b/net-libs/nodejs/nodejs-16.20.2.ebuild
new file mode 100644
index 000000000000..945fdbb0a1ab
--- /dev/null
+++ b/net-libs/nodejs/nodejs-16.20.2.ebuild
@@ -0,0 +1,234 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CONFIG_CHECK="~ADVISE_SYSCALLS"
+PYTHON_COMPAT=( python3_{9..11} )
+PYTHON_REQ_USE="threads(+)"
+
+inherit bash-completion-r1 flag-o-matic linux-info pax-utils python-any-r1 toolchain-funcs xdg-utils
+
+DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine"
+HOMEPAGE="https://nodejs.org/"
+LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
+
+if [[ ${PV} == *9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/nodejs/node"
+	SLOT="0"
+else
+	SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
+	SLOT="0/$(ver_cut 1)"
+	KEYWORDS="amd64 arm arm64 ppc64 ~riscv x86 ~amd64-linux ~x64-macos"
+	S="${WORKDIR}/node-v${PV}"
+fi
+
+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 )"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND=">=app-arch/brotli-1.0.9:=
+	>=dev-libs/libuv-1.40.0:=
+	>=net-dns/c-ares-1.18.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= )
+	sys-devel/gcc:*"
+BDEPEND="${PYTHON_DEPS}
+	sys-apps/coreutils
+	virtual/pkgconfig
+	systemtap? ( dev-util/systemtap )
+	test? ( net-misc/curl )
+	pax-kernel? ( sys-apps/elfix )"
+DEPEND="${RDEPEND}"
+
+pkg_pretend() {
+	(use x86 && ! use cpu_flags_x86_sse2) && \
+		die "Your CPU doesn't support the required SSE2 instruction."
+}
+
+pkg_setup() {
+	python-any-r1_pkg_setup
+	linux-info_pkg_setup
+}
+
+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
+
+	# 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}-16.4.2-paxmarking.patch )
+
+	default
+}
+
+src_configure() {
+	xdg_environment_reset
+
+	# LTO compiler flags are handled by configure.py itself
+	filter-lto
+	# nodejs unconditionally links to libatomic #869992
+	# specifically it requires __atomic_is_lock_free which
+	# is not yet implemented by sys-libs/compiler-rt (see
+	# https://reviews.llvm.org/D85044?id=287068), therefore
+	# we depend on gcc and force using libgcc as the support lib
+	tc-is-clang && append-ldflags "--rtlib=libgcc --unwindlib=libgcc"
+
+	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";;
+		lp64*) myarch="riscv64";;
+		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
+		keepdir /etc/npm
+		echo "NPM_CONFIG_GLOBALCONFIG=${EPREFIX}/etc/npm/npmrc" > "${T}"/50npm
+		doenvd "${T}"/50npm
+
+		# Install bash completion for `npm`
+		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
+
+		# 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() {
+	local drop_tests=(
+		test/parallel/test-dns-setserver-when-querying.js
+		test/parallel/test-fs-mkdir.js
+		test/parallel/test-fs-utimes-y2K38.js
+		test/parallel/test-release-npm.js
+		test/parallel/test-socket-write-after-fin-error.js
+		test/parallel/test-tls-streamwrap-buffersize.js
+		test/sequential/test-util-debug.js
+	)
+	rm -f "${drop_tests[@]}"
+
+	out/${BUILDTYPE}/cctest || die
+	"${EPYTHON}" tools/test.py --mode=${BUILDTYPE,,} --flaky-tests=dontcare -J message parallel sequential || die
+}
+
+pkg_postinst() {
+	if use npm; then
+		ewarn "remember to run: source /etc/profile if you plan to use nodejs"
+		ewarn "	in your current shell"
+	fi
+}


^ permalink raw reply related	[flat|nested] 36+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/
@ 2023-11-06 15:42 William Hubbs
  0 siblings, 0 replies; 36+ messages in thread
From: William Hubbs @ 2023-11-06 15:42 UTC (permalink / raw
  To: gentoo-commits

commit:     5a367252e37e26524a0008a4923ba37ac08fc403
Author:     William Hubbs <williamh <AT> gentoo <DOT> org>
AuthorDate: Mon Nov  6 15:41:36 2023 +0000
Commit:     William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Mon Nov  6 15:41:36 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5a367252

net-libs/nodejs: gcc 14 porting fixes

Bug: https://bugs.gentoo.org/916754
Signed-off-by: William Hubbs <williamh <AT> gentoo.org>

 net-libs/nodejs/files/nodejs-20.8.1-gcc14.patch | 24 ++++++++++++++++++++++++
 net-libs/nodejs/nodejs-20.8.1-r1.ebuild         |  1 +
 net-libs/nodejs/nodejs-20.9.0.ebuild            |  4 ++++
 3 files changed, 29 insertions(+)

diff --git a/net-libs/nodejs/files/nodejs-20.8.1-gcc14.patch b/net-libs/nodejs/files/nodejs-20.8.1-gcc14.patch
new file mode 100644
index 000000000000..ee34d4ed2e7f
--- /dev/null
+++ b/net-libs/nodejs/files/nodejs-20.8.1-gcc14.patch
@@ -0,0 +1,24 @@
+https://chromium-review.googlesource.com/c/v8/v8/+/4583222
+
+From 6100b929273cffbd1377e21cce2cd0f83e99e459 Mon Sep 17 00:00:00 2001
+From: Sam James <sam@gentoo.org>
+Date: Sun, 04 Jun 2023 04:15:16 +0100
+Subject: [PATCH] heap: Add missing <algorithm> include for std::remove
+
+GCC 14 changes some internal includes within libstdc++ so this transient
+include gets lost. Include <algorithm> explicitly for std::remove.
+
+Change-Id: Iab8a2c751a0f9c9dc6a770d6296ad6de724ef3bb
+---
+
+diff --git a/src/heap/cppgc/stats-collector.h b/src/heap/cppgc/stats-collector.h
+index 2cf7284..d8414ae 100644
+--- a/deps/v8/src/heap/cppgc/stats-collector.h
++++ b/deps/v8/src/heap/cppgc/stats-collector.h
+@@ -8,6 +8,7 @@
+ #include <stddef.h>
+ #include <stdint.h>
+
++#include <algorithm>
+ #include <atomic>
+ #include <vector>

diff --git a/net-libs/nodejs/nodejs-20.8.1-r1.ebuild b/net-libs/nodejs/nodejs-20.8.1-r1.ebuild
index ca388b4b5262..a6b4b1666cb1 100644
--- a/net-libs/nodejs/nodejs-20.8.1-r1.ebuild
+++ b/net-libs/nodejs/nodejs-20.8.1-r1.ebuild
@@ -62,6 +62,7 @@ CHECKREQS_DISK_BUILD="22G"
 
 PATCHES=(
 	"${FILESDIR}"/"${PN}"-20.3.0-gcc14.patch
+	"${FILESDIR}"/"${PN}"-20.8.1-gcc14.patch
 	)
 
 pkg_pretend() {

diff --git a/net-libs/nodejs/nodejs-20.9.0.ebuild b/net-libs/nodejs/nodejs-20.9.0.ebuild
index 58de8a867c1e..faa339ce0bd2 100644
--- a/net-libs/nodejs/nodejs-20.9.0.ebuild
+++ b/net-libs/nodejs/nodejs-20.9.0.ebuild
@@ -60,6 +60,10 @@ DEPEND="${RDEPEND}"
 CHECKREQS_MEMORY="8G"
 CHECKREQS_DISK_BUILD="22G"
 
+PATCHES=(
+	"${FILESDIR}"/"${PN}"-20.8.1-gcc14.patch
+	)
+
 pkg_pretend() {
 	if [[ ${MERGE_TYPE} != "binary" ]]; then
 		if is-flagq "-g*" && ! is-flagq "-g*0" ; then


^ permalink raw reply related	[flat|nested] 36+ messages in thread

end of thread, other threads:[~2023-11-06 15:42 UTC | newest]

Thread overview: 36+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-11-21 21:36 [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/files/, net-libs/nodejs/ Marek Szuba
  -- strict thread matches above, loose matches on Subject: below --
2023-11-06 15:42 William Hubbs
2023-11-02 21:57 William Hubbs
2023-09-14 22:45 William Hubbs
2023-09-07 15:51 William Hubbs
2023-04-27  2:04 William Hubbs
2023-04-17 17:20 William Hubbs
2023-03-05 23:18 William Hubbs
2022-10-28 15:57 Sam James
2022-09-16 16:16 William Hubbs
2022-09-14  6:14 William Hubbs
2022-06-11 21:04 William Hubbs
2022-05-04 19:02 William Hubbs
2022-05-04 18:50 William Hubbs
2022-05-04 18:25 William Hubbs
2022-05-04 17:57 William Hubbs
2022-03-17 21:39 William Hubbs
2021-06-24 11:15 Marek Szuba
2021-06-04 12:01 Marek Szuba
2021-05-09 14:29 Marek Szuba
2021-05-09 14:29 Marek Szuba
2021-05-04 15:42 Marek Szuba
2021-01-08 22:55 Marek Szuba
2020-11-13 17:25 Marek Szuba
2020-11-09 15:06 Marek Szuba
2020-09-04  7:09 Jeroen Roovers
2019-11-27 21:37 Magnus Granberg
2019-10-11 14:53 Jeroen Roovers
2019-03-16 14:45 Jeroen Roovers
2018-12-27 14:59 Jeroen Roovers
2018-12-13 12:50 Jeroen Roovers
2018-07-23 10:49 Jeroen Roovers
2017-11-15 15:13 Jeroen Roovers
2017-10-24  4:49 Jeroen Roovers
2017-08-18 14:17 Jeroen Roovers
2016-10-25  6:29 Jeroen Roovers

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox