Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

net-libs/iojs-1.7.1 version bump #95

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion net-libs/iojs/Manifest
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
AUX iojs-1.2.0-pkgconfig.patch 1715 SHA256 da19714dc8dd0732a91433762351e4c23a0a65ad7a979486d4fbc68bfa1a832e SHA512 3e96be5ca5ad9447238eef506263584f47139e2d8b46c794c6b6f77491fb42187a182beccbad70f97f0fcd14750f501196a529066d0f1416947539a416c98153 WHIRLPOOL 3f9a942da04455fa95a2f2c52a6648874ea81d63de6b5161e5d0e20240e6512c438a445ec29622d355af7069f52f5c84ed9b5cb65d9846ff304295ec5e3d1451
AUX iojs-1.7.1-pkgconfig.patch 1628 SHA256 2184435bfdc48488009da2bac7bd157796acba22506aba6775a0f934eb263159 SHA512 0627d5f46d1a06c532884116b2aa7f2515a18711cea548389b3a6d92b88d5f6b3fdb148b609223c1c21dc7a36348db24a4c448c517c6937796052f76218552c1 WHIRLPOOL 52386ac67d7b234521fa3cf1c289d30bf353349003386aa748b86fa2277ca62aca5aa163b7607e9c48f61a1adc62b0275b644296da914a866a1d5464d052a4f1
DIST iojs-v1.0.4.tar.xz 12284732 SHA256 c902f5abbd59c56346680f0b4a71056c51610847b9576acf83a9c210bf664e98 SHA512 0e3d4f66fc7f64e09f999b1fdb7bbbfe80a5cfd0396ec718bf166ae44bcb27eebf5b59c3cd4a74f050b59ee529678b1bdef1c3b9d71534c8ac0ab8caf8472021 WHIRLPOOL cfd766a513877f6ccfddc4e1eb4e0be4fa987dbac7c7c8159f70556b72a01b26fdd7d92be3fcb7efc37691b6808c8d570199741f01f95df77dd9aa95312bac9e
DIST iojs-v1.1.0.tar.xz 12309452 SHA256 2baa9b076c84c13b0572de4618ac94058fc98a87266925bcd18fb70fb7d521a7 SHA512 2a01632a5afa828ab3fcfc2bf44557a4aba5b150e3b4a7d66bc4c415f96c5cbe802bbfe6085d483a6fea75eae48b963892faf1e2f50f5ae291ee0fdbb87da912 WHIRLPOOL f6d9c3f93a11d29f4d0b2ec24141d80d195749e5625a0bcaddfed7fca271b311121bb29f83c7b591869aae327a5f36ef86f5f98844a8b924b0b30e8eece58a08
DIST iojs-v1.2.0.tar.xz 12327228 SHA256 d33b448d173a0df675c471d24a33db57208c30b3e30b8c49f3b1d0666178e9cb SHA512 2f42141d234f4ac468f6bc794a051338322b5d0709d2a54e8efd2b5180a5e6e5877cf727ecd2f0f20e8a504522ba938af5c0ed2b3d822a001bfb1e05d04eaed8 WHIRLPOOL a188242252ebd87a5e17a129e09751e49c36009f5bb818a0ad31828bfb7d1c3d397a61ca4fe1b91f10603fafcd1944afdd0c6fda9fef7610b8bee2afac518355
Expand All @@ -7,6 +8,7 @@ DIST iojs-v1.4.1.tar.xz 12352156 SHA256 fdb2aa43f3099855532ebdec50c4bf8c62b971d1
DIST iojs-v1.5.1.tar.xz 10458032 SHA256 edf7fe994b72f70cc2c8e6d971ad94f576cdb36b2be008471e5b0d3af61a77fc SHA512 97aecf0b5e36c0692f3220f3bdddcc901218ae0dd04ddcb408c5767f985e6b4e601849b835f74b66579010f8b6fdf372f48209682d16f5675ac087762801ef33 WHIRLPOOL 252b68a0874680280de103b85f9af2d841510114e526cbf603349b59e3ff04e7e424c96c9e2bb186e1e4e1f096cfebe35d0f66fbd853f5ca44259d91f4ec8059
DIST iojs-v1.6.2.tar.xz 10516028 SHA256 0015db12ebc7bdef4c44d88af08c964dea5fbf45a6e1218ed5ce26a275a4d3c6 SHA512 03a9dabdb5cfdf858f34acd0ca6442bf065eb7f098e117771eda3e528e9629bc4c76a260c0bcdcc07f4c02ca851118e926f4c510556477a79c69464f910b75ff WHIRLPOOL dbe2e185890b34270df361311b2765cbfb4fd9a692dc382df574c1b2c893ac6529192ad639aff0b27d1eb87d8419ba30b2208e1eaf2f087a4e2f576eb952bbae
DIST iojs-v1.6.3.tar.xz 10625872 SHA256 79954738268ef0952a61549b951230fac70ce0f7fc709cae25b1d53039430380 SHA512 b07a1eed5a96e0b8db006e0d75e526a05db1b04bea2155058e58a8dbd3f3a638d2cf64aef4afabef544a7db3f4c6652bd17b14f9fc4a90263d7ddcd29c48b0ae WHIRLPOOL 56de6fb7187e5041acd978c27ed85e12cb02a6b204c2c1ebe68a356f9fb8e552def1846c4ce30d4deff7230ab2fefeebc9adc756c91c556d52586c1d0a2bd6c0
DIST iojs-v1.7.1.tar.xz 10867156 SHA256 3c63010701b1968baf08d99327821c79746d0602ba71060c07d2bd9f1ff485f4 SHA512 4b3841d3098d41805d21a01d897740e9d9aaa1cc323a591d4c477faf893cfb00dcb4610ae93ac041566d543b1d6b19a6f17b17965d10b75c9667e6b4dcce3446 WHIRLPOOL c21be6348e56912fe193dea79becd5fccb97c0372eb6fdc59b60aa070bc30cfe96f055709f565a13411c17212d04029861f197fb57a2bdce795bf5ef41839529
EBUILD iojs-1.0.4-r1.ebuild 3206 SHA256 884a98f1736ded1fdc73b076307054763eead3cbb69fb6198b7238832cfc6f46 SHA512 99519f8f678ada8dc6c25645866e382a5994cdb4d65792bfad43a3e2018599d02d2762d51b6b2961622b3eaf5da1c005bc78d762e506c92ed4045da8c6800a7d WHIRLPOOL 65edebb0c07bc39bdf00eb368f37a08e2c3e9e46bce29c4cb43942fc1e9cacc6e1e5ff39e89f3749a43b58c31636dbd9e1b7fccd703bdda7a852f078194ef3dc
EBUILD iojs-1.0.4.ebuild 2944 SHA256 4a78febd3440bc5fa021312c3994e462e5da8ed0e916003369bd0398bdd46e56 SHA512 15888b7647b29f50e9488a6497672aa2a686c1646b1403914cacfc51ce5b87a73417bbc0e384e4551fcdd2f631a33e4ffd5b089a692f4ac674c11ecde51824f7 WHIRLPOOL 22becab91f294b04ff7207fdd594e5639d51d9168d8bc6344f3332f88dede4e0dbfac03e0e46ef3bfe211f7f5caa08211d306563fbec1a236801747b6317fec0
EBUILD iojs-1.1.0.ebuild 3203 SHA256 d861b5e857e2ec150b7469e2928f13642944323027dd249406e7782fa7e8739e SHA512 fc9630b1e2b9db03f5a9e9aa7239321cd197b661bbcb9564b04755d25ef12bd92160abec20067a46a3ebd0160650713e00707c4e8ce87219a6fd799824c6133b WHIRLPOOL 84b40270e7f440c9caef7cff80ef2c30c18ce9830f66eb4c0316cba14c84e1e6fb9ab8cc9b59ae7f978c5433836470e7efae8d7d69467e7b4527c4a6b426fdd0
Expand All @@ -17,5 +19,6 @@ EBUILD iojs-1.5.1.ebuild 3233 SHA256 e2fca9deb651b58f479570aeca59f7e9d076b8b203b
EBUILD iojs-1.6.2.ebuild 3194 SHA256 16d3351798df810d7a65a3e040e01fc030447406a09443a2c4ae1720d4dd47b9 SHA512 6692d158e946bea196a5792d9ea493d6c6f8e2e3dbd0e320b48bc6b45409270babca96a901cdce2145da883f9304db73b233fb9a4f33b28242d9dee56178f39e WHIRLPOOL 5f12144db7748a6f23bc297f8f264844ac2446a40c67dc3d3a69f9c0e284902f92f219d1e6326bb7f4a9603f0c1f5a2bbdd3443ffa2a8b3fec6143dd7e5e72d8
EBUILD iojs-1.6.3-r1.ebuild 3319 SHA256 ffa0ce4359c1fbb892e9833e4d9aa340aa25188ff85eb9001fa27ee96b48568f SHA512 e22d5d724015a7ebfd9c8430563bcdbab96c380d74f9fb5822b0b6191d73a0f18b7b07449d963bbca1bbbbc334daa5f5ddff931ed2c7c333c85b800be16b026c WHIRLPOOL 1398a113361ee76babef901cefaef97491c517dec7d6d78e7df2aed8fa126eaa620108985c04d7767bdf7f3de7cc5cbca3f362aa95c5606866ff760aa5edd8c0
EBUILD iojs-1.6.3.ebuild 3194 SHA256 8895cae3249eb4e23fea9a8f169f4ce1d6ff07314eaa39a641b8d1a474c93514 SHA512 b82ea099551d4720cad4b49f8a463f6ee0d285f49f979d1e87ad55dfbd1d8273d0f3e9555e7b81b310a418302ace4871f4eba609fa821d27f22e616b883b2d58 WHIRLPOOL f8ef47a138ae118b6e75327ce3a914235839689d43eb20f881c0963a21baf8de82a01cea37bd0b0166d460ba044ca1f7960cae456e72b3eee9b9c7ae386bb123
EBUILD iojs-1.7.1.ebuild 3817 SHA256 c5c599194fe041d64901e2e725437ae98c5680ffe940f9620e0636d6bac64c32 SHA512 bf6fd934f063afe4992c1dcc8f99ac31c9478279da311ba17134bcd8e7b2af1a133896e655c3a72bb5fe32c7f1f897b08e1066263e19bb8999c282c68b45df84 WHIRLPOOL 1382621d67b692b47c5b0e82525a743a4f6993173738d24699458ff0158be9c6033398aac1a0d7f346ccee3da79ffd56941735070f8b9b2bce932959c673a9ab
MISC ChangeLog 2065 SHA256 e3c188387c6393cc6ad67121f460f855dd56a2e12ed10f23d61c28ec56ec7c00 SHA512 71629856710b802145c4a93402b8269847e494c57467672ab9183f542c1fa1835a74d85bae7bcf5ab6bdf861aa4b53be4e7e80f48f2ff41259512bdb43328bde WHIRLPOOL 55628366bfb0526705533b9c88d8f60b19438ee1de33d286d39586f1f5fdf4191161e9d1ecf690a902b0eb6ff759c5dd885273be955d14fabb3fd33abe26e9c0
MISC metadata.xml 619 SHA256 8f10a6ab63addd0163f1e9fdaca6967afd042984e7d87156a279c172bb8d33af SHA512 466393773f8b103604eb68890bd75ee3a1d308d9ec7e330c1b926d766cf015133fc75ec5dfef60014a8c01f0160d1e6efccfcdb27f656c2405a0c60b5c4baff6 WHIRLPOOL ec7d788a32828fe33b991b46e32a121b6ea914cbdf487cebd4a5d4058fdc1e611fbfc737fd448dcf195c90d1e2162e953cd141da51eba448336c7fda5d717032
MISC metadata.xml 945 SHA256 df3d5c5619158cca7f6b52111bb8c7d42ffc231061389c134984dfe7771f98e1 SHA512 ba2ae70644d857bed881e0fa67a2ce2a5741fe2e72d585c12bf81ec2ba42e414a76acae2601ccec0359fc700e5a275899c0212ed7a3079eec0da0a87a1d274a5 WHIRLPOOL 466a076e90fa6e2f9b0a802b3114ebaedd512ba735abdb0792948550c8fadbeea803c1f962efe631480141f23a034c3d3fc0aa9619ddb38b404136c885230841
48 changes: 48 additions & 0 deletions net-libs/iojs/files/iojs-1.7.1-pkgconfig.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
diff --git configure configure
index 67440a2..2a3b05f 100755
--- configure
+++ configure
@@ -326,12 +326,13 @@ def b(value):


