diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/Manifest b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/Manifest
new file mode 100644
index 0000000000..ea9d03ce4a
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/Manifest
@@ -0,0 +1,13 @@
+DIST js-1.7.0.tar.gz 1165607 BLAKE2B 61749e10886bbb9e4958a41925fae8dcbd7d943b9bf838878368c30e26ba61f300bc2ec37982653b87fedf76707dda2ffd510282de4bce87d1da11ca42fa108c SHA512 9d9fbd9c1dae969ca19ddb0f977ac56f3e0479ec393b859de252fcdd8b7fc325e80399073540884ed365ce56a3219be34c0db9300d5e50f32969660c90527e51
+DIST js185-1.0.0.tar.gz 6164605 BLAKE2B 76a37f0ceae05d3475853875bd0ce4be6e525e4114816f8f281ea6fc6b60a71060975a0fa1cb843f57ad1e2f842dfb26b24244fa0fd6c20f6ae2ebbe430f70be SHA512 2af7122a7c7007fd7b6668776fe1222515a810b3e43bbf0f76b8f94e1ef406ffd3fb5ccec393021b00274c05b38a77235bc8d6886994c56762fcaf0aa7cf6718
+DIST mozjs-24.2.0.tar.bz2 15624530 BLAKE2B 633f3e42011a8395aa4e60842c2de1cb472692a0d9355c1e2c49e1ef943605cafaea0c836f9044adfceb38d7e04a0941b895474d08097f641bfca4494c5c5fe4 SHA512 49805e256f6fa797505c01b7596d5bb941ed7a2454862c52ed42ad48b5ae4540b777e77ed8da1b98c89f8622ed2c76052187983687008a4ff53594addb328df4
+DIST mozjs-38.3.0sfink2.tar.bz2 27232902 BLAKE2B 42a039a41b7479a32e22f260cb58f098e1a1d4833f801f193bdd8b75403f94567b9ef2ebe85b2a811fe2f9b27cd934afe1054bd4e7d9aae0b8a80acdec8e42a4 SHA512 debad1fbd21e025c567b083677cfd0a2023ec2aff750241f495ac2977034a7299e068cb3b0b2351c97457119cc8aef563f00416092a70a3a269d20947b700206
+DIST mozjs-45.0.2.tar.bz2 97508152 BLAKE2B 89600f7e2a3effe71ad140646110aaf3be91cc5313cf227f1d16e796e249e287cc8dbf2599aa4277f2652a83ec3570f58c1c51ef319632254b9ac5caec46bb9a SHA512 84a3cf12e2603e00bcfe518a1a5000f53b21758c1c6b32a0410e63ab7db8d4452028195b0ba3e56144054b06e90f8e5195b4db94dba711f7c75d11da99c6c61d
+DIST mozjs-52.9.1pre1.tar.bz2 30178574 BLAKE2B 0920432b5140e78297a9bcbccb54268d75a223d5e75e4ff90b3b01aab4f7736b4a4e05c47b3a925ff0a74607a0abad3b6583c75d070ef5142009b20ebaf6e4bf SHA512 187b231b246a5ae09e55c0fef77866b316d75f38f4c2e066d5d4325d8da63433027020c929439cab46af3253ac63ab2f780223a8fd2c6ff535b3409bb6c4aa0f
+DIST mozjs17.0.0.tar.gz 6778934 BLAKE2B a37debf5079fc4c27bb9edd3172c6e7914f6128fac6ffa97b49ac266c477d0916b180fb68ecd0916a52f935959a83d73254b0ba72b4898adc5e3b85927d17d2a SHA512 39b68aeb9f712f146778d8b68ee795709a1372c8ab893a222af4eb34882427d6f5cf877e743d6cb2f1b4348c194d8f3774f00cb775b03515b34b49560b748be4
+DIST spidermonkey-52.0-patches-0.tar.xz 5172 BLAKE2B 8bcf9477de47ef3b882cd3281efa7f77c16ce11fc93f44446a620917adf629fde8290af1dd69f0930a889aacfee3603bf60eb9c1e718a1dfd3e218a1013b6192 SHA512 88ad640fb0efa4972f1b7782bd0abee1751b73914ee51faade93b25c4d8eec64e7693898842a406c49fc2ab43733404efeccb138afb64d2193b9a5eb612578e3
+DIST spidermonkey-slot0-patches-01.tar.xz 10488 BLAKE2B 4a5195ac11d1076046424fc10d1416d097fb230cd8b0b28ac8b65d379e0c0518586ced0f48f833dea52b13fb5d300e02664657ab2479bfcc343bc358d394d5d7 SHA512 6c878ed0b50c052989a8b965fed845e9c672b691f4c4b1f98ee82e81a33880e1e6bf1dac8222d71322553282de602a88272dedebbcf50d27967fc172f0a8054a
+DIST spidermonkey-slot17-patches-01.tar.xz 2748 BLAKE2B a55504d726f925096de7e066a1d323154bc796018644f347bc1d012ea6ee8441cc19f30689e06fd26bab5a5d2e8376e90bf2c1930a588be8b48865f7bbc524ea SHA512 21a90f85d156de3cca9811317507162a458f908bb447924fcfbf49b7bb70496b611ce7df90b90775316b8ceafda56692be3bf856b168b83ed40b8a5c668eed3f
+DIST spidermonkey-slot24-patches-01.tar.xz 3444 BLAKE2B f207577db223d51e315d473f0eefa8a2805fab49acd952fa5796eb4e967c82c76965afcdea1b55ac98c5e94f4321f40c1ea9079d5ebee99fdef950bddee91ab2 SHA512 712250983f726eb2fe7ae243e9ca510b6e5b8fa0f221fe5120c2e2f75334f7e4b10b8ab172869d7333a120529dbc2a513c170533d5ad5af27a2643ce1384bbdb
+DIST spidermonkey-slot38-patches-01.tar.xz 7472 BLAKE2B 7585aa6f5a84d6ae21e41137fca8da093580182f798f63bfcf2e402e3bf58df4cb3f43cef3eb635044508800f6757247fa3a65ca53230243a455925f436a9510 SHA512 953acee985d192c6d0f18f14c70fdda33a7c8f784c6833ca8b75495044b40a8b3f29b281c40dbfcda0c8570c111a3dd1717c2ef0ffd651c1b50d1f2bff1f6d09
+DIST spidermonkey-slot45-patches-01.tar.xz 5092 BLAKE2B 0188a179fc741ab84a93aae1e77f8b765868ca716b8879661bfa678aef918998c9488db3b866a13c79ae28edb43ac0ebb10345b0471b717c4174c61cba9646bc SHA512 d52f038a7b4f7b410b5a1f94a55962adafc5906e7d85f605f3fe45ad49417c2b9d58d853a81b5d2395a2842c9780992d5a2c1a0e67aa77fb09f21aff9aeb0f7a
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/files/moz38-dont-hardcode-libc-soname.patch b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/files/moz38-dont-hardcode-libc-soname.patch
new file mode 100644
index 0000000000..708c749697
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/files/moz38-dont-hardcode-libc-soname.patch
@@ -0,0 +1,15 @@
+--- a/testing/mozbase/mozinfo/mozinfo/mozinfo.py 2018-01-12 12:21:16.764318254 -0500
++++ b/testing/mozbase/mozinfo/mozinfo/mozinfo.py 2018-01-12 12:22:23.392069398 -0500
+@@ -93,10 +93,11 @@
+
+ if info['os'] == 'linux':
+ import ctypes
++ import ctypes.util
+ import errno
+ PR_SET_SECCOMP = 22
+ SECCOMP_MODE_FILTER = 2
+- ctypes.CDLL("libc.so.6", use_errno=True).prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, 0)
++ ctypes.CDLL(ctypes.util.find_library('c'), use_errno=True).prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, 0)
+ info['has_sandbox'] = ctypes.get_errno() == errno.EFAULT
+ else:
+ info['has_sandbox'] = True
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/files/spidermonkey-52-baseconfig.patch b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/files/spidermonkey-52-baseconfig.patch
new file mode 100644
index 0000000000..ee52728fa9
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/files/spidermonkey-52-baseconfig.patch
@@ -0,0 +1,22 @@
+Fix various paths to include MOZ_APP_VERSION
+
+This has been committed upstream but was not included in
+the 52.4.0 sources that spidermonkey was rolled from.
+
+--- a/config/baseconfig.mk 2017-10-03 14:00:45.000000000 -0400
++++ b/config/baseconfig.mk 2017-10-03 16:36:10.857663794 -0400
+@@ -2,10 +2,10 @@
+ # directly in python/mozbuild/mozbuild/base.py for gmake validation.
+ # We thus use INCLUDED_AUTOCONF_MK to enable/disable some parts depending
+ # whether a normal build is happening or whether the check is running.
+-includedir := $(includedir)/$(MOZ_APP_NAME)
+-idldir = $(includedir)/idl/$(MOZ_APP_NAME)
+-installdir = $(libdir)/$(MOZ_APP_NAME)
+-sdkdir = $(libdir)/$(MOZ_APP_NAME)
++includedir := $(includedir)/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
++idldir = $(includedir)/idl/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
++installdir = $(libdir)/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
++sdkdir = $(libdir)/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
+ ifeq (.,$(DEPTH))
+ DIST = dist
+ else
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/files/spidermonkey-perl-defined-array-check.patch b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/files/spidermonkey-perl-defined-array-check.patch
new file mode 100644
index 0000000000..c3996ae82b
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/files/spidermonkey-perl-defined-array-check.patch
@@ -0,0 +1,11 @@
+--- a/js/src/config/milestone.pl 2013-02-11 17:33:22.000000000 -0500
++++ b/js/src/config/milestone.pl 2015-07-15 10:44:31.676153600 -0400
+@@ -55,7 +55,7 @@
+ #
+ my $milestone = Moz::Milestone::getOfficialMilestone($MILESTONE_FILE);
+
+-if (defined(@TEMPLATE_FILE)) {
++if (@TEMPLATE_FILE) {
+ my $TFILE;
+
+ foreach $TFILE (@TEMPLATE_FILE) {
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/metadata.xml b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/metadata.xml
new file mode 100644
index 0000000000..83c60ddc3f
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/metadata.xml
@@ -0,0 +1,18 @@
+
+
+
+
+ mozilla@gentoo.org
+ Gentoo Mozilla Team
+
+
+ Stand-alone JavaScript C++ library
+
+
+
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-1.7.0-r3.ebuild b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-1.7.0-r3.ebuild
new file mode 100644
index 0000000000..5d604b0370
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-1.7.0-r3.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+
+inherit eutils toolchain-funcs multilib flag-o-matic
+
+MY_P="js-${PV}"
+DESCRIPTION="Stand-alone JavaScript C library"
+HOMEPAGE="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+SRC_URI="http://archive.mozilla.org/pub/js/${MY_P}.tar.gz
+ https://dev.gentoo.org/~axs/distfiles/${PN}-slot0-patches-01.tar.xz
+ "
+
+LICENSE="NPL-1.1"
+SLOT="0/js"
+KEYWORDS="alpha amd64 ~arm ppc ppc64 ~sparc x86 ~x86-fbsd"
+IUSE="threadsafe unicode"
+
+S="${WORKDIR}/js/src"
+
+RDEPEND="threadsafe? ( dev-libs/nspr )"
+DEPEND="${RDEPEND}"
+
+src_prepare() {
+ epatch "${WORKDIR}"/sm0/${PN}-1.5-build.patch \
+ "${WORKDIR}"/sm0/${PN}-1.6-header.patch \
+ "${WORKDIR}"/sm0/${P}-threadsafe.diff \
+ "${WORKDIR}"/sm0/${P}-ldflags.patch
+
+ # don't force owner for Prefix
+ sed -i -e '/^INSTALL :=/s/-g 0 -o root//' Makefile.ref || die
+
+ if [[ ${CHOST} == *-freebsd* ]]; then
+ # Don't try to be smart, this does not work in cross-compile anyway
+ ln -s "${S}/config/Linux_All.mk" "${S}/config/$(uname -s)$(uname -r).mk"
+ fi
+}
+
+src_compile() {
+ use unicode && append-flags "-DJS_C_STRINGS_ARE_UTF8"
+ tc-export CC LD AR RANLIB
+ local threadsafe=""
+ use threadsafe && threadsafe="JS_THREADSAFE=1"
+ emake -j1 -f Makefile.ref LIBDIR="$(get_libdir)" ${threadsafe} \
+ XLDFLAGS="$(raw-ldflags)" HOST_LDFLAGS="${LDFLAGS}"
+}
+
+src_install() {
+ emake -f Makefile.ref install DESTDIR="${ED}" LIBDIR="$(get_libdir)"
+ dodoc ../jsd/README
+ dohtml README.html
+}
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-1.8.5-r6.ebuild b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-1.8.5-r6.ebuild
new file mode 100644
index 0000000000..fb6e97c768
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-1.8.5-r6.ebuild
@@ -0,0 +1,152 @@
+# Copyright 1999-2018 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+WANT_AUTOCONF="2.1"
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="threads"
+inherit autotools eutils toolchain-funcs multilib python-any-r1 versionator pax-utils
+
+MY_PN="js"
+TARBALL_PV="$(replace_all_version_separators '' $(get_version_component_range 1-3))"
+MY_P="${MY_PN}-${PV}"
+TARBALL_P="${MY_PN}${TARBALL_PV}-1.0.0"
+DESCRIPTION="Stand-alone JavaScript C library"
+HOMEPAGE="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+SRC_URI="https://archive.mozilla.org/pub/js/${TARBALL_P}.tar.gz
+ https://dev.gentoo.org/~axs/distfiles/${PN}-slot0-patches-01.tar.xz
+ "
+
+LICENSE="NPL-1.1"
+SLOT="0/mozjs185"
+KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh ~sparc x86 ~amd64-fbsd ~x86-fbsd ~x64-macos"
+IUSE="debug minimal static-libs test"
+
+S="${WORKDIR}/${MY_P}"
+BUILDDIR="${S}/js/src"
+
+RDEPEND=">=dev-libs/nspr-4.7.0
+ sys-libs/readline:0=
+ x64-macos? ( dev-libs/jemalloc )"
+DEPEND="${RDEPEND}
+ ${PYTHON_DEPS}
+ app-arch/zip
+ virtual/pkgconfig"
+
+pkg_setup(){
+ if [[ ${MERGE_TYPE} != "binary" ]]; then
+ export LC_ALL="C"
+ fi
+}
+
+src_prepare() {
+ # https://bugzilla.mozilla.org/show_bug.cgi?id=628723#c43
+ epatch "${WORKDIR}"/sm0/${P}-fix-install-symlinks.patch
+ # https://bugzilla.mozilla.org/show_bug.cgi?id=638056#c9
+ epatch "${WORKDIR}"/sm0/${P}-fix-ppc64.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=400727
+ # https://bugs.gentoo.org/show_bug.cgi?id=420471
+ epatch "${WORKDIR}"/sm0/${P}-arm_respect_cflags-3.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=438746
+ epatch "${WORKDIR}"/sm0/${PN}-1.8.7-freebsd-pthreads.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=441928
+ epatch "${WORKDIR}"/sm0/${PN}-1.8.5-perf_event-check.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=439260
+ epatch "${WORKDIR}"/sm0/${P}-symbol-versions.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=441934
+ epatch "${WORKDIR}"/sm0/${PN}-1.8.5-ia64-fix.patch
+ epatch "${WORKDIR}"/sm0/${PN}-1.8.5-ia64-static-strings.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=431560
+ epatch "${WORKDIR}"/sm0/${PN}-1.8.5-isfinite.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=552786
+ epatch "${FILESDIR}"/${PN}-perl-defined-array-check.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=439558
+ epatch "${WORKDIR}"/sm0/${PN}-1.8.7-x32.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=582478
+ epatch "${WORKDIR}"/sm0/${PN}-1.8.5-gcc6.patch
+
+ epatch_user
+
+ cd "${BUILDDIR}" || die
+ eautoconf
+}
+
+src_configure() {
+ cd "${BUILDDIR}" || die
+
+ CC="$(tc-getCC)" CXX="$(tc-getCXX)" \
+ AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" \
+ LD="$(tc-getLD)" \
+ ac_cv_lib_dnet_dnet_ntoa=no \
+ ac_cv_lib_dnet_stub_dnet_ntoa=no \
+ econf \
+ ${myopts} \
+ --enable-jemalloc \
+ --enable-readline \
+ --enable-threadsafe \
+ --with-system-nspr \
+ --disable-optimize \
+ --disable-profile-guided-optimization \
+ $(use_enable debug) \
+ $(use_enable static-libs static) \
+ $(use_enable test tests)
+}
+
+cross_make() {
+ emake \
+ CFLAGS="${BUILD_CFLAGS}" \
+ CXXFLAGS="${BUILD_CXXFLAGS}" \
+ AR="${BUILD_AR}" \
+ CC="${BUILD_CC}" \
+ CXX="${BUILD_CXX}" \
+ RANLIB="${BUILD_RANLIB}" \
+ "$@"
+}
+src_compile() {
+ cd "${BUILDDIR}" || die
+ if tc-is-cross-compiler; then
+ tc-export_build_env BUILD_{AR,CC,CXX,RANLIB}
+ cross_make jscpucfg host_jsoplengen host_jskwgen
+ cross_make -C config nsinstall
+ mv {,native-}jscpucfg || die
+ mv {,native-}host_jskwgen || die
+ mv {,native-}host_jsoplengen || die
+ mv config/{,native-}nsinstall || die
+ sed -i \
+ -e 's@./jscpucfg@./native-jscpucfg@' \
+ -e 's@./host_jskwgen@./native-host_jskwgen@' \
+ -e 's@./host_jsoplengen@./native-host_jsoplengen@' \
+ Makefile || die
+ sed -i -e 's@/nsinstall@/native-nsinstall@' config/config.mk || die
+ rm -f config/host_nsinstall.o \
+ config/host_pathsub.o \
+ host_jskwgen.o \
+ host_jsoplengen.o || die
+ fi
+ emake
+}
+
+src_test() {
+ cd "${BUILDDIR}/jsapi-tests" || die
+ # for bug 415791
+ pax-mark mr jsapi-tests
+ emake check
+}
+
+src_install() {
+ cd "${BUILDDIR}" || die
+ emake DESTDIR="${D}" install
+ # bug 437520 , exclude js shell for small systems
+ if ! use minimal ; then
+ dobin shell/js
+ pax-mark m "${ED}/usr/bin/js"
+ fi
+ dodoc ../../README
+ dohtml README.html
+
+ if ! use static-libs; then
+ # We can't actually disable building of static libraries
+ # They're used by the tests and in a few other places
+ find "${D}" -iname '*.a' -delete || die
+ fi
+}
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-17.0.0-r4.ebuild b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-17.0.0-r4.ebuild
new file mode 100644
index 0000000000..fe180ba3be
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-17.0.0-r4.ebuild
@@ -0,0 +1,137 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+WANT_AUTOCONF="2.1"
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="threads"
+inherit eutils toolchain-funcs multilib python-any-r1 versionator pax-utils
+
+MY_PN="mozjs"
+MY_P="${MY_PN}${PV}"
+DESCRIPTION="Stand-alone JavaScript C library"
+HOMEPAGE="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+SRC_URI="http://archive.mozilla.org/pub/js/${MY_PN}${PV}.tar.gz
+ https://dev.gentoo.org/~axs/distfiles/${PN}-slot17-patches-01.tar.xz"
+
+LICENSE="NPL-1.1"
+SLOT="17"
+# "MIPS, MacroAssembler is not supported" wrt #491294 for -mips
+KEYWORDS="alpha amd64 arm -hppa ia64 -mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd"
+IUSE="debug jit minimal static-libs test"
+
+REQUIRED_USE="debug? ( jit )"
+RESTRICT="ia64? ( test )"
+
+S="${WORKDIR}/${MY_P}"
+BUILDDIR="${S}/js/src"
+
+RDEPEND=">=dev-libs/nspr-4.9.4
+ virtual/libffi
+ sys-libs/readline:0=
+ >=sys-libs/zlib-1.1.4"
+DEPEND="${RDEPEND}
+ ${PYTHON_DEPS}
+ app-arch/zip
+ virtual/pkgconfig"
+
+pkg_setup(){
+ if [[ ${MERGE_TYPE} != "binary" ]]; then
+ python-any-r1_pkg_setup
+ export LC_ALL="C"
+ fi
+}
+
+src_prepare() {
+ epatch "${WORKDIR}"/sm17/${PN}-${SLOT}-js-config-shebang.patch
+ epatch "${WORKDIR}"/sm17/${PN}-${SLOT}-ia64-mmap.patch
+ epatch "${WORKDIR}"/sm17/${PN}-17.0.0-fix-file-permissions.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=552786
+ epatch "${FILESDIR}"/${PN}-perl-defined-array-check.patch
+
+ # Remove obsolete jsuword bug #506160
+ sed -i -e '/jsuword/d' "${BUILDDIR}"/jsval.h ||die "sed failed"
+ epatch_user
+
+ if [[ ${CHOST} == *-freebsd* ]]; then
+ # Don't try to be smart, this does not work in cross-compile anyway
+ ln -sfn "${BUILDDIR}/config/Linux_All.mk" "${S}/config/$(uname -s)$(uname -r).mk" || die
+ fi
+}
+
+src_configure() {
+ cd "${BUILDDIR}" || die
+
+ CC="$(tc-getCC)" CXX="$(tc-getCXX)" \
+ AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" \
+ LD="$(tc-getLD)" \
+ econf \
+ ${myopts} \
+ --enable-jemalloc \
+ --enable-readline \
+ --enable-threadsafe \
+ --with-system-nspr \
+ --enable-system-ffi \
+ --enable-jemalloc \
+ $(use_enable debug) \
+ $(use_enable jit tracejit) \
+ $(use_enable jit methodjit) \
+ $(use_enable static-libs static) \
+ $(use_enable test tests)
+}
+
+cross_make() {
+ emake \
+ CFLAGS="${BUILD_CFLAGS}" \
+ CXXFLAGS="${BUILD_CXXFLAGS}" \
+ AR="${BUILD_AR}" \
+ CC="${BUILD_CC}" \
+ CXX="${BUILD_CXX}" \
+ RANLIB="${BUILD_RANLIB}" \
+ "$@"
+}
+src_compile() {
+ cd "${BUILDDIR}" || die
+ if tc-is-cross-compiler; then
+ tc-export_build_env BUILD_{AR,CC,CXX,RANLIB}
+ cross_make host_jsoplengen host_jskwgen
+ cross_make -C config nsinstall
+ mv {,native-}host_jskwgen || die
+ mv {,native-}host_jsoplengen || die
+ mv config/{,native-}nsinstall || die
+ sed -i \
+ -e 's@./host_jskwgen@./native-host_jskwgen@' \
+ -e 's@./host_jsoplengen@./native-host_jsoplengen@' \
+ Makefile || die
+ sed -i -e 's@/nsinstall@/native-nsinstall@' config/config.mk || die
+ rm -f config/host_nsinstall.o \
+ config/host_pathsub.o \
+ host_jskwgen.o \
+ host_jsoplengen.o || die
+ fi
+ emake
+}
+
+src_test() {
+ cd "${BUILDDIR}/jsapi-tests" || die
+ emake check
+}
+
+src_install() {
+ cd "${BUILDDIR}" || die
+ emake DESTDIR="${D}" install
+
+ if ! use minimal; then
+ if use jit; then
+ pax-mark m "${ED}/usr/bin/js${SLOT}"
+ fi
+ else
+ rm -f "${ED}/usr/bin/js${SLOT}"
+ fi
+
+ if ! use static-libs; then
+ # We can't actually disable building of static libraries
+ # They're used by the tests and in a few other places
+ find "${D}" -iname '*.a' -delete || die
+ fi
+}
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-17.0.0-r5.ebuild b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-17.0.0-r5.ebuild
new file mode 100644
index 0000000000..533fbc1f02
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-17.0.0-r5.ebuild
@@ -0,0 +1,141 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="6"
+WANT_AUTOCONF="2.1"
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="threads"
+inherit toolchain-funcs multilib python-any-r1 versionator pax-utils
+
+MY_PN="mozjs"
+MY_P="${MY_PN}${PV}"
+DESCRIPTION="Stand-alone JavaScript C library"
+HOMEPAGE="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+SRC_URI="http://archive.mozilla.org/pub/js/${MY_PN}${PV}.tar.gz
+ https://dev.gentoo.org/~axs/distfiles/${PN}-slot17-patches-01.tar.xz"
+
+LICENSE="NPL-1.1"
+SLOT="17"
+# "MIPS, MacroAssembler is not supported" wrt #491294 for -mips
+KEYWORDS="alpha amd64 arm -hppa ia64 -mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd"
+IUSE="debug jit minimal static-libs test"
+
+REQUIRED_USE="debug? ( jit )"
+RESTRICT="ia64? ( test )"
+
+S="${WORKDIR}/${MY_P}"
+BUILDDIR="${S}/js/src"
+
+RDEPEND=">=dev-libs/nspr-4.9.4
+ virtual/libffi
+ sys-libs/readline:0=
+ >=sys-libs/zlib-1.1.4"
+DEPEND="${RDEPEND}
+ ${PYTHON_DEPS}
+ app-arch/zip
+ virtual/pkgconfig"
+
+pkg_setup(){
+ if [[ ${MERGE_TYPE} != "binary" ]]; then
+ python-any-r1_pkg_setup
+ export LC_ALL="C"
+ fi
+}
+
+PATCHES=(
+ "${WORKDIR}"/sm17/${PN}-${SLOT}-js-config-shebang.patch
+ "${WORKDIR}"/sm17/${PN}-${SLOT}-ia64-mmap.patch
+ "${WORKDIR}"/sm17/${PN}-17.0.0-fix-file-permissions.patch
+ "${WORKDIR}"/sm17/${PN}-17-clang.patch
+ "${FILESDIR}"/${PN}-perl-defined-array-check.patch
+ "${WORKDIR}"/sm17/${PN}-17-fix_pointer_dereference.patch
+)
+
+src_prepare() {
+ default
+
+ # Remove obsolete jsuword bug #506160
+ sed -i -e '/jsuword/d' "${BUILDDIR}"/jsval.h || die "sed failed"
+
+ if [[ ${CHOST} == *-freebsd* ]]; then
+ # Don't try to be smart, this does not work in cross-compile anyway
+ ln -sfn "${BUILDDIR}/config/Linux_All.mk" "${S}/config/$(uname -s)$(uname -r).mk" || die
+ fi
+}
+
+src_configure() {
+ cd "${BUILDDIR}" || die
+
+ CC="$(tc-getCC)" CXX="$(tc-getCXX)" \
+ AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" \
+ LD="$(tc-getLD)" \
+ econf \
+ ${myopts} \
+ --enable-jemalloc \
+ --enable-readline \
+ --enable-threadsafe \
+ --with-system-nspr \
+ --enable-system-ffi \
+ --enable-jemalloc \
+ $(use_enable debug) \
+ $(use_enable jit tracejit) \
+ $(use_enable jit methodjit) \
+ $(use_enable static-libs static) \
+ $(use_enable test tests)
+}
+
+cross_make() {
+ emake \
+ CFLAGS="${BUILD_CFLAGS}" \
+ CXXFLAGS="${BUILD_CXXFLAGS}" \
+ AR="${BUILD_AR}" \
+ CC="${BUILD_CC}" \
+ CXX="${BUILD_CXX}" \
+ RANLIB="${BUILD_RANLIB}" \
+ "$@"
+}
+src_compile() {
+ cd "${BUILDDIR}" || die
+ if tc-is-cross-compiler; then
+ tc-export_build_env BUILD_{AR,CC,CXX,RANLIB}
+ cross_make host_jsoplengen host_jskwgen
+ cross_make -C config nsinstall
+ mv {,native-}host_jskwgen || die
+ mv {,native-}host_jsoplengen || die
+ mv config/{,native-}nsinstall || die
+ sed -i \
+ -e 's@./host_jskwgen@./native-host_jskwgen@' \
+ -e 's@./host_jsoplengen@./native-host_jsoplengen@' \
+ Makefile || die
+ sed -i -e 's@/nsinstall@/native-nsinstall@' config/config.mk || die
+ rm -f config/host_nsinstall.o \
+ config/host_pathsub.o \
+ host_jskwgen.o \
+ host_jsoplengen.o || die
+ fi
+ emake
+}
+
+src_test() {
+ cd "${BUILDDIR}/jsapi-tests" || die
+ emake check
+}
+
+src_install() {
+ cd "${BUILDDIR}" || die
+ default
+
+ if ! use minimal; then
+ if use jit; then
+ pax-mark m "${ED}/usr/bin/js${SLOT}" || die
+ fi
+ else
+ rm -f "${ED}/usr/bin/js${SLOT}" || die
+ fi
+
+ if ! use static-libs; then
+ # We can't actually disable building of static libraries
+ # They're used by the tests and in a few other places
+ find "${D}" -iname '*.a' -delete || die
+ fi
+}
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-24.2.0-r3.ebuild b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-24.2.0-r3.ebuild
new file mode 100644
index 0000000000..c42b72131c
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-24.2.0-r3.ebuild
@@ -0,0 +1,154 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+WANT_AUTOCONF="2.1"
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="threads"
+inherit autotools eutils toolchain-funcs multilib python-any-r1 versionator pax-utils
+
+MY_PN="mozjs"
+MY_P="${MY_PN}-${PV/_/.}"
+DESCRIPTION="Stand-alone JavaScript C library"
+HOMEPAGE="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+SRC_URI="https://archive.mozilla.org/pub/js/${MY_P}.tar.bz2
+ https://dev.gentoo.org/~axs/distfiles/${PN}-slot24-patches-01.tar.xz"
+
+LICENSE="NPL-1.1"
+SLOT="24"
+KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd"
+IUSE="debug icu jit minimal static-libs +system-icu test"
+
+RESTRICT="ia64? ( test )"
+
+S="${WORKDIR}/${MY_P%.rc*}"
+BUILDDIR="${S}/js/src"
+
+RDEPEND=">=dev-libs/nspr-4.9.4
+ virtual/libffi
+ sys-libs/readline:0=
+ >=sys-libs/zlib-1.1.4
+ system-icu? ( >=dev-libs/icu-1.51:= )"
+DEPEND="${RDEPEND}
+ ${PYTHON_DEPS}
+ app-arch/zip
+ virtual/pkgconfig"
+
+pkg_setup(){
+ if [[ ${MERGE_TYPE} != "binary" ]]; then
+ python-any-r1_pkg_setup
+ export LC_ALL="C"
+ fi
+}
+
+src_prepare() {
+ epatch "${WORKDIR}"/sm24/${PN}-${SLOT}-system-icu.patch
+ epatch "${WORKDIR}"/sm24/${PN}-24.2.0-fix-file-permissions.patch
+ epatch "${WORKDIR}"/sm24/${PN}-${SLOT}-upward-growing-stack.patch
+ # https://bugs.gentoo.org/show_bug.cgi?id=552786
+ epatch "${FILESDIR}"/${PN}-perl-defined-array-check.patch
+ epatch_user
+
+ if [[ ${CHOST} == *-freebsd* ]]; then
+ # Don't try to be smart, this does not work in cross-compile anyway
+ ln -sfn "${BUILDDIR}/config/Linux_All.mk" "${S}/config/$(uname -s)$(uname -r).mk" || die
+ fi
+
+ cd "${BUILDDIR}" || die
+ eautoconf
+}
+
+src_configure() {
+ export SHELL=/bin/sh
+ cd "${BUILDDIR}" || die
+
+ local myopts=""
+ if use icu; then # make sure system-icu flag only affects icu-enabled build
+ myopts+="$(use_with system-icu)"
+ else
+ myopts+="--without-system-icu"
+ fi
+
+ CC="$(tc-getCC)" CXX="$(tc-getCXX)" \
+ AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" \
+ LD="$(tc-getLD)" \
+ econf \
+ ${myopts} \
+ --enable-jemalloc \
+ --enable-readline \
+ --enable-threadsafe \
+ --with-system-nspr \
+ --enable-system-ffi \
+ --disable-optimize \
+ $(use_enable icu intl-api) \
+ $(use_enable debug) \
+ $(use_enable jit yarr-jit) \
+ $(use_enable jit ion) \
+ $(use_enable static-libs static) \
+ $(use_enable test tests)
+}
+
+cross_make() {
+ emake \
+ CFLAGS="${BUILD_CFLAGS}" \
+ CXXFLAGS="${BUILD_CXXFLAGS}" \
+ AR="${BUILD_AR}" \
+ CC="${BUILD_CC}" \
+ CXX="${BUILD_CXX}" \
+ RANLIB="${BUILD_RANLIB}" \
+ "$@"
+}
+src_compile() {
+ cd "${BUILDDIR}" || die
+ if tc-is-cross-compiler; then
+ tc-export_build_env BUILD_{AR,CC,CXX,RANLIB}
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS="" \
+ host_jsoplengen host_jskwgen
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" HOST_OPTIMIZE_FLAGS="" \
+ -C config nsinstall
+ mv {,native-}host_jskwgen || die
+ mv {,native-}host_jsoplengen || die
+ mv config/{,native-}nsinstall || die
+ sed -i \
+ -e 's@./host_jskwgen@./native-host_jskwgen@' \
+ -e 's@./host_jsoplengen@./native-host_jsoplengen@' \
+ Makefile || die
+ sed -i -e 's@/nsinstall@/native-nsinstall@' config/config.mk || die
+ rm -f config/host_nsinstall.o \
+ config/host_pathsub.o \
+ host_jskwgen.o \
+ host_jsoplengen.o || die
+ fi
+ emake \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS=""
+}
+
+src_test() {
+ cd "${BUILDDIR}/jsapi-tests" || die
+ emake check
+}
+
+src_install() {
+ cd "${BUILDDIR}" || die
+ emake DESTDIR="${D}" install
+
+ if ! use minimal; then
+ if use jit; then
+ pax-mark m "${ED}/usr/bin/js${SLOT}"
+ fi
+ else
+ rm -f "${ED}/usr/bin/js${SLOT}"
+ fi
+
+ if ! use static-libs; then
+ # We can't actually disable building of static libraries
+ # They're used by the tests and in a few other places
+ find "${D}" -iname '*.a' -delete || die
+ fi
+}
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-24.2.0-r4.ebuild b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-24.2.0-r4.ebuild
new file mode 100644
index 0000000000..6613f6e1b6
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-24.2.0-r4.ebuild
@@ -0,0 +1,157 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+WANT_AUTOCONF="2.1"
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="threads"
+inherit autotools toolchain-funcs multilib python-any-r1 versionator pax-utils
+
+MY_PN="mozjs"
+MY_P="${MY_PN}-${PV/_/.}"
+DESCRIPTION="Stand-alone JavaScript C library"
+HOMEPAGE="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+SRC_URI="https://archive.mozilla.org/pub/js/${MY_P}.tar.bz2
+ https://dev.gentoo.org/~axs/distfiles/${PN}-slot24-patches-01.tar.xz"
+
+LICENSE="NPL-1.1"
+SLOT="24"
+KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd"
+IUSE="debug icu jit minimal static-libs +system-icu test"
+
+RESTRICT="ia64? ( test )"
+
+S="${WORKDIR}/${MY_P%.rc*}"
+BUILDDIR="${S}/js/src"
+
+RDEPEND=">=dev-libs/nspr-4.9.4
+ virtual/libffi
+ sys-libs/readline:0=
+ >=sys-libs/zlib-1.1.4
+ system-icu? ( >=dev-libs/icu-1.51:= )"
+DEPEND="${RDEPEND}
+ ${PYTHON_DEPS}
+ app-arch/zip
+ virtual/pkgconfig"
+
+PATCHES=(
+ "${WORKDIR}"/sm24/${PN}-${SLOT}-system-icu.patch
+ "${WORKDIR}"/sm24/${PN}-24.2.0-fix-file-permissions.patch
+ "${WORKDIR}"/sm24/${PN}-${SLOT}-upward-growing-stack.patch
+ "${FILESDIR}"/${PN}-perl-defined-array-check.patch
+ "${WORKDIR}"/sm24/${PN}-17-fix_pointer_dereference.patch
+)
+
+pkg_setup(){
+ if [[ ${MERGE_TYPE} != "binary" ]]; then
+ python-any-r1_pkg_setup
+ export LC_ALL="C"
+ fi
+}
+
+src_prepare() {
+ default
+
+ if [[ ${CHOST} == *-freebsd* ]]; then
+ # Don't try to be smart, this does not work in cross-compile anyway
+ ln -sfn "${BUILDDIR}/config/Linux_All.mk" "${S}/config/$(uname -s)$(uname -r).mk" || die
+ fi
+
+ cd "${BUILDDIR}" || die
+ eautoconf
+}
+
+src_configure() {
+ export SHELL=/bin/sh
+ cd "${BUILDDIR}" || die
+
+ local myopts=""
+ if use icu; then # make sure system-icu flag only affects icu-enabled build
+ myopts+="$(use_with system-icu)"
+ else
+ myopts+="--without-system-icu"
+ fi
+
+ CC="$(tc-getCC)" CXX="$(tc-getCXX)" \
+ AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" \
+ LD="$(tc-getLD)" \
+ econf \
+ ${myopts} \
+ --enable-jemalloc \
+ --enable-readline \
+ --enable-threadsafe \
+ --with-system-nspr \
+ --enable-system-ffi \
+ --disable-optimize \
+ $(use_enable icu intl-api) \
+ $(use_enable debug) \
+ $(use_enable jit yarr-jit) \
+ $(use_enable jit ion) \
+ $(use_enable static-libs static) \
+ $(use_enable test tests)
+}
+
+cross_make() {
+ emake \
+ CFLAGS="${BUILD_CFLAGS}" \
+ CXXFLAGS="${BUILD_CXXFLAGS}" \
+ AR="${BUILD_AR}" \
+ CC="${BUILD_CC}" \
+ CXX="${BUILD_CXX}" \
+ RANLIB="${BUILD_RANLIB}" \
+ "$@"
+}
+src_compile() {
+ cd "${BUILDDIR}" || die
+ if tc-is-cross-compiler; then
+ tc-export_build_env BUILD_{AR,CC,CXX,RANLIB}
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS="" \
+ host_jsoplengen host_jskwgen
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" HOST_OPTIMIZE_FLAGS="" \
+ -C config nsinstall
+ mv {,native-}host_jskwgen || die
+ mv {,native-}host_jsoplengen || die
+ mv config/{,native-}nsinstall || die
+ sed -i \
+ -e 's@./host_jskwgen@./native-host_jskwgen@' \
+ -e 's@./host_jsoplengen@./native-host_jsoplengen@' \
+ Makefile || die
+ sed -i -e 's@/nsinstall@/native-nsinstall@' config/config.mk || die
+ rm -f config/host_nsinstall.o \
+ config/host_pathsub.o \
+ host_jskwgen.o \
+ host_jsoplengen.o || die
+ fi
+ emake \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS=""
+}
+
+src_test() {
+ cd "${BUILDDIR}/jsapi-tests" || die
+ emake check
+}
+
+src_install() {
+ cd "${BUILDDIR}" || die
+ default
+
+ if ! use minimal; then
+ if use jit; then
+ pax-mark m "${ED}/usr/bin/js${SLOT}" || die
+ fi
+ else
+ rm -f "${ED}/usr/bin/js${SLOT}" || die
+ fi
+
+ if ! use static-libs; then
+ # We can't actually disable building of static libraries
+ # They're used by the tests and in a few other places
+ find "${D}" -iname '*.a' -delete || die
+ fi
+}
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-38.3.0.ebuild b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-38.3.0.ebuild
new file mode 100644
index 0000000000..dcbf4ae252
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-38.3.0.ebuild
@@ -0,0 +1,147 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+WANT_AUTOCONF="2.1"
+inherit autotools toolchain-funcs pax-utils mozcoreconf-v4
+
+MY_PN="mozjs"
+MY_P="${MY_PN}-${PV/_/.}sfink2"
+DESCRIPTION="Stand-alone JavaScript C library"
+HOMEPAGE="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+SRC_URI="https://archive.mozilla.org/pub/${PN}/releases/${PV}/${MY_P}.tar.bz2
+ https://dev.gentoo.org/~axs/distfiles/${PN}-slot38-patches-01.tar.xz"
+
+LICENSE="NPL-1.1"
+SLOT="38"
+KEYWORDS="alpha amd64 ~arm ~hppa ia64 ~mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd"
+IUSE="debug +jit minimal static-libs +system-icu test"
+
+RESTRICT="ia64? ( test )"
+
+#S="${WORKDIR}/${MY_P%.rc*}"
+S="${WORKDIR}/${MY_P}"
+BUILDDIR="${S}/js/src"
+
+RDEPEND=">=dev-libs/nspr-4.10.10
+ virtual/libffi
+ sys-libs/readline:0=
+ >=sys-libs/zlib-1.2.3
+ system-icu? ( >=dev-libs/icu-51.1:= )"
+DEPEND="${RDEPEND}"
+
+pkg_setup(){
+ if [[ ${MERGE_TYPE} != "binary" ]]; then
+ moz_pkgsetup
+ fi
+}
+
+src_prepare() {
+ eapply "${WORKDIR}"/sm38/${PN}-38-jsapi-tests.patch \
+ "${WORKDIR}"/sm38/mozjs38-1269317.patch \
+ "${WORKDIR}"/sm38/mozjs38-fix-tracelogger.patch \
+ "${WORKDIR}"/sm38/mozjs38-copy-headers.patch \
+ "${WORKDIR}"/sm38/mozjs38-pkg-config-version.patch \
+ "${WORKDIR}"/sm38/mozilla_configure_regexp_esr38.patch \
+ "${FILESDIR}"/moz38-dont-hardcode-libc-soname.patch
+
+ eapply_user
+
+ if [[ ${CHOST} == *-freebsd* ]]; then
+ # Don't try to be smart, this does not work in cross-compile anyway
+ ln -sfn "${BUILDDIR}/config/Linux_All.mk" "${S}/config/$(uname -s)$(uname -r).mk" || die
+ fi
+
+ cd "${BUILDDIR}" || die
+ eautoconf
+}
+
+src_configure() {
+ export SHELL="${SHELL:-${EPREFIX%/}/bin/bash}"
+
+ cd "${BUILDDIR}" || die
+
+ econf \
+ --enable-jemalloc \
+ --enable-readline \
+ --enable-threadsafe \
+ --with-system-nspr \
+ --enable-system-ffi \
+ --disable-optimize \
+ --with-intl-api \
+ $(use_with system-icu) \
+ $(use_enable debug) \
+ $(use_enable jit yarr-jit) \
+ $(use_enable jit ion) \
+ $(use_enable static-libs static) \
+ $(use_enable test tests)
+}
+
+cross_make() {
+ emake \
+ CFLAGS="${BUILD_CFLAGS}" \
+ CXXFLAGS="${BUILD_CXXFLAGS}" \
+ AR="${BUILD_AR}" \
+ CC="${BUILD_CC}" \
+ CXX="${BUILD_CXX}" \
+ RANLIB="${BUILD_RANLIB}" \
+ "$@"
+}
+src_compile() {
+ cd "${BUILDDIR}" || die
+ if tc-is-cross-compiler; then
+ tc-export_build_env BUILD_{AR,CC,CXX,RANLIB}
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS="" \
+ host_jsoplengen host_jskwgen
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" HOST_OPTIMIZE_FLAGS="" \
+ -C config nsinstall
+ mv {,native-}host_jskwgen || die
+ mv {,native-}host_jsoplengen || die
+ mv config/{,native-}nsinstall || die
+ sed -i \
+ -e 's@./host_jskwgen@./native-host_jskwgen@' \
+ -e 's@./host_jsoplengen@./native-host_jsoplengen@' \
+ Makefile || die
+ sed -i -e 's@/nsinstall@/native-nsinstall@' config/config.mk || die
+ rm -f config/host_nsinstall.o \
+ config/host_pathsub.o \
+ host_jskwgen.o \
+ host_jsoplengen.o || die
+ fi
+
+ MOZ_MAKE_FLAGS="${MAKEOPTS}"
+ emake \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS=""
+}
+
+src_test() {
+ cd "${BUILDDIR}/js/src/jsapi-tests" || die
+ ./jsapi-tests || die
+}
+
+src_install() {
+ cd "${BUILDDIR}" || die
+ emake DESTDIR="${D}" install
+
+ mv "${ED}"usr/bin/js-config{,${SLOT}} || die
+ mv "${ED}"usr/bin/js{,${SLOT}} || die
+ if ! use minimal; then
+ if use jit; then
+ pax-mark m "${ED}"usr/bin/js${SLOT}
+ fi
+ else
+ rm -f "${ED}"/usr/bin/js${SLOT}
+ fi
+
+ if ! use static-libs; then
+ # We can't actually disable building of static libraries
+ # They're used by the tests and in a few other places
+ find "${D}" -iname '*.a' -o -iname '*.ajs' -delete || die
+ fi
+}
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-45.0.2.ebuild b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-45.0.2.ebuild
new file mode 100644
index 0000000000..065995e59d
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-45.0.2.ebuild
@@ -0,0 +1,148 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+WANT_AUTOCONF="2.1"
+inherit autotools toolchain-funcs pax-utils mozcoreconf-v4
+
+MY_PN="mozjs"
+MY_P="${MY_PN}-${PV/_/.}"
+DESCRIPTION="Stand-alone JavaScript C library"
+HOMEPAGE="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+SRC_URI="https://archive.mozilla.org/pub/${PN}/releases/${PV}/${MY_P}.tar.bz2
+ https://dev.gentoo.org/~axs/distfiles/${PN}-slot45-patches-01.tar.xz"
+
+LICENSE="NPL-1.1"
+SLOT="45"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
+IUSE="debug +jit minimal static-libs +system-icu test"
+
+RESTRICT="ia64? ( test )"
+
+S="${WORKDIR}/${MY_P%.rc*}"
+BUILDDIR="${S}/js/src"
+
+RDEPEND=">=dev-libs/nspr-4.10.10
+ virtual/libffi
+ sys-libs/readline:0=
+ >=sys-libs/zlib-1.2.3
+ system-icu? ( >=dev-libs/icu-51.1:= )"
+DEPEND="${RDEPEND}"
+
+pkg_setup(){
+ if [[ ${MERGE_TYPE} != "binary" ]]; then
+ moz_pkgsetup
+ fi
+}
+
+src_prepare() {
+ eapply "${WORKDIR}"/sm45/${PN}-38-jsapi-tests.patch \
+ "${WORKDIR}"/sm45/mozjs45-1266366.patch \
+ "${WORKDIR}"/sm45/mozjs38-pkg-config-version.patch \
+ "${WORKDIR}"/sm45/mozilla_configure_regexp_esr.patch \
+ "${WORKDIR}"/sm45/${PN}-${SLOT}-dont-symlink-non-objfiles.patch \
+ "${FILESDIR}"/moz38-dont-hardcode-libc-soname.patch
+
+ # apply relevant (modified) patches from gentoo's firefox-45 patchset
+ eapply "${WORKDIR}"/sm45/ff45
+
+ eapply_user
+
+ if [[ ${CHOST} == *-freebsd* ]]; then
+ # Don't try to be smart, this does not work in cross-compile anyway
+ ln -sfn "${BUILDDIR}/config/Linux_All.mk" "${S}/config/$(uname -s)$(uname -r).mk" || die
+ fi
+
+ cd "${BUILDDIR}" || die
+ eautoconf
+}
+
+src_configure() {
+ export SHELL="${SHELL:-${EPREFIX%/}/bin/bash}"
+ cd "${BUILDDIR}" || die
+
+ econf \
+ --enable-jemalloc \
+ --enable-readline \
+ --enable-threadsafe \
+ --with-system-nspr \
+ --enable-system-ffi \
+ --disable-optimize \
+ --with-intl-api \
+ $(use_with system-icu) \
+ $(use_enable debug) \
+ $(use_enable jit yarr-jit) \
+ $(use_enable jit ion) \
+ $(use_enable static-libs static) \
+ $(use_enable test tests)
+}
+
+cross_make() {
+ emake \
+ CFLAGS="${BUILD_CFLAGS}" \
+ CXXFLAGS="${BUILD_CXXFLAGS}" \
+ AR="${BUILD_AR}" \
+ CC="${BUILD_CC}" \
+ CXX="${BUILD_CXX}" \
+ RANLIB="${BUILD_RANLIB}" \
+ "$@"
+}
+src_compile() {
+ cd "${BUILDDIR}" || die
+ if tc-is-cross-compiler; then
+ tc-export_build_env BUILD_{AR,CC,CXX,RANLIB}
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS="" \
+ host_jsoplengen host_jskwgen
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" HOST_OPTIMIZE_FLAGS="" \
+ -C config nsinstall
+ mv {,native-}host_jskwgen || die
+ mv {,native-}host_jsoplengen || die
+ mv config/{,native-}nsinstall || die
+ sed -i \
+ -e 's@./host_jskwgen@./native-host_jskwgen@' \
+ -e 's@./host_jsoplengen@./native-host_jsoplengen@' \
+ Makefile || die
+ sed -i -e 's@/nsinstall@/native-nsinstall@' config/config.mk || die
+ rm -f config/host_nsinstall.o \
+ config/host_pathsub.o \
+ host_jskwgen.o \
+ host_jsoplengen.o || die
+ fi
+
+ MOZ_MAKE_FLAGS="${MAKEOPTS}" \
+ emake \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS=""
+}
+
+src_test() {
+ cd "${BUILDDIR}/js/src/jsapi-tests" || die
+ ./jsapi-tests || die
+}
+
+src_install() {
+ cd "${BUILDDIR}" || die
+ emake DESTDIR="${D}" install
+
+ # re-slot due to upstream stripping out most of the slotting
+ mv "${ED}"usr/bin/js-config{,${SLOT}} || die
+ mv "${ED}"usr/bin/js{,${SLOT}} || die
+ if ! use minimal; then
+ if use jit; then
+ pax-mark m "${ED}"usr/bin/js${SLOT}
+ fi
+ else
+ rm -f "${ED}"usr/bin/js${SLOT}
+ fi
+
+ if ! use static-libs; then
+ # We can't actually disable building of static libraries
+ # They're used by the tests and in a few other places
+ find "${D}" -iname '*.a' -o -iname '*.ajs' -delete || die
+ fi
+}
diff --git a/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-52.9.1_pre1.ebuild b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-52.9.1_pre1.ebuild
new file mode 100644
index 0000000000..a0bc863ec2
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/dev-lang/spidermonkey/spidermonkey-52.9.1_pre1.ebuild
@@ -0,0 +1,147 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+WANT_AUTOCONF="2.1"
+inherit autotools toolchain-funcs pax-utils mozcoreconf-v5
+
+MY_PN="mozjs"
+MY_P="${MY_PN}-${PV/_rc/.rc}"
+MY_P="${MY_P/_pre/pre}"
+DESCRIPTION="Stand-alone JavaScript C++ library"
+HOMEPAGE="https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+#SRC_URI="https://people.mozilla.org/~sfink/${MY_P}.tar.bz2"
+SRC_URI="http://ftp.mozilla.org/pub/spidermonkey/prereleases/52/pre1/mozjs-52.9.1pre1.tar.bz2 -> ${MY_P}.tar.bz2
+ https://dev.gentoo.org/~axs/distfiles/${PN}-52.0-patches-0.tar.xz"
+
+LICENSE="NPL-1.1"
+SLOT="52"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
+IUSE="debug minimal +system-icu test"
+
+RESTRICT="ia64? ( test )"
+
+S="${WORKDIR}/${MY_P%.rc*}"
+BUILDDIR="${S}/jsobj"
+
+RDEPEND=">=dev-libs/nspr-4.13.1
+ virtual/libffi
+ sys-libs/readline:0=
+ >=sys-libs/zlib-1.2.3
+ system-icu? ( >=dev-libs/icu-58.1:= )"
+DEPEND="${RDEPEND}"
+
+pkg_setup(){
+ [[ ${MERGE_TYPE} == "binary" ]] || \
+ moz_pkgsetup
+}
+
+src_prepare() {
+ # remove patches integrated by upstream
+ rm -f "${WORKDIR}"/${PN}/0002-build-Add-major-version-to-make-parallel-installable.patch \
+ "${WORKDIR}"/${PN}/0005-headers-Fix-symbols-visibility.patch \
+ "${WORKDIR}"/${PN}/0007-build-Remove-unnecessary-NSPR-dependency.patch \
+ "${WORKDIR}"/${PN}/0008-tests-Skip-on-all-64-bit-archs.patch \
+ || die
+
+ eapply "${WORKDIR}/${PN}"
+ eapply "${FILESDIR}"/moz38-dont-hardcode-libc-soname.patch
+ #eapply "${FILESDIR}"/${PN}-52-baseconfig.patch
+
+ eapply_user
+
+ if [[ ${CHOST} == *-freebsd* ]]; then
+ # Don't try to be smart, this does not work in cross-compile anyway
+ ln -sfn "${BUILDDIR}/config/Linux_All.mk" "${S}/config/$(uname -s)$(uname -r).mk" || die
+ fi
+
+ cd "${S}"/js/src || die
+ eautoconf old-configure.in
+ eautoconf
+
+ # there is a default config.cache that messes everything up
+ rm -f "${S}"/js/src/config.cache || die
+
+ mkdir -p "${BUILDDIR}" || die
+}
+
+src_configure() {
+ cd "${BUILDDIR}" || die
+
+ ECONF_SOURCE="${S}/js/src" \
+ econf \
+ --enable-jemalloc \
+ --enable-readline \
+ --with-system-nspr \
+ --disable-optimize \
+ --with-intl-api \
+ $(use_with system-icu) \
+ $(use_enable debug) \
+ $(use_enable test tests) \
+ XARGS="/usr/bin/xargs" \
+ SHELL="${SHELL:-${EPREFIX}/bin/bash}" \
+ CC="${CC}" CXX="${CXX}" LD="${LD}" AR="${AR}" RANLIB="${RANLIB}"
+}
+
+cross_make() {
+ emake \
+ CFLAGS="${BUILD_CFLAGS}" \
+ CXXFLAGS="${BUILD_CXXFLAGS}" \
+ AR="${BUILD_AR}" \
+ CC="${BUILD_CC}" \
+ CXX="${BUILD_CXX}" \
+ RANLIB="${BUILD_RANLIB}" \
+ "$@"
+}
+src_compile() {
+ cd "${BUILDDIR}" || die
+ if tc-is-cross-compiler; then
+ tc-export_build_env BUILD_{AR,CC,CXX,RANLIB}
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS="" \
+ host_jsoplengen host_jskwgen
+ cross_make \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" HOST_OPTIMIZE_FLAGS="" \
+ -C config nsinstall
+ mv {,native-}host_jskwgen || die
+ mv {,native-}host_jsoplengen || die
+ mv config/{,native-}nsinstall || die
+ sed -i \
+ -e 's@./host_jskwgen@./native-host_jskwgen@' \
+ -e 's@./host_jsoplengen@./native-host_jsoplengen@' \
+ Makefile || die
+ sed -i -e 's@/nsinstall@/native-nsinstall@' config/config.mk || die
+ rm -f config/host_nsinstall.o \
+ config/host_pathsub.o \
+ host_jskwgen.o \
+ host_jsoplengen.o || die
+ fi
+
+ MOZ_MAKE_FLAGS="${MAKEOPTS}" \
+ emake \
+ MOZ_OPTIMIZE_FLAGS="" MOZ_DEBUG_FLAGS="" \
+ HOST_OPTIMIZE_FLAGS="" MODULE_OPTIMIZE_FLAGS="" \
+ MOZ_PGO_OPTIMIZE_FLAGS=""
+}
+
+src_test() {
+ cd "${BUILDDIR}/js/src/jsapi-tests" || die
+ ./jsapi-tests || die
+}
+
+src_install() {
+ cd "${BUILDDIR}" || die
+ emake DESTDIR="${D}" install
+
+ if ! use minimal; then
+ pax-mark m "${ED}"usr/bin/js${SLOT}
+ else
+ rm -f "${ED}"usr/bin/js${SLOT}
+ fi
+
+ # We can't actually disable building of static libraries
+ # They're used by the tests and in a few other places
+ find "${D}" -iname '*.a' -o -iname '*.ajs' -delete || die
+}
diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-1.7.0-r3 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-1.7.0-r3
new file mode 100644
index 0000000000..22bffd2fc0
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-1.7.0-r3
@@ -0,0 +1,13 @@
+DEFINED_PHASES=compile install prepare
+DEPEND=threadsafe? ( dev-libs/nspr )
+DESCRIPTION=Stand-alone JavaScript C library
+EAPI=5
+HOMEPAGE=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey
+IUSE=threadsafe unicode
+KEYWORDS=alpha amd64 ~arm ppc ppc64 ~sparc x86 ~x86-fbsd
+LICENSE=NPL-1.1
+RDEPEND=threadsafe? ( dev-libs/nspr )
+SLOT=0/js
+SRC_URI=http://archive.mozilla.org/pub/js/js-1.7.0.tar.gz https://dev.gentoo.org/~axs/distfiles/spidermonkey-slot0-patches-01.tar.xz
+_eclasses_=desktop b1d22ac8bdd4679ab79c71aca235009d epatch a1bf4756dba418a7238f3be0cb010c54 estack 43ddf5aaffa7a8d0482df54d25a66a1f eutils 6e6c2737b59a4b982de6fb3ecefd87f8 flag-o-matic 55aaa148741116aa54ad0d80e361818e ltprune 08f9e1d9ee0af8f5d9a7854efbcd8c0e multilib b2f01ad412baf81650c23fcf0975fa33 preserve-libs ef207dc62baddfddfd39a164d9797648 toolchain-funcs f164325a2cdb5b3ea39311d483988861 vcs-clean 2a0f74a496fa2b1552c4f3398258b7bf
+_md5_=50dff43f0e40f6b4ce25d3c23e5854ce
diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-1.8.5-r6 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-1.8.5-r6
new file mode 100644
index 0000000000..56c1c215c5
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-1.8.5-r6
@@ -0,0 +1,13 @@
+DEFINED_PHASES=compile configure install prepare setup test
+DEPEND=>=dev-libs/nspr-4.7.0 sys-libs/readline:0= x64-macos? ( dev-libs/jemalloc ) || ( >=dev-lang/python-2.7.5-r2:2.7[threads] ) app-arch/zip virtual/pkgconfig >=app-portage/elt-patches-20170815 !=sys-devel/automake-1.16.1:1.16 >=sys-devel/automake-1.15.1:1.15 ) ~sys-devel/autoconf-2.13 >=sys-devel/libtool-2.4
+DESCRIPTION=Stand-alone JavaScript C library
+EAPI=5
+HOMEPAGE=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey
+IUSE=debug minimal static-libs test
+KEYWORDS=alpha amd64 arm ~arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh ~sparc x86 ~amd64-fbsd ~x86-fbsd ~x64-macos
+LICENSE=NPL-1.1
+RDEPEND=>=dev-libs/nspr-4.7.0 sys-libs/readline:0= x64-macos? ( dev-libs/jemalloc )
+SLOT=0/mozjs185
+SRC_URI=https://archive.mozilla.org/pub/js/js185-1.0.0.tar.gz https://dev.gentoo.org/~axs/distfiles/spidermonkey-slot0-patches-01.tar.xz
+_eclasses_=autotools 1bf086cdd7356f5c9a4acd9727bd2065 desktop b1d22ac8bdd4679ab79c71aca235009d epatch a1bf4756dba418a7238f3be0cb010c54 estack 43ddf5aaffa7a8d0482df54d25a66a1f eutils 6e6c2737b59a4b982de6fb3ecefd87f8 libtool f143db5a74ccd9ca28c1234deffede96 ltprune 08f9e1d9ee0af8f5d9a7854efbcd8c0e multilib b2f01ad412baf81650c23fcf0975fa33 pax-utils e85f015e815dd463b0c206d781ef45a5 preserve-libs ef207dc62baddfddfd39a164d9797648 python-any-r1 4900ae970f827a22d33d41bd8b8f9ace python-utils-r1 12114a2a9aab35b93efc037a196b3234 toolchain-funcs f164325a2cdb5b3ea39311d483988861 vcs-clean 2a0f74a496fa2b1552c4f3398258b7bf versionator 2352c3fc97241f6a02042773c8287748
+_md5_=e35e6d2611df242f2bb08bc72c75b82b
diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-17.0.0-r4 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-17.0.0-r4
new file mode 100644
index 0000000000..c67a1c8d35
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-17.0.0-r4
@@ -0,0 +1,15 @@
+DEFINED_PHASES=compile configure install prepare setup test
+DEPEND=>=dev-libs/nspr-4.9.4 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.1.4 || ( >=dev-lang/python-2.7.5-r2:2.7[threads] ) app-arch/zip virtual/pkgconfig
+DESCRIPTION=Stand-alone JavaScript C library
+EAPI=5
+HOMEPAGE=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey
+IUSE=debug jit minimal static-libs test
+KEYWORDS=alpha amd64 arm -hppa ia64 -mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd
+LICENSE=NPL-1.1
+RDEPEND=>=dev-libs/nspr-4.9.4 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.1.4
+REQUIRED_USE=debug? ( jit )
+RESTRICT=ia64? ( test )
+SLOT=17
+SRC_URI=http://archive.mozilla.org/pub/js/mozjs17.0.0.tar.gz https://dev.gentoo.org/~axs/distfiles/spidermonkey-slot17-patches-01.tar.xz
+_eclasses_=desktop b1d22ac8bdd4679ab79c71aca235009d epatch a1bf4756dba418a7238f3be0cb010c54 estack 43ddf5aaffa7a8d0482df54d25a66a1f eutils 6e6c2737b59a4b982de6fb3ecefd87f8 ltprune 08f9e1d9ee0af8f5d9a7854efbcd8c0e multilib b2f01ad412baf81650c23fcf0975fa33 pax-utils e85f015e815dd463b0c206d781ef45a5 preserve-libs ef207dc62baddfddfd39a164d9797648 python-any-r1 4900ae970f827a22d33d41bd8b8f9ace python-utils-r1 12114a2a9aab35b93efc037a196b3234 toolchain-funcs f164325a2cdb5b3ea39311d483988861 vcs-clean 2a0f74a496fa2b1552c4f3398258b7bf versionator 2352c3fc97241f6a02042773c8287748
+_md5_=7b3755c321292a4872112b5ec6b261c6
diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-17.0.0-r5 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-17.0.0-r5
new file mode 100644
index 0000000000..eb8851e739
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-17.0.0-r5
@@ -0,0 +1,15 @@
+DEFINED_PHASES=compile configure install prepare setup test
+DEPEND=>=dev-libs/nspr-4.9.4 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.1.4 || ( >=dev-lang/python-2.7.5-r2:2.7[threads] ) app-arch/zip virtual/pkgconfig
+DESCRIPTION=Stand-alone JavaScript C library
+EAPI=6
+HOMEPAGE=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey
+IUSE=debug jit minimal static-libs test
+KEYWORDS=alpha amd64 arm -hppa ia64 -mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd
+LICENSE=NPL-1.1
+RDEPEND=>=dev-libs/nspr-4.9.4 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.1.4
+REQUIRED_USE=debug? ( jit )
+RESTRICT=ia64? ( test )
+SLOT=17
+SRC_URI=http://archive.mozilla.org/pub/js/mozjs17.0.0.tar.gz https://dev.gentoo.org/~axs/distfiles/spidermonkey-slot17-patches-01.tar.xz
+_eclasses_=estack 43ddf5aaffa7a8d0482df54d25a66a1f multilib b2f01ad412baf81650c23fcf0975fa33 pax-utils e85f015e815dd463b0c206d781ef45a5 python-any-r1 4900ae970f827a22d33d41bd8b8f9ace python-utils-r1 12114a2a9aab35b93efc037a196b3234 toolchain-funcs f164325a2cdb5b3ea39311d483988861 versionator 2352c3fc97241f6a02042773c8287748
+_md5_=aa8ecf92a16532e703e2187f9a0957a5
diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-24.2.0-r3 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-24.2.0-r3
new file mode 100644
index 0000000000..c078a17720
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-24.2.0-r3
@@ -0,0 +1,14 @@
+DEFINED_PHASES=compile configure install prepare setup test
+DEPEND=>=dev-libs/nspr-4.9.4 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.1.4 system-icu? ( >=dev-libs/icu-1.51:= ) || ( >=dev-lang/python-2.7.5-r2:2.7[threads] ) app-arch/zip virtual/pkgconfig >=app-portage/elt-patches-20170815 !=sys-devel/automake-1.16.1:1.16 >=sys-devel/automake-1.15.1:1.15 ) ~sys-devel/autoconf-2.13 >=sys-devel/libtool-2.4
+DESCRIPTION=Stand-alone JavaScript C library
+EAPI=5
+HOMEPAGE=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey
+IUSE=debug icu jit minimal static-libs +system-icu test
+KEYWORDS=alpha amd64 arm hppa ia64 ~mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd
+LICENSE=NPL-1.1
+RDEPEND=>=dev-libs/nspr-4.9.4 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.1.4 system-icu? ( >=dev-libs/icu-1.51:= )
+RESTRICT=ia64? ( test )
+SLOT=24
+SRC_URI=https://archive.mozilla.org/pub/js/mozjs-24.2.0.tar.bz2 https://dev.gentoo.org/~axs/distfiles/spidermonkey-slot24-patches-01.tar.xz
+_eclasses_=autotools 1bf086cdd7356f5c9a4acd9727bd2065 desktop b1d22ac8bdd4679ab79c71aca235009d epatch a1bf4756dba418a7238f3be0cb010c54 estack 43ddf5aaffa7a8d0482df54d25a66a1f eutils 6e6c2737b59a4b982de6fb3ecefd87f8 libtool f143db5a74ccd9ca28c1234deffede96 ltprune 08f9e1d9ee0af8f5d9a7854efbcd8c0e multilib b2f01ad412baf81650c23fcf0975fa33 pax-utils e85f015e815dd463b0c206d781ef45a5 preserve-libs ef207dc62baddfddfd39a164d9797648 python-any-r1 4900ae970f827a22d33d41bd8b8f9ace python-utils-r1 12114a2a9aab35b93efc037a196b3234 toolchain-funcs f164325a2cdb5b3ea39311d483988861 vcs-clean 2a0f74a496fa2b1552c4f3398258b7bf versionator 2352c3fc97241f6a02042773c8287748
+_md5_=10b906fea1f5d272bc3d4a34a367c417
diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-24.2.0-r4 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-24.2.0-r4
new file mode 100644
index 0000000000..285f43a32d
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-24.2.0-r4
@@ -0,0 +1,14 @@
+DEFINED_PHASES=compile configure install prepare setup test
+DEPEND=>=dev-libs/nspr-4.9.4 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.1.4 system-icu? ( >=dev-libs/icu-1.51:= ) || ( >=dev-lang/python-2.7.5-r2:2.7[threads] ) app-arch/zip virtual/pkgconfig >=app-portage/elt-patches-20170815 !=sys-devel/automake-1.16.1:1.16 >=sys-devel/automake-1.15.1:1.15 ) ~sys-devel/autoconf-2.13 >=sys-devel/libtool-2.4
+DESCRIPTION=Stand-alone JavaScript C library
+EAPI=6
+HOMEPAGE=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey
+IUSE=debug icu jit minimal static-libs +system-icu test
+KEYWORDS=alpha amd64 arm hppa ia64 ~mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd
+LICENSE=NPL-1.1
+RDEPEND=>=dev-libs/nspr-4.9.4 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.1.4 system-icu? ( >=dev-libs/icu-1.51:= )
+RESTRICT=ia64? ( test )
+SLOT=24
+SRC_URI=https://archive.mozilla.org/pub/js/mozjs-24.2.0.tar.bz2 https://dev.gentoo.org/~axs/distfiles/spidermonkey-slot24-patches-01.tar.xz
+_eclasses_=autotools 1bf086cdd7356f5c9a4acd9727bd2065 estack 43ddf5aaffa7a8d0482df54d25a66a1f libtool f143db5a74ccd9ca28c1234deffede96 multilib b2f01ad412baf81650c23fcf0975fa33 pax-utils e85f015e815dd463b0c206d781ef45a5 python-any-r1 4900ae970f827a22d33d41bd8b8f9ace python-utils-r1 12114a2a9aab35b93efc037a196b3234 toolchain-funcs f164325a2cdb5b3ea39311d483988861 versionator 2352c3fc97241f6a02042773c8287748
+_md5_=ae4b5ec879767de220cea7d5cfe32a5a
diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-38.3.0 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-38.3.0
new file mode 100644
index 0000000000..3a56c0fb1b
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-38.3.0
@@ -0,0 +1,14 @@
+DEFINED_PHASES=compile configure install prepare setup test
+DEPEND=>=dev-libs/nspr-4.10.10 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.2.3 system-icu? ( >=dev-libs/icu-51.1:= ) >=app-portage/elt-patches-20170815 !=sys-devel/automake-1.16.1:1.16 >=sys-devel/automake-1.15.1:1.15 ) ~sys-devel/autoconf-2.13 >=sys-devel/libtool-2.4 virtual/pkgconfig || ( >=dev-lang/python-2.7.5-r2:2.7[ncurses,sqlite,ssl,threads] )
+DESCRIPTION=Stand-alone JavaScript C library
+EAPI=6
+HOMEPAGE=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey
+IUSE=debug +jit minimal static-libs +system-icu test custom-cflags custom-optimization
+KEYWORDS=alpha amd64 ~arm ~hppa ia64 ~mips ppc ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd
+LICENSE=NPL-1.1
+RDEPEND=>=dev-libs/nspr-4.10.10 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.2.3 system-icu? ( >=dev-libs/icu-51.1:= )
+RESTRICT=ia64? ( test )
+SLOT=38
+SRC_URI=https://archive.mozilla.org/pub/spidermonkey/releases/38.3.0/mozjs-38.3.0sfink2.tar.bz2 https://dev.gentoo.org/~axs/distfiles/spidermonkey-slot38-patches-01.tar.xz
+_eclasses_=autotools 1bf086cdd7356f5c9a4acd9727bd2065 desktop b1d22ac8bdd4679ab79c71aca235009d epatch a1bf4756dba418a7238f3be0cb010c54 estack 43ddf5aaffa7a8d0482df54d25a66a1f eutils 6e6c2737b59a4b982de6fb3ecefd87f8 flag-o-matic 55aaa148741116aa54ad0d80e361818e libtool f143db5a74ccd9ca28c1234deffede96 ltprune 08f9e1d9ee0af8f5d9a7854efbcd8c0e mozcoreconf-v4 45c0b61c53e2dbbcf728355c62f8de3c multilib b2f01ad412baf81650c23fcf0975fa33 pax-utils e85f015e815dd463b0c206d781ef45a5 preserve-libs ef207dc62baddfddfd39a164d9797648 python-any-r1 4900ae970f827a22d33d41bd8b8f9ace python-utils-r1 12114a2a9aab35b93efc037a196b3234 toolchain-funcs f164325a2cdb5b3ea39311d483988861 vcs-clean 2a0f74a496fa2b1552c4f3398258b7bf versionator 2352c3fc97241f6a02042773c8287748
+_md5_=dd64edd1746abba4e134bcda06e0e5b6
diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-45.0.2 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-45.0.2
new file mode 100644
index 0000000000..d72e238aa9
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-45.0.2
@@ -0,0 +1,14 @@
+DEFINED_PHASES=compile configure install prepare setup test
+DEPEND=>=dev-libs/nspr-4.10.10 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.2.3 system-icu? ( >=dev-libs/icu-51.1:= ) >=app-portage/elt-patches-20170815 !=sys-devel/automake-1.16.1:1.16 >=sys-devel/automake-1.15.1:1.15 ) ~sys-devel/autoconf-2.13 >=sys-devel/libtool-2.4 virtual/pkgconfig || ( >=dev-lang/python-2.7.5-r2:2.7[ncurses,sqlite,ssl,threads] )
+DESCRIPTION=Stand-alone JavaScript C library
+EAPI=6
+HOMEPAGE=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey
+IUSE=debug +jit minimal static-libs +system-icu test custom-cflags custom-optimization
+KEYWORDS=~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd
+LICENSE=NPL-1.1
+RDEPEND=>=dev-libs/nspr-4.10.10 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.2.3 system-icu? ( >=dev-libs/icu-51.1:= )
+RESTRICT=ia64? ( test )
+SLOT=45
+SRC_URI=https://archive.mozilla.org/pub/spidermonkey/releases/45.0.2/mozjs-45.0.2.tar.bz2 https://dev.gentoo.org/~axs/distfiles/spidermonkey-slot45-patches-01.tar.xz
+_eclasses_=autotools 1bf086cdd7356f5c9a4acd9727bd2065 desktop b1d22ac8bdd4679ab79c71aca235009d epatch a1bf4756dba418a7238f3be0cb010c54 estack 43ddf5aaffa7a8d0482df54d25a66a1f eutils 6e6c2737b59a4b982de6fb3ecefd87f8 flag-o-matic 55aaa148741116aa54ad0d80e361818e libtool f143db5a74ccd9ca28c1234deffede96 ltprune 08f9e1d9ee0af8f5d9a7854efbcd8c0e mozcoreconf-v4 45c0b61c53e2dbbcf728355c62f8de3c multilib b2f01ad412baf81650c23fcf0975fa33 pax-utils e85f015e815dd463b0c206d781ef45a5 preserve-libs ef207dc62baddfddfd39a164d9797648 python-any-r1 4900ae970f827a22d33d41bd8b8f9ace python-utils-r1 12114a2a9aab35b93efc037a196b3234 toolchain-funcs f164325a2cdb5b3ea39311d483988861 vcs-clean 2a0f74a496fa2b1552c4f3398258b7bf versionator 2352c3fc97241f6a02042773c8287748
+_md5_=e38c86344ed64a78c9b10f9fc0ca447a
diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-52.9.1_pre1 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-52.9.1_pre1
new file mode 100644
index 0000000000..5d1b73311f
--- /dev/null
+++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/dev-lang/spidermonkey-52.9.1_pre1
@@ -0,0 +1,14 @@
+DEFINED_PHASES=compile configure install prepare setup test
+DEPEND=>=dev-libs/nspr-4.13.1 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.2.3 system-icu? ( >=dev-libs/icu-58.1:= ) >=app-portage/elt-patches-20170815 !=sys-devel/automake-1.16.1:1.16 >=sys-devel/automake-1.15.1:1.15 ) ~sys-devel/autoconf-2.13 >=sys-devel/libtool-2.4 virtual/pkgconfig || ( >=dev-lang/python-2.7.5-r2:2.7[ncurses,sqlite,ssl,threads] )
+DESCRIPTION=Stand-alone JavaScript C++ library
+EAPI=6
+HOMEPAGE=https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey
+IUSE=debug minimal +system-icu test custom-cflags custom-optimization
+KEYWORDS=~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd
+LICENSE=NPL-1.1
+RDEPEND=>=dev-libs/nspr-4.13.1 virtual/libffi sys-libs/readline:0= >=sys-libs/zlib-1.2.3 system-icu? ( >=dev-libs/icu-58.1:= )
+RESTRICT=ia64? ( test )
+SLOT=52
+SRC_URI=http://ftp.mozilla.org/pub/spidermonkey/prereleases/52/pre1/mozjs-52.9.1pre1.tar.bz2 -> mozjs-52.9.1pre1.tar.bz2 https://dev.gentoo.org/~axs/distfiles/spidermonkey-52.0-patches-0.tar.xz
+_eclasses_=autotools 1bf086cdd7356f5c9a4acd9727bd2065 desktop b1d22ac8bdd4679ab79c71aca235009d epatch a1bf4756dba418a7238f3be0cb010c54 estack 43ddf5aaffa7a8d0482df54d25a66a1f eutils 6e6c2737b59a4b982de6fb3ecefd87f8 flag-o-matic 55aaa148741116aa54ad0d80e361818e libtool f143db5a74ccd9ca28c1234deffede96 ltprune 08f9e1d9ee0af8f5d9a7854efbcd8c0e mozcoreconf-v5 602c3c0a642bafeabb149c49a6df941f multilib b2f01ad412baf81650c23fcf0975fa33 pax-utils e85f015e815dd463b0c206d781ef45a5 preserve-libs ef207dc62baddfddfd39a164d9797648 python-any-r1 4900ae970f827a22d33d41bd8b8f9ace python-utils-r1 12114a2a9aab35b93efc037a196b3234 toolchain-funcs f164325a2cdb5b3ea39311d483988861 vcs-clean 2a0f74a496fa2b1552c4f3398258b7bf versionator 2352c3fc97241f6a02042773c8287748
+_md5_=be730937ba09030e9e9d83cc966dfc91