Gentoo Archives: gentoo-commits

From: Jeroen Roovers <jer@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-libs/nodejs/
Date: Tue, 28 May 2019 06:58:12
Message-Id: 1559026685.1ce818baa33f1affa463dfd68234644fc46adf9d.jer@gentoo
1 commit: 1ce818baa33f1affa463dfd68234644fc46adf9d
2 Author: Jeroen Roovers <jer <AT> gentoo <DOT> org>
3 AuthorDate: Tue May 28 06:57:40 2019 +0000
4 Commit: Jeroen Roovers <jer <AT> gentoo <DOT> org>
5 CommitDate: Tue May 28 06:58:05 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1ce818ba
7
8 net-libs/nodejs: Old
9
10 Package-Manager: Portage-2.3.67, Repoman-2.3.13
11 Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>
12
13 net-libs/nodejs/Manifest | 1 -
14 net-libs/nodejs/nodejs-12.2.0.ebuild | 208 -----------------------------------
15 2 files changed, 209 deletions(-)
16
17 diff --git a/net-libs/nodejs/Manifest b/net-libs/nodejs/Manifest
18 index 5f025a2dc6c..fa5a663689f 100644
19 --- a/net-libs/nodejs/Manifest
20 +++ b/net-libs/nodejs/Manifest
21 @@ -2,7 +2,6 @@ DIST node-v0.12.18.tar.gz 19842591 BLAKE2B f94f4de6e2875267be194580c645087a262b9
22 DIST node-v10.15.3.tar.xz 20262632 BLAKE2B d65d4e274fa829be5cda1970b0ebe7081e8476334cb825e5727324c3202bc015f4ba39589608284d0f8c0b722079c06d1587de5299a3c81ccb7b0eacbdaccf84 SHA512 cf741f733af7a7e1fbd37b0f98110078494b4771dbdfccacfda95a5ea4cda6cdcea4f8d31dddcf27477213614e4ab6cf7d1a1f900cb92936333730737ac4f9e8
23 DIST node-v11.14.0.tar.xz 22106812 BLAKE2B 3a8dd9feb5916f235bf69d0610e32c1861e64f427b6de5ec27b3634268f273826f271cf5ea821042420d3b3f348124be2ce2fda13d0addea092db1338c9f95f7 SHA512 4e8033ea0f326fe5a8372c81771cd58242881ac7db905f697ce79ef9cb3ba2dfe2b94fb24a36775761c72ac531096c5e18a8574f933d76c1b652b18419b25446
24 DIST node-v11.15.0.tar.xz 22115480 BLAKE2B ed1f621e46d24051f8d84255875e7cb2c1bc0f9432a12fcc35dc5e336a71bb3e7f511146d112d1f236f9f978a68987d80331c22699479ce63b7bf30e50643219 SHA512 48270620fab3eef86c21387b316ce9054e2b0aac60a36f7fc08d18ad4a11c8d2082886ca20a455fb4a74a561d7e97c77403227ec9a83a13c47fa230b47a5af2e
25 -DIST node-v12.2.0.tar.xz 22436748 BLAKE2B bb578aad8ad49ee542716086591d896c325083d48b7e69b8b0e9644db2b43546872eaba4b7b6a8b983cb7b21fc948705af88cbf883f275af76bd24918088d584 SHA512 00cda17e5fcce771ea461941d6cdd258545ac295bfbe7543f3153278e73fddbe117dd81c4e22716c147eddaab2577f50abf2a3235b18b4eca60180dee050dd7b
26 DIST node-v12.3.0.tar.xz 22448392 BLAKE2B 8c6e40d9bcfee315b6bb5f97846db27ebeae2520fcde5ede942af2f24032101c06653dded9d4fa77992fcdaf5b0f67452e5e3cbb032bd33cde4dc496a652c283 SHA512 4b97524781efb8c284337b36d1b02576aa6703aa37d0775329eff735f38bcb5391364bd420914fa75088b97e72fe087e263a41fb2367fc8e8f7f63ebf4a949e6
27 DIST node-v12.3.1.tar.xz 22462972 BLAKE2B f28b5594aca3701735a178873ae426ebde27a6abb5b13115c6ca2a32bb2e2532f60a96722b07737246bdf8a1dce799e86f920a355278ad8619d9931319a6e81a SHA512 40e05550d48b0b8739fcd6ef66a70e53e85106af486c2f99aad58fe10c8f33e5473ab5afb59849960ce828f5c8bb21f26cecbbfb31852a2f2c6aa3916449b44d
28 DIST node-v4.9.1.tar.xz 13250164 BLAKE2B 7a689b99bb4bf507f7f21dd2c096a5766d023a8174c0f468cab37365af1920b8700da04157e1a406917790524255ef32c243a74662fd50ef7d3567d189dac9cf SHA512 690c9fdf608e5194069a10955bdd94ec87cb1c308f13bc4d2cae92fa01436ace10fadf58f2e51d477dde6c570b23edc1c71fafea79bfc9cab2903eb2fa5f87aa
29
30 diff --git a/net-libs/nodejs/nodejs-12.2.0.ebuild b/net-libs/nodejs/nodejs-12.2.0.ebuild
31 deleted file mode 100644
32 index 54f1648d778..00000000000
33 --- a/net-libs/nodejs/nodejs-12.2.0.ebuild
34 +++ /dev/null
35 @@ -1,208 +0,0 @@
36 -# Copyright 1999-2019 Gentoo Authors
37 -# Distributed under the terms of the GNU General Public License v2
38 -
39 -EAPI=7
40 -PYTHON_COMPAT=( python2_7 )
41 -PYTHON_REQ_USE="threads"
42 -inherit bash-completion-r1 flag-o-matic pax-utils python-single-r1 toolchain-funcs
43 -
44 -DESCRIPTION="A JavaScript runtime built on Chrome's V8 JavaScript engine"
45 -HOMEPAGE="https://nodejs.org/"
46 -SRC_URI="https://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz"
47 -
48 -LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
49 -SLOT="0"
50 -KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x64-macos"
51 -IUSE="cpu_flags_x86_sse2 debug doc icu inspector +npm +snapshot +ssl systemtap test"
52 -REQUIRED_USE="
53 - ${PYTHON_REQUIRED_USE}
54 - inspector? ( icu ssl )
55 - npm? ( ssl )
56 -"
57 -
58 -RDEPEND="
59 - >=dev-libs/libuv-1.28.0:=
60 - >=net-dns/c-ares-1.15.0
61 - >=net-libs/http-parser-2.8.0:=
62 - >=net-libs/nghttp2-1.38.0
63 - sys-libs/zlib
64 - icu? ( >=dev-libs/icu-64.2:= )
65 - ssl? ( >=dev-libs/openssl-1.1.1:0= )
66 -"
67 -DEPEND="
68 - ${RDEPEND}
69 - ${PYTHON_DEPS}
70 - systemtap? ( dev-util/systemtap )
71 - test? ( net-misc/curl )
72 -"
73 -PATCHES=(
74 - "${FILESDIR}"/${PN}-10.3.0-global-npm-config.patch
75 - "${FILESDIR}"/${PN}-99999999-llhttp.patch
76 -)
77 -S="${WORKDIR}/node-v${PV}"
78 -
79 -pkg_pretend() {
80 - (use x86 && ! use cpu_flags_x86_sse2) && \
81 - die "Your CPU doesn't support the required SSE2 instruction."
82 -
83 - ( [[ ${MERGE_TYPE} != "binary" ]] && ! test-flag-CXX -std=c++11 ) && \
84 - die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
85 -}
86 -
87 -src_prepare() {
88 - tc-export CC CXX PKG_CONFIG
89 - export V=1
90 - export BUILDTYPE=Release
91 -
92 - # fix compilation on Darwin
93 - # https://code.google.com/p/gyp/issues/detail?id=260
94 - sed -i -e "/append('-arch/d" tools/gyp/pylib/gyp/xcode_emulation.py || die
95 -
96 - # make sure we use python2.* while using gyp
97 - sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
98 - sed -i -e "s/|| 'python2'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || die
99 -
100 - # less verbose install output (stating the same as portage, basically)
101 - sed -i -e "/print/d" tools/install.py || die
102 -
103 - # proper libdir, hat tip @ryanpcmcquen https://github.com/iojs/io.js/issues/504
104 - local LIBDIR=$(get_libdir)
105 - sed -i -e "s|lib/|${LIBDIR}/|g" tools/install.py || die
106 - sed -i -e "s/'lib'/'${LIBDIR}'/" deps/npm/lib/npm.js || die
107 -
108 - # Avoid writing a depfile, not useful
109 - sed -i -e "/DEPFLAGS =/d" tools/gyp/pylib/gyp/generator/make.py || die
110 -
111 - sed -i -e "/'-O3'/d" common.gypi node.gypi || die
112 -
113 - # Avoid a test that I've only been able to reproduce from emerge. It doesnt
114 - # seem sandbox related either (invoking it from a sandbox works fine).
115 - # The issue is that no stdin handle is openened when asked for one.
116 - # It doesn't really belong upstream , so it'll just be removed until someone
117 - # with more gentoo-knowledge than me (jbergstroem) figures it out.
118 - rm test/parallel/test-stdout-close-unref.js || die
119 -
120 - # debug builds. change install path, remove optimisations and override buildtype
121 - if use debug; then
122 - sed -i -e "s|out/Release/|out/Debug/|g" tools/install.py || die
123 - BUILDTYPE=Debug
124 - fi
125 -
126 - default
127 -}
128 -
129 -src_configure() {
130 - local myconf=(
131 - --shared-cares --shared-http-parser --shared-libuv --shared-nghttp2
132 - --shared-zlib
133 - )
134 - use debug && myconf+=( --debug )
135 - use icu && myconf+=( --with-intl=system-icu ) || myconf+=( --with-intl=none )
136 - use inspector || myconf+=( --without-inspector )
137 - use npm || myconf+=( --without-npm )
138 - use snapshot && myconf+=( --with-snapshot )
139 - use ssl && myconf+=( --shared-openssl --openssl-use-def-ca-store ) || myconf+=( --without-ssl )
140 -
141 - local myarch=""
142 - case ${ABI} in
143 - amd64) myarch="x64";;
144 - arm) myarch="arm";;
145 - arm64) myarch="arm64";;
146 - ppc64) myarch="ppc64";;
147 - x32) myarch="x32";;
148 - x86) myarch="ia32";;
149 - *) myarch="${ABI}";;
150 - esac
151 -
152 - GYP_DEFINES="linux_use_gold_flags=0
153 - linux_use_bundled_binutils=0
154 - linux_use_bundled_gold=0" \
155 - "${PYTHON}" configure \
156 - --prefix="${EPREFIX}"/usr \
157 - --dest-cpu=${myarch} \
158 - $(use_with systemtap dtrace) \
159 - "${myconf[@]}" || die
160 -}
161 -
162 -src_compile() {
163 - emake -C out mksnapshot
164 - pax-mark m "out/${BUILDTYPE}/mksnapshot"
165 - emake -C out
166 -}
167 -
168 -src_install() {
169 - local LIBDIR="${ED}/usr/$(get_libdir)"
170 - default
171 -
172 - pax-mark -m "${ED}"usr/bin/node
173 -
174 - # set up a symlink structure that node-gyp expects..
175 - dodir /usr/include/node/deps/{v8,uv}
176 - dosym . /usr/include/node/src
177 - for var in deps/{uv,v8}/include; do
178 - dosym ../.. /usr/include/node/${var}
179 - done
180 -
181 - if use doc; then
182 - # Patch docs to make them offline readable
183 - for i in `grep -rl 'fonts.googleapis.com' "${S}"/out/doc/api/*`; do
184 - sed -i '/fonts.googleapis.com/ d' $i;
185 - done
186 - # Install docs
187 - docinto html
188 - dodoc -r "${S}"/doc/*
189 - fi
190 -
191 - if use npm; then
192 - dodir /etc/npm
193 -
194 - # Install bash completion for `npm`
195 - # We need to temporarily replace default config path since
196 - # npm otherwise tries to write outside of the sandbox
197 - local npm_config="usr/$(get_libdir)/node_modules/npm/lib/config/core.js"
198 - sed -i -e "s|'/etc'|'${ED}/etc'|g" "${ED}/${npm_config}" || die
199 - local tmp_npm_completion_file="$(emktemp)"
200 - "${ED}/usr/bin/npm" completion > "${tmp_npm_completion_file}"
201 - newbashcomp "${tmp_npm_completion_file}" npm
202 - sed -i -e "s|'${ED}/etc'|'/etc'|g" "${ED}/${npm_config}" || die
203 -
204 - # Move man pages
205 - doman "${LIBDIR}"/node_modules/npm/man/man{1,5,7}/*
206 -
207 - # Clean up
208 - rm "${LIBDIR}"/node_modules/npm/{.mailmap,.npmignore,Makefile} || die
209 - rm -rf "${LIBDIR}"/node_modules/npm/{doc,html,man} || die
210 -
211 - local find_exp="-or -name"
212 - local find_name=()
213 - for match in "AUTHORS*" "CHANGELOG*" "CONTRIBUT*" "README*" \
214 - ".travis.yml" ".eslint*" ".wercker.yml" ".npmignore" \
215 - "*.md" "*.markdown" "*.bat" "*.cmd"; do
216 - find_name+=( ${find_exp} "${match}" )
217 - done
218 -
219 - # Remove various development and/or inappropriate files and
220 - # useless docs of dependend packages.
221 - find "${LIBDIR}"/node_modules \
222 - \( -type d -name examples \) -or \( -type f \( \
223 - -iname "LICEN?E*" \
224 - "${find_name[@]}" \
225 - \) \) -exec rm -rf "{}" \;
226 - fi
227 -
228 - mv "${ED}"/usr/share/doc/node "${ED}"/usr/share/doc/${PF} || die
229 -}
230 -
231 -src_test() {
232 - out/${BUILDTYPE}/cctest || die
233 - "${PYTHON}" tools/test.py --mode=${BUILDTYPE,,} -J message parallel sequential || die
234 -}
235 -
236 -pkg_postinst() {
237 - elog "The global npm config lives in /etc/npm. This deviates slightly"
238 - elog "from upstream which otherwise would have it live in /usr/etc/."
239 - elog ""
240 - elog "Protip: When using node-gyp to install native modules, you can"
241 - elog "avoid having to download extras by doing the following:"
242 - elog "$ node-gyp --nodedir /usr/include/node <command>"
243 -}