def pkg_config(pkg):
- cmd = os.popen('pkg-config --libs %s' % pkg, 'r')
+ pkg_config = os.environ.get('PKG_CONFIG', 'pkg-config')
+ cmd = os.popen(pkg_config + ' --libs %s' % pkg, 'r')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you upstreaming this? :)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, and more.

libs = cmd.readline().strip()
ret = cmd.close()
if (ret): return None

- cmd = os.popen('pkg-config --cflags %s' % pkg, 'r')
+ cmd = os.popen(pkg_config + ' --cflags %s' % pkg, 'r')
cflags = cmd.readline().strip()
ret = cmd.close()
if (ret): return None
@@ -603,14 +604,21 @@ def configure_node(o):

def configure_libz(o):
o['variables']['node_shared_zlib'] = b(options.shared_zlib)
+ if b(options.shared_zlib) == 'true':
+ (libs, cflags) = pkg_config('zlib') or ('-lz', '')

- if b(options.shared_zlib) == True:
- o['libraries'] += ['-l%s' % options.shared_zlib_libname]
- if options.shared_zlib_libpath:
- o['libraries'] += ['-L%s' % options.shared_zlib_libpath]
- if options.shared_zlib_includes:
- o['include_dirs'] += [options.shared_zlib_includes]
+ if options.shared_zlib_libpath:
+ o['libraries'] += ['-L%s' % options.shared_zlib_libpath]

