Added patch to fix bittorrent exception issue (thanks to Daniel Lange).
authorTiziano Müller <dev-zero@gentoo.org>
Wed, 10 Jan 2007 21:30:46 +0000 (21:30 +0000)
committerTiziano Müller <dev-zero@gentoo.org>
Wed, 10 Jan 2007 21:30:46 +0000 (21:30 +0000)
Package-Manager: portage-2.1.2_rc4-r1

net-misc/aria2/ChangeLog
net-misc/aria2/aria2-0.9.0-r1.ebuild [new file with mode: 0644]
net-misc/aria2/files/aria2-0.9.0-isalpha_exception.patch [new file with mode: 0644]
net-misc/aria2/files/digest-aria2-0.9.0-r1 [new file with mode: 0644]

index a7fc1f364d24c5712c67233d5780f3e38fb94624..0b22a0a14c6638d1efd88e79be585dd3f8659003 100644 (file)
@@ -1,6 +1,13 @@
 # ChangeLog for net-misc/aria2
 # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/aria2/ChangeLog,v 1.9 2007/01/06 11:11:08 dev-zero Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/aria2/ChangeLog,v 1.10 2007/01/10 21:30:45 dev-zero Exp $
+
+*aria2-0.9.0-r1 (10 Jan 2007)
+
+  10 Jan 2007; Tiziano Müller <dev-zero@gentoo.org>
+  +files/aria2-0.9.0-isalpha_exception.patch, -aria2-0.9.0.ebuild,
+  +aria2-0.9.0-r1.ebuild:
+  Added patch to fix bittorrent exception issue (thanks to Daniel Lange).
 
   06 Jan 2007; Tiziano Müller <dev-zero@gentoo.org> -aria2-0.8.1.ebuild:
   Dropped old version
diff --git a/net-misc/aria2/aria2-0.9.0-r1.ebuild b/net-misc/aria2/aria2-0.9.0-r1.ebuild
new file mode 100644 (file)
index 0000000..5ef32f8
--- /dev/null
@@ -0,0 +1,58 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/aria2/aria2-0.9.0-r1.ebuild,v 1.1 2007/01/10 21:30:45 dev-zero Exp $
+
+inherit eutils
+
+KEYWORDS="~amd64 ~ppc ~ppc64 ~sparc ~x86"
+
+DESCRIPTION="A download utility with resuming and segmented downloading with HTTP/HTTPS/FTP/BitTorrent support."
+HOMEPAGE="http://aria2.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="ares bittorrent gnutls metalink nls ssl"
+
+# Tests are still broken
+RESTRICT="test"
+
+CDEPEND="ssl? (
+               gnutls? ( net-libs/gnutls )
+               !gnutls? ( dev-libs/openssl ) )
+       ares? ( >=net-dns/c-ares-1.3.1 )
+       bittorrent? ( gnutls? ( dev-libs/libgcrypt ) )
+       metalink? ( >=dev-libs/libxml2-2.6.26 )"
+DEPEND="${CDEPEND}
+       nls? ( sys-devel/gettext )"
+RDEPEND="${CDEPEND}
+       nls? ( virtual/libiconv virtual/libintl )"
+
+src_unpack() {
+       unpack ${A}
+       cd "${S}"
+       epatch "${FILESDIR}/${P}-isalpha_exception.patch"
+}
+
+src_compile() {
+       use ssl && \
+               myconf="${myconf} $(use_with gnutls) $(use_with !gnutls openssl)"
+
+       # Note:
+       # - we don't have ares, only libcares
+       # - depends on libgcrypt only when using openssl
+       econf \
+               $(use_enable nls) \
+               $(use_enable metalink) \
+               $(use_enable bittorrent) \
+               --without-ares \
+               $(use_with ares libcares) \
+               $(use_with metalink libxml2) \
+               ${myconf} \
+               || die "econf failed"
+       emake || die "emake failed"
+}
+
+src_install() {
+       emake DESTDIR="${D}" install || die "emake install failed"
+       dodoc ChangeLog README AUTHORS TODO NEWS
+}
diff --git a/net-misc/aria2/files/aria2-0.9.0-isalpha_exception.patch b/net-misc/aria2/files/aria2-0.9.0-isalpha_exception.patch
new file mode 100644 (file)
index 0000000..2c0b7d8
--- /dev/null
@@ -0,0 +1,23 @@
+*** aria2-0.9.0/src/Util.cc    2006-11-06 00:04:17.000000000 +0900
+--- aria2-0.9.0+1/src/Util.cc  2007-01-11 01:55:24.000000000 +0900
+***************
+*** 213,219 ****
+  string Util::torrentUrlencode(const unsigned char* target, int len) {
+    string dest;
+    for(int i = 0; i < len; i++) {
+!     if(isalpha(target[i]) || isdigit(target[i])) {
+        dest += target[i];
+      } else {
+        char temp[4];
+--- 213,221 ----
+  string Util::torrentUrlencode(const unsigned char* target, int len) {
+    string dest;
+    for(int i = 0; i < len; i++) {
+!     if('0' <= target[i] && target[i] <= '9' ||
+!        'A' <= target[i] && target[i] <= 'Z' ||
+!        'a' <= target[i] && target[i] <= 'z') {
+        dest += target[i];
+      } else {
+        char temp[4];
+
+                
diff --git a/net-misc/aria2/files/digest-aria2-0.9.0-r1 b/net-misc/aria2/files/digest-aria2-0.9.0-r1
new file mode 100644 (file)
index 0000000..768cf87
--- /dev/null
@@ -0,0 +1,3 @@
+MD5 f4d1e1761ee2386e5d3a6248b363267f aria2-0.9.0.tar.bz2 405772
+RMD160 3560d8f49ebc8e74f189fe520166d1e340025b2c aria2-0.9.0.tar.bz2 405772
+SHA256 65a51bfd371b78bcf1704b5754b52bfc0468aec5e218ee44cbdd9d5efcc346a6 aria2-0.9.0.tar.bz2 405772