summaryrefslogtreecommitdiff
path: root/www-client/elinks
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /www-client/elinks
reinit the tree, so we can have metadata
Diffstat (limited to 'www-client/elinks')
-rw-r--r--www-client/elinks/Manifest16
-rw-r--r--www-client/elinks/elinks-0.12_pre6-r1.ebuild183
-rw-r--r--www-client/elinks/elinks-0.12_pre6-r2.ebuild186
-rw-r--r--www-client/elinks/elinks-9999.ebuild156
-rw-r--r--www-client/elinks/files/elinks-0.10.4.conf-syscharset.diff79
-rw-r--r--www-client/elinks/files/elinks-0.11.2-lua-5.1.patch16
-rw-r--r--www-client/elinks/files/elinks-0.12_pre5-compilation-fix.patch12
-rw-r--r--www-client/elinks/files/elinks-0.12_pre5-ruby-1.9.patch187
-rw-r--r--www-client/elinks/files/elinks-0.12_pre5-sm185-jsval-fixes.patch124
-rw-r--r--www-client/elinks/files/elinks-0.12pre5-spidermonkey-callback.patch12
-rw-r--r--www-client/elinks/files/elinks-9999-parallel-make.patch51
-rw-r--r--www-client/elinks/metadata.xml20
12 files changed, 1042 insertions, 0 deletions
diff --git a/www-client/elinks/Manifest b/www-client/elinks/Manifest
new file mode 100644
index 000000000000..017d5e27095d
--- /dev/null
+++ b/www-client/elinks/Manifest
@@ -0,0 +1,16 @@
+AUX elinks-0.10.4.conf-syscharset.diff 2580 SHA256 3269413843aabff245ee3dce522a475e5b3042adf4676b644a63d323bb77818c SHA512 3b17025054f9cf2ed9934ce5c19859eb50a216a295e6712659c4899c3539e3fc571e6f289809ad2d07be44330b96107a8dd65754c23f978bd54def28a24b88b3 WHIRLPOOL 230294ec39cec90ae84fd23644bcdadb97de8635eb794b4baf8e93d0b0fc2932f7b54ee25f6c4e49166aa4e296ab05f5588561fcab56867bb3caee0b9ab9db16
+AUX elinks-0.11.2-lua-5.1.patch 538 SHA256 d931af4db13b53be32def17417d86ee916511209ce9a54f25d017ee2d24473d4 SHA512 48aca9662b3d9b43ba027d2328acdafe6363f3e2a69e6f2a6d468718c28f12de6247c629273a11aef0b053010a7b7250c03db39fab1cb4cd6d237bd1c69fccef WHIRLPOOL 4f84c457ed14a2d7414edbe374623e5295aa9ee8aa71403d386a46b499143a97d1dc78ff5d8951d602f8d60cefc648f79ed02038267cb58ae79ba062e68d1e34
+AUX elinks-0.12_pre5-compilation-fix.patch 464 SHA256 984c3e1127c18eb0925fbe1cca5bb2a7b214c6cd082db434e8fe37e082715e7e SHA512 7c1232f4f15579f8073cdea7397e4a34d5bec51268eb61cdff854f221615b027c385b81871e7b5fbefeda1ddf5de3008719724b9853798bc198866a25c8840fe WHIRLPOOL 1a3303d1ed36429bf47b4a1e55a87917d3fe20417f218999c1a02a90c199b4a1dc914a674c86fce8c62cb5cb3ab11019c2547de8c9cb44fe5660f2673b706062
+AUX elinks-0.12_pre5-ruby-1.9.patch 7131 SHA256 4274a6434c42b669fbee9e75a79bd02c33d50472bbb8e1c2ea441b3d2eae20de SHA512 41f8b34f9666740fbadffc4e47467670c7766f3b8612933a08cc6febe975f9453c21c393a43927c11ffe7ef6e0875ef09e125c80e84caa9f0917f864cb1d35e6 WHIRLPOOL 691d259ea49b1a859680b245a383fcf1da79626e848fb35489bdfa787c0fe0c99405610a10a03dbdde7847a838e8ac060c37136b8f71ce73751449afd7b293fa
+AUX elinks-0.12_pre5-sm185-jsval-fixes.patch 3921 SHA256 d59f9e97f5d495803e0ac35726bf42592a8f726c2367fbc08b8fe9de79de4a2f SHA512 62a96d53b529c409d81094899c75cd7943176628e2b7301a005c6ebf9f660e813fbf1f3df213c43148d425e933208f761090b23b6ae75da93a93b13a1e924a34 WHIRLPOOL 03ae46d5a9497ac81db5cca364aa6cda4bfb3dc5864482e11778dfef752ae4c76a374026fafa3e2507c9626c528b483bd68a3277647b4c200de95197507fefa5
+AUX elinks-0.12pre5-spidermonkey-callback.patch 513 SHA256 14b65ba92e8693105945d20de6e8f07ec946f17fbbf5248b4f8c431a92b88982 SHA512 81a2397b90531db291526fed738fd3661362c3d20c4bc330f909375cea3779f32f4286c8c43700bf7c19d6eb177e97acb3c32f15abba052651ee5b947f3bec43 WHIRLPOOL 224e95b0f09c61de04c1b6e9845a56ca94ee5c99fb90a7c9e57800c1cede50658091d7b1b3a7aec5a0bad9b7eff2e5ca4a1f7a107381bf8208b08e1624661f3d
+AUX elinks-9999-parallel-make.patch 1620 SHA256 f9eb07dedc6a08a4ffb3f592422313563e14a486a635a306016658168221bb2d SHA512 bdd612c1ce226115170e97d70519b5ec4816d8469e0cd31ec66000b603c92913645f2b57eca9f030b90af811e43db5647928d27f7bc3a8c06560be40a8063248 WHIRLPOOL 9a0e336bf1dc43632aae15d06921f83235acf53a3cb2ec617d8a14c504050c9a7985e0f9cd30db9ea77e18abde4f934ed0d1a698b8b267df946cddb8147a9751
+DIST elinks-0.10.4.conf.bz2 5370 SHA256 cb0fcd10cc592697de5d8d9358447a770d2b4613b17b629c0f0e05965baa6209 SHA512 defdc743d78f9620eac60f4cfc1c07ecc6d18d1d771899b6eec184bea818d612ef110219127284a5b7c53ca07746fc90fbeb97344b3aef7f1f894ed839443296 WHIRLPOOL c6dd65a281a0f48461ddac18e9981c029acd4906a294a02cfcf40429a18b443dee92a7c3317e704dc61fb519df3fa80da14c49a3f138640e223b64372669aa3a
+DIST elinks-0.12_pre5-js185-patches.tar.bz2 13820 SHA256 64f7c4a657128983d054bd0d2027e11facd42fcc86bd8dfdf5b27ffbacbd54c8 SHA512 1552aeacdecb0a2db357402e0474d6b4810c767609d1d399b3350a4bcdc21ba9c0bde5a5d0bffd1d7b27d41ac46e3e85ae2527d715a1645a2dd51ab14b8eab3c WHIRLPOOL e6f7746407cd6654c19d4bc71dc4d0fd63070a78f7bc7c43f11f6e388268de963748597b0a2fd03cd22632651800b990ec0819d54799be9bfc4589332e11dbdd
+DIST elinks-0.12pre6.tar.bz2 2854500 SHA256 383646375b8a325bef5a132c8300caab90eb0b842c5f8eff68febc00e29acada SHA512 bff70faafea7c4739695a7fad8f659109894b318588f5a035a5594a6053238789259ce6067c2f5cb97448f138db143adebb23f84bf689bea209ba37573484b7f WHIRLPOOL 2501e7ed557dfcc5ca4175bda3452d8c1dc42c2db2f18a0263373b6f28966619e3b3c75b0ed3d9cb4e04d177bd5d88ecdedda541531adfcd35b6ef4fe4920ed1
+EBUILD elinks-0.12_pre6-r1.ebuild 6169 SHA256 8aa6e19508521d4d980065e2e5bcd61eeba3acb5a0c558ca145dbd0b8ddb620c SHA512 55fdeff2c895755867af2b8955f2c998c0f4630a42bf6b42cd04fc06375319711cd9d16148e4c3522f3aee01fc815afc66f8d7985c861aec93edf662c76dd8b5 WHIRLPOOL ea399425b28c4e9a9e4ce58b4be3480e61815917111464728674a2071bb65c2451e84f880a3c23c69dee135fa6f77c43961cb53ac1ab441e42512b4a62605e88
+EBUILD elinks-0.12_pre6-r2.ebuild 6237 SHA256 a77c2f000850daa94ad1678418c3562dfa74d0c3ca771deb4c7f195198fb9b9e SHA512 577d54441d67bde1ef5c184def7966307d6edbcc7f1150bd7877ac52e92986007b78d7940d368a750459d27943e23a412076a3f48f3842f69dcf7fd3ab79d119 WHIRLPOOL 9d2bd6dddfe15f3ace534675a3d70dd340806f799ab19f1573bcea7915fbc39fd41562610589aebe657a2988e581cccb84fa7bd823c98a3473ba0e906fca89fe
+EBUILD elinks-9999.ebuild 4541 SHA256 1645bce21dfd50610d9d70e2adffaed98542f64161d66ab743e6fa2309a9f1aa SHA512 fc872f241992d8239971b64498d3a1e8b3be26de4b37c1ea3369fb5ff823c96d8e93e9d8d0f6e73bd781836fb1c53d6b6ea11d76d905ca8432d0406a6cee36ae WHIRLPOOL 70c9b08c0299576f20ea3fad5767cfe2713449d569c6f599eee99ae206ad8080290c733d3f529192c36360107bab875f349d7c21d9288038591605a8f30d5499
+MISC ChangeLog 4414 SHA256 b262ad1bf7c6a9a6f6c235e3c18dc9d1bf8e02464fe9d02261f027f39030daef SHA512 4e638a40d71c0255fbcaaece19e086b2ab686f3925c94e2bdcdd1db4fc0df5d095c288aecbf1f29eb3d20e9c57e64f325914304c57f3a64167d36533136a8f05 WHIRLPOOL 8081af9da11d5348596d8983c316d0419fbd91653f77c526d4ee975165b3e39f0eefc4af8a631694d8206937491915b808229e3edbdb9792b682b01c4db9e5be
+MISC ChangeLog-2015 31519 SHA256 71745c2c3c1045e62ad4e81c483e1631b1ade3613960e1ceac53e7138667661a SHA512 69e0aed4825d552cc2759f4d450ade766d0af7a9d28bb5dcf0b8f2bd84d42b8ccf3ef3c359ddbca50d6a2adde93d69a9cbbfb1354ddf25d5f76b8debd1bfd281 WHIRLPOOL 46b05f4a92f49f420abd0841116d3e302d5ce9078a8fd4c8df3fe2e56941ba6a21567bbb5130d8a54e677913c7dee25e4a45a27743ce7e3dddc2939e8b0dfe17
+MISC metadata.xml 836 SHA256 12135eef67bef2f67b967d706cb2dcf7352f006bf9229dea7bd21c227cb4fda2 SHA512 59193a58790b8616e11c4e998762f936a313ecbf9b51b922f85bd02c52a74c34a58196c1a4f425de74ffb89a913e05f1d6fc2f824d9255d583381e241badcb23 WHIRLPOOL d7923db6c626b3b8fafd325e42231d0c32fb5f92dd212d05a14bb5ad5b7756959adc9c631200892eacb0c4d5634eedbc9a36cf884e573ba08838440bbb8642df
diff --git a/www-client/elinks/elinks-0.12_pre6-r1.ebuild b/www-client/elinks/elinks-0.12_pre6-r1.ebuild
new file mode 100644
index 000000000000..0f7f036a2e67
--- /dev/null
+++ b/www-client/elinks/elinks-0.12_pre6-r1.ebuild
@@ -0,0 +1,183 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=4
+inherit eutils autotools flag-o-matic
+
+MY_P="${P/_/}"
+DESCRIPTION="Advanced and well-established text-mode web browser"
+HOMEPAGE="http://elinks.or.cz/"
+SRC_URI="http://elinks.or.cz/download/${MY_P}.tar.bz2
+ https://dev.gentoo.org/~spock/portage/distfiles/elinks-0.10.4.conf.bz2
+ https://dev.gentoo.org/~axs/distfiles/${PN}-0.12_pre5-js185-patches.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="alpha amd64 ~arm hppa ia64 ~mips ppc ppc64 sparc x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="bittorrent bzip2 debug finger ftp gc gopher gpm guile idn ipv6
+ javascript lua +mouse nls nntp perl ruby samba ssl unicode X xml zlib"
+RESTRICT="test"
+
+DEPEND="
+ bzip2? ( >=app-arch/bzip2-1.0.2 )
+ gc? ( dev-libs/boehm-gc )
+ ssl? ( >=dev-libs/openssl-0.9.6g:0 )
+ xml? ( >=dev-libs/expat-1.95.4 )
+ X? ( x11-libs/libX11 x11-libs/libXt )
+ zlib? ( >=sys-libs/zlib-1.1.4 )
+ lua? ( >=dev-lang/lua-5:0 )
+ gpm? ( >=sys-libs/ncurses-5.2:0 >=sys-libs/gpm-1.20.0-r5 )
+ guile? ( >=dev-scheme/guile-1.6.4-r1[deprecated,discouraged] )
+ idn? ( net-dns/libidn )
+ perl? ( dev-lang/perl )
+ ruby? ( dev-lang/ruby dev-ruby/rubygems )
+ samba? ( net-fs/samba )
+ javascript? ( dev-lang/spidermonkey:0 )"
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}/${MY_P}"
+
+src_prepare() {
+ cd "${WORKDIR}"
+ epatch "${FILESDIR}"/${PN}-0.10.4.conf-syscharset.diff
+ mv "${PN}-0.10.4.conf" "${PN}.conf"
+ if ! use ftp ; then
+ sed -i -e 's/\(.*protocol.ftp.*\)/# \1/' ${PN}.conf
+ fi
+ sed -i -e 's/\(.*set protocol.ftp.use_epsv.*\)/# \1/' ${PN}.conf
+ cd "${S}"
+
+ if use lua && has_version ">=dev-lang/lua-5.1"; then
+ epatch "${FILESDIR}"/${PN}-0.11.2-lua-5.1.patch
+ fi
+
+ epatch "${FILESDIR}"/${PN}-9999-parallel-make.patch
+ epatch "${FILESDIR}"/${PN}-0.12_pre5-compilation-fix.patch
+
+ if use javascript ; then
+ if has_version ">=dev-lang/spidermonkey-1.8"; then
+ if has_version ">=dev-lang/spidermonkey-1.8.5"; then
+ epatch "${WORKDIR}"/patches/${PN}-0.12_pre5-js185-1-heartbeat.patch
+ epatch "${WORKDIR}"/patches/${PN}-0.12_pre5-js185-2-up.patch
+ epatch "${WORKDIR}"/patches/${PN}-0.12_pre5-js185-3-histback.patch
+ epatch "${FILESDIR}"/${PN}-0.12_pre5-sm185-jsval-fixes.patch
+# if has_version ">=dev-lang/spidermonkey-1.8.7"; then
+# # fix lib order in configure check and add mozjs187
+# # (these seds are necessary so that @preserved-libs copies are not used)
+# sed -i -e 's:for spidermonkeylib in js .*$:for spidermonkeylib in mozjs187 mozjs185 mozjs js smjs; do:' \
+# configure.in || die
+# else
+ # fix lib order in configure check
+ # (these seds are necessary so that @preserved-libs copies are not used)
+ sed -i -e 's:for spidermonkeylib in js .*$:for spidermonkeylib in mozjs185 mozjs js smjs; do:' \
+ configure.in || die
+# fi
+ else
+ # fix lib order in configure check
+ # (these seds are necessary so that @preserved-libs copies are not used)
+ epatch "${FILESDIR}"/${MY_P}-spidermonkey-callback.patch
+ sed -i -e 's:for spidermonkeylib in js .*$:for spidermonkeylib in mozjs js smjs; do:' \
+ configure.in || die
+ fi
+ fi
+ fi
+ epatch "${FILESDIR}"/${PN}-0.12_pre5-ruby-1.9.patch
+ # Regenerate acinclude.m4 - based on autogen.sh.
+ cat > acinclude.m4 <<- _EOF
+ dnl Automatically generated from config/m4/ files.
+ dnl Do not modify!
+ _EOF
+ cat config/m4/*.m4 >> acinclude.m4
+
+ sed -i -e 's/-Werror//' configure*
+
+ eautoreconf
+}
+
+src_configure() {
+ # NOTE about GNUTSL SSL support (from the README -- 25/12/2002)
+ # As GNUTLS is not yet 100% stable and its support in ELinks is not so well
+ # tested yet, it's recommended for users to give a strong preference to OpenSSL whenever possible.
+ local myconf=""
+
+ if use debug ; then
+ myconf="--enable-debug"
+ else
+ myconf="--enable-fastmem"
+ fi
+
+ if use ssl ; then
+ myconf="${myconf} --with-openssl=${EPREFIX}/usr"
+ else
+ myconf="${myconf} --without-openssl --without-gnutls"
+ fi
+
+ econf \
+ --sysconfdir="${EPREFIX}"/etc/elinks \
+ --enable-leds \
+ --enable-88-colors \
+ --enable-256-colors \
+ --enable-true-color \
+ --enable-html-highlight \
+ $(use_with gpm) \
+ $(use_with zlib) \
+ $(use_with bzip2 bzlib) \
+ $(use_with gc) \
+ $(use_with X x) \
+ $(use_with lua) \
+ $(use_with guile) \
+ $(use_with perl) \
+ $(use_with ruby) \
+ $(use_with idn) \
+ $(use_with javascript spidermonkey) \
+ $(use_enable bittorrent) \
+ $(use_enable nls) \
+ $(use_enable ipv6) \
+ $(use_enable ftp) \
+ $(use_enable gopher) \
+ $(use_enable nntp) \
+ $(use_enable finger) \
+ $(use_enable samba smb) \
+ $(use_enable mouse) \
+ $(use_enable xml xbel) \
+ ${myconf}
+}
+
+src_compile() {
+ emake V=1
+}
+
+src_install() {
+ emake V=1 DESTDIR="${D}" install
+
+ insopts -m 644 ; insinto /etc/elinks
+ doins "${WORKDIR}"/elinks.conf
+ newins contrib/keybind-full.conf keybind-full.sample
+ newins contrib/keybind.conf keybind.conf.sample
+
+ dodoc AUTHORS BUGS ChangeLog INSTALL NEWS README SITES THANKS TODO doc/*.*
+ docinto contrib ; dodoc contrib/{README,colws.diff,elinks[-.]vim*}
+ insinto /usr/share/doc/${PF}/contrib/lua ; doins contrib/lua/{*.lua,elinks-remote}
+ insinto /usr/share/doc/${PF}/contrib/conv ; doins contrib/conv/*.*
+ insinto /usr/share/doc/${PF}/contrib/guile ; doins contrib/guile/*.scm
+
+ # Remove some conflicting files on OSX. The files provided by OSX 10.4
+ # are more or less the same. -- Fabian Groffen (2005-06-30)
+ rm -f "${ED}"/usr/share/locale/locale.alias "${ED}"/usr/lib/charset.alias || die
+}
+
+pkg_postinst() {
+ einfo "This ebuild provides a default config for ELinks."
+ einfo "Please check /etc/elinks/elinks.conf"
+ einfo
+ einfo "You may want to convert your html.cfg and links.cfg of"
+ einfo "Links or older ELinks versions to the new ELinks elinks.conf"
+ einfo "using /usr/share/doc/${PF}/contrib/conv/conf-links2elinks.pl"
+ einfo
+ einfo "Please have a look at /etc/elinks/keybind-full.sample and"
+ einfo "/etc/elinks/keybind.conf.sample for some bindings examples."
+ einfo
+ einfo "You will have to set your TERM variable to 'xterm-256color'"
+ einfo "to be able to use 256 colors in elinks."
+ echo
+}
diff --git a/www-client/elinks/elinks-0.12_pre6-r2.ebuild b/www-client/elinks/elinks-0.12_pre6-r2.ebuild
new file mode 100644
index 000000000000..ed3f69831bd0
--- /dev/null
+++ b/www-client/elinks/elinks-0.12_pre6-r2.ebuild
@@ -0,0 +1,186 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+inherit eutils autotools flag-o-matic
+
+MY_P="${P/_/}"
+DESCRIPTION="Advanced and well-established text-mode web browser"
+HOMEPAGE="http://elinks.or.cz/"
+SRC_URI="http://elinks.or.cz/download/${MY_P}.tar.bz2
+ https://dev.gentoo.org/~spock/portage/distfiles/elinks-0.10.4.conf.bz2
+ https://dev.gentoo.org/~axs/distfiles/${PN}-0.12_pre5-js185-patches.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="bittorrent bzip2 debug finger ftp gc gopher gpm guile idn ipv6
+ javascript libressl lua +mouse nls nntp perl ruby samba ssl unicode X xml zlib"
+RESTRICT="test"
+
+DEPEND="
+ bzip2? ( >=app-arch/bzip2-1.0.2 )
+ gc? ( dev-libs/boehm-gc )
+ ssl? (
+ !libressl? ( dev-libs/openssl:0= )
+ libressl? ( dev-libs/libressl:0= )
+ )
+ xml? ( >=dev-libs/expat-1.95.4 )
+ X? ( x11-libs/libX11 x11-libs/libXt )
+ zlib? ( >=sys-libs/zlib-1.1.4 )
+ lua? ( >=dev-lang/lua-5:0 )
+ gpm? ( >=sys-libs/ncurses-5.2:0 >=sys-libs/gpm-1.20.0-r5 )
+ guile? ( >=dev-scheme/guile-1.6.4-r1[deprecated,discouraged] )
+ idn? ( net-dns/libidn )
+ perl? ( dev-lang/perl )
+ ruby? ( dev-lang/ruby:= dev-ruby/rubygems )
+ samba? ( net-fs/samba )
+ javascript? ( dev-lang/spidermonkey:0 )"
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}/${MY_P}"
+
+src_prepare() {
+ cd "${WORKDIR}"
+ epatch "${FILESDIR}"/${PN}-0.10.4.conf-syscharset.diff
+ mv "${PN}-0.10.4.conf" "${PN}.conf"
+ if ! use ftp ; then
+ sed -i -e 's/\(.*protocol.ftp.*\)/# \1/' ${PN}.conf
+ fi
+ sed -i -e 's/\(.*set protocol.ftp.use_epsv.*\)/# \1/' ${PN}.conf
+ cd "${S}"
+
+ if use lua && has_version ">=dev-lang/lua-5.1"; then
+ epatch "${FILESDIR}"/${PN}-0.11.2-lua-5.1.patch
+ fi
+
+ epatch "${FILESDIR}"/${PN}-9999-parallel-make.patch
+ epatch "${FILESDIR}"/${PN}-0.12_pre5-compilation-fix.patch
+
+ if use javascript ; then
+ if has_version ">=dev-lang/spidermonkey-1.8"; then
+ if has_version ">=dev-lang/spidermonkey-1.8.5"; then
+ epatch "${WORKDIR}"/patches/${PN}-0.12_pre5-js185-1-heartbeat.patch
+ epatch "${WORKDIR}"/patches/${PN}-0.12_pre5-js185-2-up.patch
+ epatch "${WORKDIR}"/patches/${PN}-0.12_pre5-js185-3-histback.patch
+ epatch "${FILESDIR}"/${PN}-0.12_pre5-sm185-jsval-fixes.patch
+# if has_version ">=dev-lang/spidermonkey-1.8.7"; then
+# # fix lib order in configure check and add mozjs187
+# # (these seds are necessary so that @preserved-libs copies are not used)
+# sed -i -e 's:for spidermonkeylib in js .*$:for spidermonkeylib in mozjs187 mozjs185 mozjs js smjs; do:' \
+# configure.in || die
+# else
+ # fix lib order in configure check
+ # (these seds are necessary so that @preserved-libs copies are not used)
+ sed -i -e 's:for spidermonkeylib in js .*$:for spidermonkeylib in mozjs185 mozjs js smjs; do:' \
+ configure.in || die
+# fi
+ else
+ # fix lib order in configure check
+ # (these seds are necessary so that @preserved-libs copies are not used)
+ epatch "${FILESDIR}"/${MY_P}-spidermonkey-callback.patch
+ sed -i -e 's:for spidermonkeylib in js .*$:for spidermonkeylib in mozjs js smjs; do:' \
+ configure.in || die
+ fi
+ fi
+ fi
+ epatch "${FILESDIR}"/${PN}-0.12_pre5-ruby-1.9.patch
+ # Regenerate acinclude.m4 - based on autogen.sh.
+ cat > acinclude.m4 <<- _EOF
+ dnl Automatically generated from config/m4/ files.
+ dnl Do not modify!
+ _EOF
+ cat config/m4/*.m4 >> acinclude.m4
+
+ sed -i -e 's/-Werror//' configure*
+
+ eautoreconf
+}
+
+src_configure() {
+ # NOTE about GNUTSL SSL support (from the README -- 25/12/2002)
+ # As GNUTLS is not yet 100% stable and its support in ELinks is not so well
+ # tested yet, it's recommended for users to give a strong preference to OpenSSL whenever possible.
+ local myconf=""
+
+ if use debug ; then
+ myconf="--enable-debug"
+ else
+ myconf="--enable-fastmem"
+ fi
+
+ if use ssl ; then
+ myconf="${myconf} --with-openssl=${EPREFIX}/usr"
+ else
+ myconf="${myconf} --without-openssl --without-gnutls"
+ fi
+
+ econf \
+ --sysconfdir="${EPREFIX}"/etc/elinks \
+ --enable-leds \
+ --enable-88-colors \
+ --enable-256-colors \
+ --enable-true-color \
+ --enable-html-highlight \
+ $(use_with gpm) \
+ $(use_with zlib) \
+ $(use_with bzip2 bzlib) \
+ $(use_with gc) \
+ $(use_with X x) \
+ $(use_with lua) \
+ $(use_with guile) \
+ $(use_with perl) \
+ $(use_with ruby) \
+ $(use_with idn) \
+ $(use_with javascript spidermonkey) \
+ $(use_enable bittorrent) \
+ $(use_enable nls) \
+ $(use_enable ipv6) \
+ $(use_enable ftp) \
+ $(use_enable gopher) \
+ $(use_enable nntp) \
+ $(use_enable finger) \
+ $(use_enable samba smb) \
+ $(use_enable mouse) \
+ $(use_enable xml xbel) \
+ ${myconf}
+}
+
+src_compile() {
+ emake V=1
+}
+
+src_install() {
+ emake V=1 DESTDIR="${D}" install
+
+ insopts -m 644 ; insinto /etc/elinks
+ doins "${WORKDIR}"/elinks.conf
+ newins contrib/keybind-full.conf keybind-full.sample
+ newins contrib/keybind.conf keybind.conf.sample
+
+ dodoc AUTHORS BUGS ChangeLog INSTALL NEWS README SITES THANKS TODO doc/*.*
+ docinto contrib ; dodoc contrib/{README,colws.diff,elinks[-.]vim*}
+ insinto /usr/share/doc/${PF}/contrib/lua ; doins contrib/lua/{*.lua,elinks-remote}
+ insinto /usr/share/doc/${PF}/contrib/conv ; doins contrib/conv/*.*
+ insinto /usr/share/doc/${PF}/contrib/guile ; doins contrib/guile/*.scm
+
+ # Remove some conflicting files on OSX. The files provided by OSX 10.4
+ # are more or less the same. -- Fabian Groffen (2005-06-30)
+ rm -f "${ED}"/usr/share/locale/locale.alias "${ED}"/usr/lib/charset.alias || die
+}
+
+pkg_postinst() {
+ einfo "This ebuild provides a default config for ELinks."
+ einfo "Please check /etc/elinks/elinks.conf"
+ einfo
+ einfo "You may want to convert your html.cfg and links.cfg of"
+ einfo "Links or older ELinks versions to the new ELinks elinks.conf"
+ einfo "using /usr/share/doc/${PF}/contrib/conv/conf-links2elinks.pl"
+ einfo
+ einfo "Please have a look at /etc/elinks/keybind-full.sample and"
+ einfo "/etc/elinks/keybind.conf.sample for some bindings examples."
+ einfo
+ einfo "You will have to set your TERM variable to 'xterm-256color'"
+ einfo "to be able to use 256 colors in elinks."
+ echo
+}
diff --git a/www-client/elinks/elinks-9999.ebuild b/www-client/elinks/elinks-9999.ebuild
new file mode 100644
index 000000000000..86a85d7419f6
--- /dev/null
+++ b/www-client/elinks/elinks-9999.ebuild
@@ -0,0 +1,156 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="threads"
+inherit autotools eutils git-r3 flag-o-matic python-any-r1
+
+EGIT_REPO_URI="git://repo.or.cz/elinks.git"
+
+MY_P="${P/_/}"
+DESCRIPTION="Advanced and well-established text-mode web browser"
+HOMEPAGE="http://elinks.or.cz/"
+SRC_URI="https://dev.gentoo.org/~spock/portage/distfiles/elinks-0.10.4.conf.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS=""
+IUSE="bittorrent bzip2 debug finger ftp gc gopher gpm guile idn ipv6
+ javascript libressl lua +mouse nls nntp perl ruby samba ssl unicode X xml zlib"
+RESTRICT="test"
+
+DEPEND="
+ ${PYTHON_DEPS}
+ bzip2? ( >=app-arch/bzip2-1.0.2 )
+ gc? ( dev-libs/boehm-gc )
+ ssl? (
+ !libressl? ( dev-libs/openssl:0= )
+ libressl? ( dev-libs/libressl:0= )
+ )
+ xml? ( >=dev-libs/expat-1.95.4 )
+ X? ( x11-libs/libX11 x11-libs/libXt )
+ zlib? ( >=sys-libs/zlib-1.1.4 )
+ lua? ( >=dev-lang/lua-5:0= )
+ gpm? ( >=sys-libs/ncurses-5.2:0= >=sys-libs/gpm-1.20.0-r5 )
+ guile? ( >=dev-scheme/guile-1.6.4-r1[deprecated,discouraged] )
+ idn? ( net-dns/libidn )
+ perl? ( dev-lang/perl:= )
+ ruby? ( dev-lang/ruby:* dev-ruby/rubygems:* )
+ samba? ( net-fs/samba )
+ javascript? ( >=dev-lang/spidermonkey-1.8.5:0= )"
+RDEPEND="${DEPEND}"
+
+src_unpack() {
+ default
+ git-r3_src_unpack
+}
+
+src_prepare() {
+ mv "${WORKDIR}/${PN}-0.10.4.conf" "${WORKDIR}/${PN}.conf"
+ if ! use ftp ; then
+ sed -i -e 's/\(.*protocol.ftp.*\)/# \1/' "${WORKDIR}"/${PN}.conf
+ fi
+ sed -i -e 's/\(.*set protocol.ftp.use_epsv.*\)/# \1/' "${WORKDIR}"/${PN}.conf
+ epatch "${FILESDIR}"/${P}-parallel-make.patch
+
+ epatch_user
+
+ # Regenerate acinclude.m4 - based on autogen.sh.
+ cat > acinclude.m4 <<- _EOF
+ dnl Automatically generated from config/m4/ files.
+ dnl Do not modify!
+ _EOF
+ cat config/m4/*.m4 >> acinclude.m4
+ sed -i -e 's/-Werror//' configure*
+
+ eautoreconf
+}
+
+src_configure() {
+ # NOTE about GNUTSL SSL support (from the README -- 25/12/2002)
+ # As GNUTLS is not yet 100% stable and its support in ELinks is not so well
+ # tested yet, it's recommended for users to give a strong preference to OpenSSL whenever possible.
+ local myconf=""
+
+ if use debug ; then
+ myconf="--enable-debug"
+ else
+ myconf="--enable-fastmem"
+ fi
+
+ if use ssl ; then
+ myconf="${myconf} --with-openssl=${EPREFIX}/usr"
+ else
+ myconf="${myconf} --without-openssl --without-gnutls"
+ fi
+
+ econf \
+ --sysconfdir="${EPREFIX}"/etc/elinks \
+ --enable-leds \
+ --enable-88-colors \
+ --enable-256-colors \
+ --enable-true-color \
+ --enable-html-highlight \
+ $(use_with gpm) \
+ $(use_with zlib) \
+ $(use_with bzip2 bzlib) \
+ $(use_with gc) \
+ $(use_with X x) \
+ $(use_with lua) \
+ $(use_with guile) \
+ $(use_with perl) \
+ $(use_with ruby) \
+ $(use_with idn) \
+ $(use_with javascript spidermonkey) \
+ $(use_enable bittorrent) \
+ $(use_enable nls) \
+ $(use_enable ipv6) \
+ $(use_enable ftp) \
+ $(use_enable gopher) \
+ $(use_enable nntp) \
+ $(use_enable finger) \
+ $(use_enable samba smb) \
+ $(use_enable mouse) \
+ $(use_enable xml xbel) \
+ ${myconf}
+}
+
+src_compile() {
+ emake V=1
+}
+
+src_install() {
+ emake V=1 DESTDIR="${D}" install
+
+ insopts -m 644 ; insinto /etc/elinks
+ doins "${WORKDIR}"/elinks.conf
+ newins contrib/keybind-full.conf keybind-full.sample
+ newins contrib/keybind.conf keybind.conf.sample
+
+ dodoc AUTHORS BUGS ChangeLog INSTALL NEWS README SITES THANKS TODO doc/*.*
+ docinto contrib ; dodoc contrib/{README,colws.diff,elinks[-.]vim*}
+ insinto /usr/share/doc/${PF}/contrib/lua ; doins contrib/lua/{*.lua,elinks-remote}
+ insinto /usr/share/doc/${PF}/contrib/conv ; doins contrib/conv/*.*
+ insinto /usr/share/doc/${PF}/contrib/guile ; doins contrib/guile/*.scm
+
+ # Remove some conflicting files on OSX. The files provided by OSX 10.4
+ # are more or less the same. -- Fabian Groffen (2005-06-30)
+ rm -f "${ED}"/usr/share/locale/locale.alias "${ED}"/usr/lib/charset.alias || die
+}
+
+pkg_postinst() {
+ einfo "This ebuild provides a default config for ELinks."
+ einfo "Please check /etc/elinks/elinks.conf"
+ einfo
+ einfo "You may want to convert your html.cfg and links.cfg of"
+ einfo "Links or older ELinks versions to the new ELinks elinks.conf"
+ einfo "using /usr/share/doc/${PF}/contrib/conv/conf-links2elinks.pl"
+ einfo
+ einfo "Please have a look at /etc/elinks/keybind-full.sample and"
+ einfo "/etc/elinks/keybind.conf.sample for some bindings examples."
+ einfo
+ einfo "You will have to set your TERM variable to 'xterm-256color'"
+ einfo "to be able to use 256 colors in elinks."
+ echo
+}
diff --git a/www-client/elinks/files/elinks-0.10.4.conf-syscharset.diff b/www-client/elinks/files/elinks-0.10.4.conf-syscharset.diff
new file mode 100644
index 000000000000..dc64712b29a8
--- /dev/null
+++ b/www-client/elinks/files/elinks-0.10.4.conf-syscharset.diff
@@ -0,0 +1,79 @@
+--- elinks-0.10.4.conf 2005-04-08 15:29:49.000000000 -0700
++++ elinks-0.10.4-syscharset.conf 2006-11-04 00:26:26.000000000 -0800
+@@ -12,8 +12,6 @@
+ # obsolete config.saving_style. You shouldn't touch it.
+ set config.saving_style_w = 1
+
+- ## terminal.linux.charset <codepage>
+- set terminal.linux.charset = "us-ascii"
+ ## terminal.linux.transparency [0|1]
+ set terminal.linux.transparency = 1
+ ## terminal.linux.colors [0|1]
+@@ -29,8 +27,6 @@
+ ## terminal.linux.type <num>
+ set terminal.linux.type = 2
+
+- ## terminal.vt100.charset <codepage>
+- set terminal.vt100.charset = "us-ascii"
+ ## terminal.vt100.transparency [0|1]
+ set terminal.vt100.transparency = 1
+ ## terminal.vt100.colors [0|1]
+@@ -46,8 +42,6 @@
+ ## terminal.vt100.type <num>
+ set terminal.vt100.type = 1
+
+- ## terminal.vt110.charset <codepage>
+- set terminal.vt110.charset = "us-ascii"
+ ## terminal.vt110.transparency [0|1]
+ set terminal.vt110.transparency = 1
+ ## terminal.vt110.colors [0|1]
+@@ -63,8 +57,6 @@
+ ## terminal.vt110.type <num>
+ set terminal.vt110.type = 1
+
+- ## terminal.xterm.charset <codepage>
+- set terminal.xterm.charset = "us-ascii"
+ ## terminal.xterm.transparency [0|1]
+ set terminal.xterm.transparency = 1
+ ## terminal.xterm.colors [0|1]
+@@ -80,8 +72,6 @@
+ ## terminal.xterm.type <num>
+ set terminal.xterm.type = 1
+
+- ## terminal.xterm-color.charset <codepage>
+- set terminal.xterm-color.charset = "us-ascii"
+ ## terminal.xterm-color.transparency [0|1]
+ set terminal.xterm-color.transparency = 1
+ ## terminal.xterm-color.colors [0|1]
+@@ -96,8 +86,7 @@
+ set terminal.xterm-color.m11_hack = 0
+ ## terminal.xterm-color.type <num>
+ set terminal.xterm-color.type = 1
+- ## terminal.screen.charset <codepage>
+- set terminal.screen.charset = "us-ascii"
++
+ ## terminal.screen.transparency [0|1]
+ set terminal.screen.transparency = 1
+ ## terminal.screen.colors [0|1]
+@@ -270,10 +259,6 @@
+
+
+
+- ## document.codepage.assume <codepage>
+- # Default document codepage.
+- set document.codepage.assume = "ISO-8859-1"
+-
+ ## document.codepage.force_assumed [0|1]
+ # Ignore charset info sent by server.
+ set document.codepage.force_assumed = 0
+@@ -343,10 +328,6 @@
+
+
+
+- ## document.dump.codepage <codepage>
+- # Codepage used in dump output.
+- set document.dump.codepage = "us-ascii"
+-
+ ## document.dump.width <num>
+ # Width of screen in characters when dumping a HTML document.
+ set document.dump.width = 80
diff --git a/www-client/elinks/files/elinks-0.11.2-lua-5.1.patch b/www-client/elinks/files/elinks-0.11.2-lua-5.1.patch
new file mode 100644
index 000000000000..20db8a484598
--- /dev/null
+++ b/www-client/elinks/files/elinks-0.11.2-lua-5.1.patch
@@ -0,0 +1,16 @@
+diff -Naurp elinks-0.11.2/src/scripting/lua/core.c elinks-0.11.2-lua/src/scripting/lua/core.c
+--- elinks-0.11.2/src/scripting/lua/core.c 2006-11-19 14:46:37.000000000 +0100
++++ elinks-0.11.2-lua/src/scripting/lua/core.c 2007-03-10 15:34:47.000000000 +0100
+@@ -646,11 +646,7 @@ init_lua(struct module *module)
+ {
+ L = lua_open();
+
+- luaopen_base(L);
+- luaopen_table(L);
+- luaopen_io(L);
+- luaopen_string(L);
+- luaopen_math(L);
++ luaL_openlibs(L);
+
+ lua_register(L, LUA_ALERT, l_alert);
+ lua_register(L, "current_url", l_current_url);
diff --git a/www-client/elinks/files/elinks-0.12_pre5-compilation-fix.patch b/www-client/elinks/files/elinks-0.12_pre5-compilation-fix.patch
new file mode 100644
index 000000000000..dee09a67eb45
--- /dev/null
+++ b/www-client/elinks/files/elinks-0.12_pre5-compilation-fix.patch
@@ -0,0 +1,12 @@
+diff -Naurp elinks-0.12pre5-orig//src/intl/charsets.c elinks-0.12pre5/src/intl/charsets.c
+--- elinks-0.12pre5-orig//src/intl/charsets.c 2010-04-04 12:19:02.000000000 +0200
++++ elinks-0.12pre5/src/intl/charsets.c 2010-04-04 12:19:20.000000000 +0200
+@@ -821,7 +821,7 @@ free_utf_table(void)
+
+ /* Cast away const. */
+ for (i = 128; i < 256; i++)
+- mem_free((unsigned char *) utf_table[i].u.str);
++ mem_free(utf_table[i].u.str);
+ }
+
+ static struct conv_table *
diff --git a/www-client/elinks/files/elinks-0.12_pre5-ruby-1.9.patch b/www-client/elinks/files/elinks-0.12_pre5-ruby-1.9.patch
new file mode 100644
index 000000000000..1e07bcde190a
--- /dev/null
+++ b/www-client/elinks/files/elinks-0.12_pre5-ruby-1.9.patch
@@ -0,0 +1,187 @@
+diff -urp a/config/m4/ruby.m4 b/config/m4/ruby.m4
+--- a/config/m4/ruby.m4 2009-07-07 13:23:17.000000000 +0100
++++ b/config/m4/ruby.m4 2012-09-10 18:23:09.000000000 +0100
+@@ -32,36 +32,40 @@ if test "$CONFIG_SCRIPTING_RUBY" = "yes"
+ if test "$CONFIG_SCRIPTING_RUBY" != "no"; then
+
+ AC_MSG_CHECKING(Ruby version)
+- if $CONFIG_SCRIPTING_RUBY -e 'exit((VERSION or RUBY_VERSION) >= "1.6.0")' >/dev/null 2>/dev/null; then
++ if $CONFIG_SCRIPTING_RUBY -e 'exit((VERSION rescue RUBY_VERSION) >= "1.6.0")' >/dev/null 2>/dev/null; then
+ ruby_version=`$CONFIG_SCRIPTING_RUBY -e 'puts "#{VERSION rescue RUBY_VERSION}"'`
+ AC_MSG_RESULT($ruby_version)
+
+ AC_MSG_CHECKING(for Ruby header files)
+- rubyhdrdir=`$CONFIG_SCRIPTING_RUBY -r mkmf -e 'print Config::CONFIG[["archdir"]] || $hdrdir' 2>/dev/null`
++ rubyhdrdir=`$CONFIG_SCRIPTING_RUBY -r mkmf -e 'print RbConfig::CONFIG[["rubyhdrdir"]] || RbConfig::CONFIG[["archdir"]] || $hdrdir' 2>/dev/null`
+
+ if test "X$rubyhdrdir" != "X"; then
+ AC_MSG_RESULT($rubyhdrdir)
+ RUBY_CFLAGS="-I$rubyhdrdir"
+- rubylibs=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e 'print Config::CONFIG[["LIBS"]]'`
++ rubyarch=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e 'print RbConfig::CONFIG[["arch"]]'`
++ if test -d "$rubyhdrdir/$rubyarch"; then
++ RUBY_CFLAGS="$RUBY_CFLAGS -I$rubyhdrdir/$rubyarch"
++ fi
++ rubylibs=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e 'print RbConfig::CONFIG[["LIBS"]]'`
+
+ if test "X$rubylibs" != "X"; then
+ RUBY_LIBS="$rubylibs"
+ fi
+
+- librubyarg=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e 'print Config.expand(Config::CONFIG[["LIBRUBYARG"]])'`
++ librubyarg=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e 'print RbConfig.expand(RbConfig::CONFIG[["LIBRUBYARG"]])'`
+
+ if test -f "$rubyhdrdir/$librubyarg"; then
+ librubyarg="$rubyhdrdir/$librubyarg"
+
+ else
+- rubylibdir=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e 'print Config.expand(Config::CONFIG[["libdir"]])'`
++ rubylibdir=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e 'print RbConfig.expand(RbConfig::CONFIG[["libdir"]])'`
+ if test -f "$rubylibdir/$librubyarg"; then
+ librubyarg="$rubylibdir/$librubyarg"
+ elif test "$librubyarg" = "libruby.a"; then
+ dnl required on Mac OS 10.3 where libruby.a doesn't exist
+ librubyarg="-lruby"
+ else
+- librubyarg=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e "print '$librubyarg'.gsub(/-L\./, %'-L#{Config.expand(Config::CONFIG[\"libdir\"])}')"`
++ librubyarg=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e "print '$librubyarg'.gsub(/-L\./, %'-L#{RbConfig.expand(RbConfig::CONFIG[\"libdir\"])}')"`
+ fi
+ fi
+
+@@ -69,7 +73,7 @@ if test "$CONFIG_SCRIPTING_RUBY" = "yes"
+ RUBY_LIBS="$librubyarg $RUBY_LIBS"
+ fi
+
+- rubyldflags=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e 'print Config::CONFIG[["LDFLAGS"]]'`
++ rubyldflags=`$CONFIG_SCRIPTING_RUBY -r rbconfig -e 'print RbConfig::CONFIG[["LDFLAGS"]]'`
+ if test "X$rubyldflags" != "X"; then
+ LDFLAGS="$rubyldflags $LDFLAGS"
+ fi
+@@ -86,6 +90,15 @@ if test "$CONFIG_SCRIPTING_RUBY" = "yes"
+ AC_MSG_RESULT(too old; need Ruby version 1.6.0 or later)
+ fi
+ fi
++ if test "$CONFIG_SCRIPTING_RUBY" = "yes"; then
++ AC_MSG_CHECKING([for rb_errinfo])
++ AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <ruby.h>]], [[rb_errinfo();]])],have_rb_errinfo="yes",have_rb_errinfo="no")
++ AC_MSG_RESULT($have_rb_errinfo)
++ if test "$have_rb_errinfo" = "yes"; then
++ AC_DEFINE([HAVE_RB_ERRINFO], [1],
++ [Define to 1 if you have the `rb_errinfo' function.])
++ fi
++ fi
+ fi
+
+ EL_RESTORE_FLAGS
+diff -urp a/src/scripting/ruby/core.c b/src/scripting/ruby/core.c
+--- a/src/scripting/ruby/core.c 2009-07-07 13:23:17.000000000 +0100
++++ b/src/scripting/ruby/core.c 2012-09-10 18:27:05.000000000 +0100
+@@ -76,10 +76,10 @@ erb_report_error(struct session *ses, in
+ break;
+ case TAG_RAISE:
+ case TAG_FATAL:
+- eclass = CLASS_OF(ruby_errinfo);
+- einfo = rb_obj_as_string(ruby_errinfo);
++ eclass = CLASS_OF(RB_ERRINFO);
++ einfo = rb_obj_as_string(RB_ERRINFO);
+
+- if (eclass == rb_eRuntimeError && RSTRING(einfo)->len == 0) {
++ if (eclass == rb_eRuntimeError && RSTRING_LEN(einfo) == 0) {
+ msg = "unhandled exception";
+
+ } else {
+@@ -88,7 +88,7 @@ erb_report_error(struct session *ses, in
+
+ epath = rb_class_path(eclass);
+ snprintf(buff, MAX_STR_LEN, "%s: %s",
+- RSTRING(epath)->ptr, RSTRING(einfo)->ptr);
++ RSTRING_PTR(epath), RSTRING_PTR(einfo));
+
+ p = strchr(buff, '\n');
+ if (p) *p = '\0';
+@@ -115,7 +115,7 @@ erb_module_message(VALUE self, VALUE str
+ unsigned char *message, *line_end;
+
+ str = rb_obj_as_string(str);
+- message = memacpy(RSTRING(str)->ptr, RSTRING(str)->len);
++ message = memacpy(RSTRING_PTR(str), RSTRING_LEN(str));
+ if (!message) return Qnil;
+
+ line_end = strchr(message, '\n');
+@@ -162,8 +162,8 @@ erb_stdout_p(int argc, VALUE *argv, VALU
+ * the inspect() method, which adds quotes to the strings, so
+ * gently ignore them. */
+
+- ptr = RSTRING(substr)->ptr;
+- len = RSTRING(substr)->len;
++ ptr = RSTRING_PTR(substr);
++ len = RSTRING_LEN(substr);
+
+ if (*ptr == '"')
+ ptr++, len--;
+diff -urp a/src/scripting/ruby/core.h b/src/scripting/ruby/core.h
+--- a/src/scripting/ruby/core.h 2009-07-07 13:23:17.000000000 +0100
++++ b/src/scripting/ruby/core.h 2012-09-10 18:26:25.000000000 +0100
+@@ -7,6 +7,20 @@ struct session;
+
+ #include <ruby.h> /* for VALUE */
+
++#ifndef RSTRING_LEN
++#define RSTRING_LEN(string) (RSTRING(string)->len)
++#endif
++
++#ifndef RSTRING_PTR
++#define RSTRING_PTR(string) (RSTRING(string)->ptr)
++#endif
++
++#ifdef HAVE_RB_ERRINFO
++#define RB_ERRINFO (rb_errinfo())
++#else
++#define RB_ERRINFO (ruby_errinfo)
++#endif
++
+ VALUE erb_module;
+
+ void alert_ruby_error(struct session *ses, unsigned char *msg);
+diff -urp a/src/scripting/ruby/hooks.c b/src/scripting/ruby/hooks.c
+--- a/src/scripting/ruby/hooks.c 2009-07-07 13:23:17.000000000 +0100
++++ b/src/scripting/ruby/hooks.c 2012-09-10 17:53:48.000000000 +0100
+@@ -83,7 +83,7 @@ script_hook_goto_url(va_list ap, void *d
+ {
+ unsigned char *new_url;
+
+- new_url = memacpy(RSTRING(result)->ptr, RSTRING(result)->len);
++ new_url = memacpy(RSTRING_PTR(result), RSTRING_LEN(result));
+ if (new_url) {
+ mem_free_set(url, new_url);
+ }
+@@ -126,7 +126,7 @@ script_hook_follow_url(va_list ap, void
+ {
+ unsigned char *new_url;
+
+- new_url = memacpy(RSTRING(result)->ptr, RSTRING(result)->len);
++ new_url = memacpy(RSTRING_PTR(result), RSTRING_LEN(result));
+ if (new_url) {
+ mem_free_set(url, new_url);
+ }
+@@ -170,9 +170,9 @@ script_hook_pre_format_html(va_list ap,
+ switch (rb_type(result)) {
+ case T_STRING:
+ {
+- int len = RSTRING(result)->len;
++ int len = RSTRING_LEN(result);
+
+- add_fragment(cached, 0, RSTRING(result)->ptr, len);
++ add_fragment(cached, 0, RSTRING_PTR(result), len);
+ normalize_cache_entry(cached, len);
+
+ break;
+@@ -216,7 +216,7 @@ script_hook_get_proxy(va_list ap, void *
+ {
+ unsigned char *proxy;
+
+- proxy = memacpy(RSTRING(result)->ptr, RSTRING(result)->len);
++ proxy = memacpy(RSTRING_PTR(result), RSTRING_LEN(result));
+ if (proxy) {
+ mem_free_set(new_proxy_url, proxy);
+ }
diff --git a/www-client/elinks/files/elinks-0.12_pre5-sm185-jsval-fixes.patch b/www-client/elinks/files/elinks-0.12_pre5-sm185-jsval-fixes.patch
new file mode 100644
index 000000000000..ee2e5e8d633f
--- /dev/null
+++ b/www-client/elinks/files/elinks-0.12_pre5-sm185-jsval-fixes.patch
@@ -0,0 +1,124 @@
+--- a/src/scripting/smjs/action_object.c 2012-06-28 11:46:58.000000000 -0400
++++ b/src/scripting/smjs/action_object.c 2012-06-28 11:52:42.000000000 -0400
+@@ -50,7 +50,7 @@
+ assert(smjs_ctx);
+ if_assert_failed return JS_FALSE;
+
+- value = JS_FALSE;
++ value = JSVAL_FALSE;
+
+ if (JS_TRUE != JS_ValueToObject(ctx, argv[-2], &fn_obj)) {
+ JS_SET_RVAL(ctx, rval, value);
+@@ -76,7 +76,7 @@
+
+ do_action(hop->ses, hop->action_id, 1);
+
+- value = JS_TRUE;
++ value = JSVAL_TRUE;
+ JS_SET_RVAL(ctx, rval, value);
+
+ return JS_TRUE;
+--- a/src/scripting/smjs/bookmarks.c 2012-06-28 11:57:40.000000000 -0400
++++ b/src/scripting/smjs/bookmarks.c 2012-06-28 12:08:20.000000000 -0400
+@@ -250,11 +250,20 @@
+
+ /* @bookmark_folder_class.getProperty */
+ static JSBool
++#if JS_VERSION >= 185
++bookmark_folder_get_property(JSContext *ctx, JSObject *obj, jsid iid, jsval *vp)
++#else
+ bookmark_folder_get_property(JSContext *ctx, JSObject *obj, jsid id, jsval *vp)
++#endif
+ {
+ struct bookmark *bookmark;
+ struct bookmark *folder;
+ unsigned char *title = NULL;
++#if JS_VERSION >= 185
++ jsval id;
++ if (!JS_IdToValue(ctx,iid,&id))
++ return JS_FALSE;
++#endif
+
+ /* This can be called if @obj if not itself an instance of the
+ * appropriate class but has one in its prototype chain. Fail
+--- a/src/scripting/smjs/elinks_object.c 2012-06-28 12:11:15.000000000 -0400
++++ b/src/scripting/smjs/elinks_object.c 2012-06-28 12:14:50.000000000 -0400
+@@ -185,7 +185,7 @@
+ method, rval))
+ return JS_FALSE;
+
+- if (JSVAL_VOID == *rval)
++ if (JSVAL_IS_VOID(*rval))
+ return JS_FALSE;
+
+ return JS_CallFunctionValue(smjs_ctx, smjs_elinks_object,
+--- a/src/scripting/smjs/globhist.c 2012-06-28 12:20:25.000000000 -0400
++++ b/src/scripting/smjs/globhist.c 2012-06-28 12:20:15.000000000 -0400
+@@ -201,11 +201,20 @@
+
+ /* @smjs_globhist_class.getProperty */
+ static JSBool
+-smjs_globhist_get_property(JSContext *ctx, JSObject *obj, jsid id, jsval *vp)
++#if JS_VERSION >= 185
++smjs_globhist_get_property(JSContext *ctx, JSObject *obj, jsid iid, jsval *vp)
++#else
++smjs_globhist_get_property(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
++#endif
+ {
+ JSObject *jsobj;
+ unsigned char *uri_string;
+ struct global_history_item *history_item;
++#if JS_VERSION >= 185
++ jsval id;
++ if (!JS_IdToValue(ctx,iid,&id))
++ return JS_FALSE;
++#endif
+
+ uri_string = JS_EncodeString(ctx, JS_ValueToString(ctx, id));
+ if (!uri_string) goto ret_null;
+--- a/src/scripting/smjs/keybinding.c 2012-06-28 12:21:39.000000000 -0400
++++ b/src/scripting/smjs/keybinding.c.new 2012-06-28 12:48:00.000000000 -0400
+@@ -17,11 +17,20 @@
+
+ /* @keymap_class.getProperty */
+ static JSBool
+-keymap_get_property(JSContext *ctx, JSObject *obj, jsid id, jsval *vp)
++#if JS_VERSION >= 185
++keymap_get_property(JSContext *ctx, JSObject *obj, jsid iid, jsval *vp)
++#else
++keymap_get_property(JSContext *ctx, JSObject *obj, jsval id, jsval *vp)
++#endif
+ {
+ unsigned char *action_str;
+ const unsigned char *keystroke_str;
+ int *data;
++#if JS_VERSION >= 185
++ jsval id;
++ if (!JS_IdToValue(ctx,iid,&id))
++ return JS_FALSE;
++#endif
+
+ /* This can be called if @obj if not itself an instance of the
+ * appropriate class but has one in its prototype chain. Fail
+@@ -70,11 +79,20 @@
+
+ /* @keymap_class.setProperty */
+ static JSBool
+-keymap_set_property(JSContext *ctx, JSObject *obj, jsid id, JSBool strict, jsval *vp)
++#if JS_VERSION >= 185
++keymap_set_property(JSContext *ctx, JSObject *obj, jsid iid, JSBool strict, jsval *vp)
++#else
++keymap_set_property(JSContext *ctx, JSObject *obj, jsval id, JSBool strict, jsval *vp)
++#endif
+ {
+ int *data;
+ unsigned char *keymap_str;
+ const unsigned char *keystroke_str;
++#if JS_VERSION >= 185
++ jsval id;
++ if (!JS_IdToValue(ctx,iid,&id))
++ return JS_FALSE;
++#endif
+
+ /* This can be called if @obj if not itself an instance of the
+ * appropriate class but has one in its prototype chain. Fail
diff --git a/www-client/elinks/files/elinks-0.12pre5-spidermonkey-callback.patch b/www-client/elinks/files/elinks-0.12pre5-spidermonkey-callback.patch
new file mode 100644
index 000000000000..b48ddaeecc47
--- /dev/null
+++ b/www-client/elinks/files/elinks-0.12pre5-spidermonkey-callback.patch
@@ -0,0 +1,12 @@
+diff -Naurp elinks-0.12pre5-orig/src/ecmascript/spidermonkey.c elinks-0.12pre5/src/ecmascript/spidermonkey.c
+--- elinks-0.12pre5-orig/src/ecmascript/spidermonkey.c 2011-06-12 01:03:02.427000686 +0200
++++ elinks-0.12pre5/src/ecmascript/spidermonkey.c 2011-06-12 01:03:31.368000736 +0200
+@@ -130,7 +130,7 @@ setup_safeguard(struct ecmascript_interp
+ JSContext *ctx)
+ {
+ interpreter->exec_start = time(NULL);
+- JS_SetBranchCallback(ctx, safeguard);
++ JS_SetOperationCallback(ctx, safeguard);
+ }
+
+
diff --git a/www-client/elinks/files/elinks-9999-parallel-make.patch b/www-client/elinks/files/elinks-9999-parallel-make.patch
new file mode 100644
index 000000000000..86aea5588a2f
--- /dev/null
+++ b/www-client/elinks/files/elinks-9999-parallel-make.patch
@@ -0,0 +1,51 @@
+--- a/Makefile.lib 2014-05-30 13:45:11.756422117 -0400
++++ b/Makefile.lib 2014-05-30 13:47:22.626423230 -0400
+@@ -117,7 +117,7 @@
+ $(sort $(filter-out $(LIB_O_NAME),$(OBJS))) \
+ $(foreach subdir,$(sort $(SUBDIRS)),$(wildcard $(subdir)/$(LIB_O_NAME)))
+
+-$(LIB_O_NAME): $(LIB_O_DEPS)
++$(LIB_O_NAME): all-recursive.built $(LIB_O_DEPS)
+ $(call cmd,ld_objs)
+
+ DEP_FILES_1 = $(foreach src,$(OBJS),.deps/$(src))
+@@ -260,21 +260,36 @@
+ # remaining subdirectories, but return an error at the end.
+ $(RULES_REC):
+ ifneq (,$(findstring k,$(MAKEFLAGS)))
+- @suberr=0; \
++ @+suberr=0; \
+ $(foreach subdir,$(sort $(SUBDIRS)), \
+ $(call ncmd,recmake,$(subdir),$(subst -recursive,,$@)) || suberr=1;) \
+ exit $$suberr
+ else
+- @$(foreach subdir,$(sort $(SUBDIRS)), \
++ @+$(foreach subdir,$(sort $(SUBDIRS)), \
+ $(call ncmd,recmake,$(subdir),$(subst -recursive,,$@)) || exit 1;)
+ endif
+
++all-recursive.built:
++ifneq (,$(findstring k,$(MAKEFLAGS)))
++ @+suberr=0; \
++ $(foreach subdir,$(sort $(SUBDIRS)), \
++ $(call ncmd,recmake,$(subdir),$(subst -recursive.built,,$@)) || suberr=1;) \
++ [ $$suberr == 0 ] && touch $@; \
++ exit $$suberr
++else
++ @+$(foreach subdir,$(sort $(SUBDIRS)), \
++ $(call ncmd,recmake,$(subdir),$(subst -recursive.built,,$@)) || exit 1;) \
++ touch $@
++endif
++
++CLEAN += all-recursive.built
++
+ # Dummy -local rules
+ $(RULES_LOCAL):
+
+ # Default deps
+ rule_deps = $(1)-recursive $(1)-default $(1)-local
+-all: $(call rule_deps,all)
++all: $(subst recursive,recursive.built,$(call rule_deps,all))
+ install: $(call rule_deps,install)
+ clean: $(call rule_deps,clean)
+ cleanall: $(call rule_deps,cleanall)
diff --git a/www-client/elinks/metadata.xml b/www-client/elinks/metadata.xml
new file mode 100644
index 000000000000..1cb8be95e41b
--- /dev/null
+++ b/www-client/elinks/metadata.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>kondor6c@toshers.org</email>
+ <name>Kevin Faulkner</name>
+ </maintainer>
+ <maintainer type="project">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
+ <use>
+ <flag name="bittorrent">Enable support for the BitTorrent protocol</flag>
+ <flag name="finger">Enable support for the finger protocol</flag>
+ <flag name="gc">Enable garbage collection support via <pkg>dev-libs/boehm-gc</pkg></flag>
+ <flag name="gopher">Enable support for the gopher protocol</flag>
+ <flag name="mouse">Make elinks to grab all mouse events</flag>
+ <flag name="xml">Enable support for bookmarks via <pkg>dev-libs/expat</pkg></flag>
+ </use>
+</pkgmetadata>