+ if options.shared_zlib_libname:
+ o['libraries'] += ['-l%s' % options.shared_zlib_libname]
+ else:
+ o['libraries'] += libs.split()
+
+ if options.shared_zlib_includes:
+ o['include_dirs'] += [options.shared_zlib_includes]
+ else:
+ o['cflags'] += cflags.split()

def configure_http_parser(o):
o['variables']['node_shared_http_parser'] = b(options.shared_http_parser)
127 changes: 127 additions & 0 deletions net-libs/iojs/iojs-1.7.1.ebuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI=5

PYTHON_COMPAT=( python2_7 )

MY_PV="v${PV}"
MY_P="${PN}-${MY_PV}"

inherit flag-o-matic pax-utils python-single-r1 toolchain-funcs

DESCRIPTION="An npm compatible platform originally based on node.js"
HOMEPAGE="http://iojs.org/"
SRC_URI="http://iojs.org/dist/${MY_PV}/${MY_P}.tar.xz"

LICENSE="Apache-1.1 Apache-2.0 BSD BSD-2 MIT"
SLOT="0"
KEYWORDS="~amd64 ~arm ~x86 ~x64-macos"
IUSE="bundled-libs debug icu +npm snapshot +ssl"

RDEPEND="icu? ( dev-libs/icu )
!bundled-libs? (
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't I just tell you this isn't going to fly?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I gave you feedback you never replied to - as well as suggesting a mitigation path forward on IRC.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, must've missed it when you changed the code and github ate old comments.

>=net-libs/http-parser-2.3
>=dev-libs/libuv-1.4.2
>=dev-libs/openssl-1.0.1m[-bindist]
)"
DEPEND="${RDEPEND}
${PYTHON_DEPS}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If scripts use it at runtime, this belongs in RDEPEND.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct. Thanks for spotting.

