Gentoo Archives: gentoo-commits

From: "Patrick Lauer (patrick)" <patrick@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-libs/iojs: iojs-2.5.0.ebuild ChangeLog
Date: Fri, 31 Jul 2015 02:55:59
Message-Id: 20150731025551.7AAFD113@oystercatcher.gentoo.org
1 patrick 15/07/31 02:55:51
2
3 Modified: ChangeLog
4 Added: iojs-2.5.0.ebuild
5 Log:
6 Bump
7
8 (Portage version: 2.2.20/cvs/Linux x86_64, unsigned Manifest commit)
9
10 Revision Changes Path
11 1.26 net-libs/iojs/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-libs/iojs/ChangeLog?rev=1.26&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-libs/iojs/ChangeLog?rev=1.26&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-libs/iojs/ChangeLog?r1=1.25&r2=1.26
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/net-libs/iojs/ChangeLog,v
20 retrieving revision 1.25
21 retrieving revision 1.26
22 diff -u -r1.25 -r1.26
23 --- ChangeLog 13 Jul 2015 02:50:03 -0000 1.25
24 +++ ChangeLog 31 Jul 2015 02:55:51 -0000 1.26
25 @@ -1,6 +1,11 @@
26 # ChangeLog for net-libs/iojs
27 # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/net-libs/iojs/ChangeLog,v 1.25 2015/07/13 02:50:03 patrick Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/net-libs/iojs/ChangeLog,v 1.26 2015/07/31 02:55:51 patrick Exp $
30 +
31 +*iojs-2.5.0 (31 Jul 2015)
32 +
33 + 31 Jul 2015; Patrick Lauer <patrick@g.o> +iojs-2.5.0.ebuild:
34 + Bump
35
36 *iojs-2.3.4 (13 Jul 2015)
37
38
39
40
41 1.1 net-libs/iojs/iojs-2.5.0.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-libs/iojs/iojs-2.5.0.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-libs/iojs/iojs-2.5.0.ebuild?rev=1.1&content-type=text/plain
45
46 Index: iojs-2.5.0.ebuild
47 ===================================================================
48 # Copyright 1999-2015 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/net-libs/iojs/iojs-2.5.0.ebuild,v 1.1 2015/07/31 02:55:51 patrick Exp $
51
52 EAPI=5
53
54 PYTHON_COMPAT=( python2_7 )
55
56 MY_PV="v${PV}"
57 MY_P="${PN}-${MY_PV}"
58
59 inherit flag-o-matic pax-utils python-single-r1 toolchain-funcs
60
61 DESCRIPTION="An npm compatible platform originally based on node.js"
62 HOMEPAGE="http://iojs.org/"
63 SRC_URI="http://iojs.org/dist/${MY_PV}/${MY_P}.tar.xz"
64
65 LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
66 SLOT="0"
67 KEYWORDS="~amd64 ~arm ~x86 ~x64-macos"
68 IUSE="debug icu +npm snapshot +ssl"
69
70 RDEPEND="icu? ( dev-libs/icu )
71 ${PYTHON_DEPS}
72 >=net-libs/http-parser-2.5
73 >=dev-libs/libuv-1.6.1
74 >=dev-libs/openssl-1.0.2d[-bindist]"
75 DEPEND="${RDEPEND}
76 !!net-libs/nodejs"
77 S="${WORKDIR}/${MY_P}"
78 REQUIRED_USE="${PYTHON_REQUIRED_USE}"
79
80 pkg_pretend() {
81 if ! test-flag-CXX -std=c++11 ; then
82 die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
83 fi
84 }
85
86 src_prepare() {
87 tc-export CC CXX PKG_CONFIG
88 export V=1 # Verbose build
89 export BUILDTYPE=Release
90
91 # fix compilation on Darwin
92 # http://code.google.com/p/gyp/issues/detail?id=260
93 sed -i -e "/append('-arch/d" tools/gyp/pylib/gyp/xcode_emulation.py || die
94
95 # make sure we use python2.* while using gyp
96 sed -i -e "s/python/${EPYTHON}/" deps/npm/node_modules/node-gyp/gyp/gyp || die
97 sed -i -e "s/|| 'python'/|| '${EPYTHON}'/" deps/npm/node_modules/node-gyp/lib/configure.js || die
98
99 # less verbose install output (stating the same as portage, basically)
100 sed -i -e "/print/d" tools/install.py || die
101
102 # proper libdir, hat tip @ryanpcmcquen https://github.com/iojs/io.js/issues/504
103 local LIBDIR=$(get_libdir)
104 sed -i -e "s|lib/|${LIBDIR}/|g" tools/install.py || die
105 sed -i -e "s/'lib'/'${LIBDIR}'/" lib/module.js || die
106 sed -i -e "s|\"lib\"|\"${LIBDIR}\"|" deps/npm/lib/npm.js || die
107
108 # Avoid a test that I've only been able to reproduce from emerge. It doesnt
109 # seem sandbox related either (invoking it from a sandbox works fine).
110 # The issue is that no stdin handle is openened when asked for one.
111 # It doesn't really belong upstream , so it'll just be removed until someone
112 # with more gentoo-knowledge than me (jbergstroem) figures it out.
113 rm test/parallel/test-stdout-close-unref.js || die
114
115 # debug builds. change install path, remove optimisations and override buildtype
116 if use debug; then
117 sed -i -e "s|out/Release/|out/Debug/|g" tools/install.py || die
118 BUILDTYPE=Debug
119 fi
120
121 epatch_user
122 }
123
124 src_configure() {
125 local myarch=""
126 local myconf+=( --shared-openssl --shared-libuv --shared-http-parser --shared-zlib )
127 use npm || myconf+=( --without-npm )
128 use icu && myconf+=( --with-intl=system-icu )
129 use snapshot && myconf+=( --with-snapshot )
130 use ssl || myconf+=( --without-ssl )
131 use debug && myconf+=( --debug )
132
133 case ${ABI} in
134 x86) myarch="ia32";;
135 amd64) myarch="x64";;
136 x32) myarch="x32";;
137 arm) myarch="arm";;
138 arm64) myarch="arm64";;
139 *) die "Unrecognized ARCH ${ARCH}";;
140 esac
141
142 "${PYTHON}" configure \
143 --prefix="${EPREFIX}"/usr \
144 --dest-cpu=${myarch} \
145 --without-dtrace \
146 "${myconf[@]}" || die
147 }
148
149 src_compile() {
150 emake -C out mksnapshot
151 pax-mark m "out/${BUILDTYPE}/mksnapshot"
152 emake -C out
153 }
154
155 src_install() {
156 local LIBDIR="${ED}/usr/$(get_libdir)"
157 emake install DESTDIR="${ED}" PREFIX=/usr
158 use npm && dodoc -r "${LIBDIR}"/node_modules/npm/html
159 rm -rf "${LIBDIR}"/node_modules/npm/{doc,html} || die
160 find "${LIBDIR}"/node_modules -type f -name "LICENSE*" -or -name "LICENCE*" -delete || die
161
162 # set up a symlink structure that npm expects..
163 dodir /usr/include/node/deps/{v8,uv}
164 dosym . /usr/include/node/src
165 for var in deps/{uv,v8}/include; do
166 dosym ../.. /usr/include/node/${var}
167 done
168
169 pax-mark -m "${ED}"/usr/bin/iojs
170 }
171
172 src_test() {
173 out/${BUILDTYPE}/cctest || die
174 declare -xl TESTTYPE="${BUILDTYPE}"
175 "${PYTHON}" tools/test.py --mode=${TESTTYPE} -J message parallel sequential || die
176 }
177
178 pkg_postinst() {
179 einfo "When using node-gyp to install native modules, you can avoid"
180 einfo "having to download the full tarball by doing the following:"
181 einfo ""
182 einfo "node-gyp --nodedir /usr/include/node <command>"
183 }