!!net-libs/nodejs"
S="${WORKDIR}/${MY_P}"

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

REQUIRED_USE=${PYTHON_REQUIRED_USE}

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok.

pkg_pretend() {
if ! test-flag-CXX -std=c++11 ; then
die "Your compiler doesn't support C++11. Use GCC 4.8, Clang 3.3 or newer."
fi
}

src_prepare() {
tc-export CC CXX PKG_CONFIG
export V=1 # Verbose build
export BUILDTYPE=Release

# fix compilation on Darwin
# http://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

epatch "${FILESDIR}"/${P}-pkgconfig.patch

# 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

# fix upstream bug regarding shared build logic (my own fault, jbergstroem)
sed -i -e "s/== True/== 'true'/g" configure || die
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess the above patch only fixes it partially?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pretty much. See above comment to the proper upstream patch which also makes us drop our pkg-config patch. The only fallout is libuv.


# 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
BUILDTYPE=Debug
fi
}

src_configure() {
local myconf=()
local myarch=""
use bundled-libs || 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

"${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}"
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" -delete

pax-mark -m "${ED}"/usr/bin/iojs
}

src_test() {
out/${BUILDTYPE}/cctest || die
declare -xl TESTTYPE="${BUILDTYPE}"
"${PYTHON}" tools/test.py --mode=${TESTTYPE} -J message parallel sequential || die
}
17 changes: 13 additions & 4 deletions net-libs/iojs/metadata.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,24 @@
<herd>proxy-maintainers</herd>
<maintainer>
<email>bugs@bergstroem.nu</email>
<name>Johan Bergstroem</name>
<name>Johan Bergström</name>
</maintainer>
<maintainer>
<email>patrick@gentoo.org</email>
<name>Patrick Lauer</name>
</maintainer>
<upstream>
<maintainer status="active">
<email>bugs@bergstroem.nu</email>
<name>Johan Bergström</name>
</maintainer>
<doc lang="en">https://iojs.org/api/</doc>
<changelog>https://github.com/iojs/io.js/blob/v1.x/CHANGELOG.md</changelog>
<bugs-to>https://github.com/iojs/io.js/issues</bugs-to>
</upstream>
<use>
<flag name='bundled-libs'>Use bundled libs instead of system libs</flag>
<flag name='npm'>Enable NPM package manager</flag>
<flag name='snapshot'>Enable snapshot creation for faster startup</flag>
<flag name='bundled-libs'>Use bundled libs instead of system libs</flag>
<flag name='npm'>Enable NPM package manager</flag>
<flag name='snapshot'>Enable snapshot creation for faster startup</flag>
</use>
</pkgmetadata>