--- libtorrent-0.12.6.orig/debian/libtorrent11.install
+++ libtorrent-0.12.6/debian/libtorrent11.install
@@ -0,0 +1 @@
+usr/lib/lib*.so.*
--- libtorrent-0.12.6.orig/debian/compat
+++ libtorrent-0.12.6/debian/compat
@@ -0,0 +1 @@
+5
--- libtorrent-0.12.6.orig/debian/rules
+++ libtorrent-0.12.6/debian/rules
@@ -0,0 +1,21 @@
+#!/usr/bin/make -f
+
+DEB_TAR_SRCDIR = libtorrent-0.12.6
+include /usr/share/cdbs/1/rules/tarball.mk
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/class/autotools.mk
+include /usr/share/cdbs/1/rules/simple-patchsys.mk
+
+architecture:=$(shell dpkg --print-architecture)
+DEB_OPT_FLAG = -W -fno-strict-aliasing
+LDFLAGS = -Wl,--as-needed
+ifeq ($(architecture),arm)
+CXXFLAGS = -O2 -mcpu=xscale -mtune=xscale
+endif
+DEB_CONFIGURE_EXTRA_FLAGS = --enable-aligned
+DEB_DH_INSTALL_SOURCEDIR = debian/tmp
+DEB_INSTALL_DOCS_ALL := --exclude=NEWS
+DEB_INSTALL_CHANGELOGS_ALL := debian/ChangeLog
+
+clean::
+ rm -f *.cdbs-config_list
--- libtorrent-0.12.6.orig/debian/control
+++ libtorrent-0.12.6/debian/control
@@ -0,0 +1,36 @@
+# -*- coding: utf-8 -*-
+Source: libtorrent
+Priority: extra
+Section: libs
+Maintainer: Rogério Brito <rbrito@ime.usp.br>
+DM-Upload-Allowed: yes
+Uploaders: Jose Luis Rivas <ghostbar@debian.org>,
+ Dmitry E. Oboukhov <unera@debian.org>
+Build-Depends: debhelper (>= 5), cdbs, libsigc++-2.0-dev, libcurl4-openssl-dev,
+ libssl-dev
+Standards-Version: 3.8.3
+Vcs-git: git://git.debian.org/git/collab-maint/libtorrent.git
+Vcs-browser: http://git.debian.org/?p=collab-maint/libtorrent.git;a=summary
+Homepage: http://libtorrent.rakshasa.no/
+
+Package: libtorrent-dev
+Section: libdevel
+Architecture: any
+Depends: libtorrent11 (= ${binary:Version}), libsigc++-2.0-dev, ${misc:Depends}
+Description: a C++ BitTorrent library by Rakshasa (development files)
+ LibTorrent is a BitTorrent library written in C++ for *nix. It is
+ designed to avoid redundant copying and storing of data that other
+ clients and libraries suffer from.
+ .
+ This package contains the files needed to compile and link programs
+ which use LibTorrent.
+
+Package: libtorrent11
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Conflicts: libtorrent10, libtorrent9
+Replaces: libtorrent10, libtorrent9
+Description: a C++ BitTorrent library by Rakshasa
+ LibTorrent is a BitTorrent library written in C++ for *nix. It is
+ designed to avoid redundant copying and storing of data that other
+ clients and libraries suffer from.
--- libtorrent-0.12.6.orig/debian/libtorrent-dev.dirs
+++ libtorrent-0.12.6/debian/libtorrent-dev.dirs
@@ -0,0 +1,2 @@
+usr/include
+usr/lib/pkgconfig
--- libtorrent-0.12.6.orig/debian/watch
+++ libtorrent-0.12.6/debian/watch
@@ -0,0 +1,3 @@
+version=3
+opts=dversionmangle=s/\+\w+\d*$// \
+ http://libtorrent.rakshasa.no/downloads/libtorrent-(.*)\.tar\.gz
--- libtorrent-0.12.6.orig/debian/changelog
+++ libtorrent-0.12.6/debian/changelog
@@ -0,0 +1,491 @@
+libtorrent (0.12.6-2) unstable; urgency=low
+
+ * Applied patch to fix "encryption = try_outgoing,enable_retry" option,
+ thanks for Tobias Diedrich <ranma+debianbts@tdiedrich.de>,
+ closes: #561232.
+
+ -- Dmitry E. Oboukhov <unera@debian.org> Fri, 08 Jan 2010 15:18:09 +0300
+
+libtorrent (0.12.6-1) unstable; urgency=low
+
+ * New upstream stable version.
+
+ -- Dmitry E. Oboukhov <unera@debian.org> Tue, 29 Dec 2009 16:26:40 +0300
+
+libtorrent (0.12.5-2) UNRELEASED; urgency=low
+
+ [ Jose Luis Rivas ]
+ * Updated debian/ChangeLog for 0.12.5.
+ * Updated to Standards-Version 3.8.2 wo/ any change needed.
+ [ UNera ]
+ * Added Conflict/Replaces sections for libtorrent11
+
+ -- Dmitry E. Oboukhov <unera@debian.org> Thu, 20 Aug 2009 09:47:43 +0400
+
+libtorrent (0.12.5-1) unstable; urgency=low
+
+ * New upstream version.
+
+ -- Dmitry E. Oboukhov <unera@debian.org> Tue, 30 Jun 2009 11:07:26 +0400
+
+libtorrent (0.12.4+tit-2) unstable; urgency=low
+
+ * Putting myself as the maintainer. Jose told me that he is busy with
+ his duties and he is free to revert this change as he pleases.
+ * Ubuntu people: please contribute your changes! Please.
+ * debian/control: remove recommends of rtorrent in the package
+
+ -- Rogério Brito <rbrito@ime.usp.br> Sun, 17 May 2009 00:51:37 -0300
+
+libtorrent (0.12.4+tit-1) unstable; urgency=low
+
+ * Fixed incorrect merge of previous upload, closes: #527949,
+ this version is really 0.12.4.
+ * Now we use tar-in-tar build system (added +tit as suffix into version).
+
+ -- Dmitry E. Oboukhov <unera@debian.org> Sat, 09 May 2009 20:27:09 +0400
+
+libtorrent (0.12.4-2) unstable; urgency=low
+
+ [ Rogério Brito ]
+ * debian/changelog:
+ + prepare an upload meant to unstable.
+ * debian/copyright:
+ + fix lintian warning regarding versionless link to GPL.
+ * debian/control:
+ + add myself as an uploader (discussed with Jose and Adeodato).
+ + word-wrap the build dependencies field (for more legibility).
+ + include ${misc:Depends} in the binary libtorrent-dev.
+ + include comment at the top of the file (policy 3.8.1 allows it).
+ + update Standards-Version to 3.8.1.
+ * debian/rules:
+ + add --as-needed linker option to reduce library dependencies.
+ + TODO: create a -dbg package.
+ + TODO: create a symbols file.
+ * Notice: the library still doesn't provide symbol files because it
+ seems to export many private symbols. This will be sent upstream (it
+ is better than a Debian specific fix and it has been this way for
+ quite some time now).
+ * more changes to come in the near future.
+ [ Dmitry E. Oboukhov ]
+ * debian/control:
+ + add myself as an uploader.
+
+ -- Dmitry E. Oboukhov <unera@debian.org> Fri, 08 May 2009 20:17:41 +0400
+
+libtorrent (0.12.4-1) experimental; urgency=low
+
+ * New Upstream Version
+ * Updated debian/ChangeLog file.
+ * debian/copyright: Added copyright notice of src/utils/sha_fast.*
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Wed, 19 Nov 2008 13:54:25 -0430
+
+libtorrent (0.12.3-1) experimental; urgency=low
+
+ * New upstream release.
+ * Patches are applied from upstream, deleted.
+ * Updated build-depends and added libcurl4-openssl-dev.
+ * Bumped to 3.8.0 Standards-Version
+ * Bumped libtorrent10 to libtorrent11 by SONAME version.
+ * Refreshed debian/copyright.
+ * Removed Arnaud Andesi from Uploaders.
+ * Removed XS- From Vcs fields and updated these fields.
+ * Updated debian/ChangeLog file.
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Mon, 17 Nov 2008 23:48:01 -0430
+
+libtorrent (0.12.2-1) experimental; urgency=low
+
+ * New upstream release
+ * Deleted debian/patches/update-changelog.patch:
+ + Now is shipped in a plain text file, easier to maintain.
+ * debian/control:
+ + Added "by Rakshasa" to the short description of the package.
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Thu, 08 May 2008 22:51:25 -0430
+
+libtorrent (0.12.1-1) experimental; urgency=low
+
+ * New upstream release.
+ * debian/rules:
+ + Added `-W' flag (Closes: #449214).
+ + Added CXXFLAGS to build with xscale if arch is arm (Closes: #441362).
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Thu, 08 May 2008 21:43:35 -0430
+
+libtorrent (0.11.9-1.1) unstable; urgency=low
+
+ * Non-maintainer upload.
+ * Fix FTBFS with gcc-4.3. (Closes: #420920)
+
+ -- James Vega <jamessan@debian.org> Tue, 15 Apr 2008 21:38:37 -0400
+
+libtorrent (0.11.9-1) unstable; urgency=low
+
+ * New upstream version.
+ * debian/rules:
+ + Removed `-03` flag, CDBS automatically replaces it with `-02`,
+ the memory leak issue was fixed in 0.11.x versions.
+ + Added the exclusion of the doc `NEWS` since there's nothing useful
+ inside. (Closes: #444120)
+ + Added `-fno-strict-aliasing` compilation option because of issue
+ with gcc-4.2.0 that produces segfault. (Closes: #446988)
+ * debian/patches/update-changelog.patch:
+ + Updated with the new changelog.
+ * debian/control:
+ + Updated to Standards-Version 3.7.3, no modifications needed.
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Sun, 16 Dec 2007 19:09:02 -0430
+
+libtorrent (0.11.8-1) unstable; urgency=low
+
+ * New upstream version
+ * debian/patches/update-changelog.patch:
+ + Updated with the new changelog.
+ * debian/control:
+ + Added the Homepage field, deleted Homepages from the descriptions.
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Tue, 11 Sep 2007 15:12:31 -0400
+
+libtorrent (0.11.7-1) unstable; urgency=low
+
+ * New upstream release.
+ * debian/patches/update-changelog.patch:
+ + Updated. (Closes: #432572)
+
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Thu, 16 Aug 2007 18:45:29 -0400
+
+libtorrent (0.11.6-1) unstable; urgency=low
+
+ * New upstream release.
+ * debian/patches/update-changelog.patch:
+ + Updated.
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Tue, 07 Aug 2007 13:48:47 -0400
+
+libtorrent (0.11.5-1) unstable; urgency=low
+
+ * New upstream release
+ * debian/control:
+ + Removed unneeded Replace field. (Closes: #410350)
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Wed, 20 Jun 2007 20:09:21 -0400
+
+libtorrent (0.11.4-1) unstable; urgency=low
+
+ [ Jose Luis Rivas ]
+ * New upstream version.
+ * debian/patches/update-changelog.patch:
+ + Modified to patch the full file.
+ * debian/rules:
+ + Moved patchsys-quilt.mk to simple-patchsys.mk
+ * debian/control:
+ + Removed quilt from Build-Depends.
+
+ [ Arnaud Fontaine ]
+ * debian/control:
+ + Add Build-Depends against patchutils.
+ + Add XS-Vcs-Bzr field.
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Sat, 31 Mar 2007 10:31:05 -0400
+
+libtorrent (0.11.3-1) unstable; urgency=low
+
+ * New upstream release
+ * debian/patches/update-changelog.patch: updated
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Sun, 25 Mar 2007 20:37:30 -0400
+
+libtorrent (0.11.2-1) unstable; urgency=low
+
+ * New upstream release
+ * debian/patches/update-changelog.patch: updated
+ * Removed unneeded conflicts and replaces with libtorrent9 (Closes: #410350)
+
+ -- Jose Luis Rivas <ghostbar@localhost.localdomain> Tue, 20 Mar 2007 23:55:19 -0400
+
+libtorrent (0.11.1-1) unstable; urgency=low
+
+ [ Jose Luis Rivas ]
+ * New upstream release.
+ * Changed name from libtorrent9 to libtorrent10.
+ * Fixed changelog problems (closes: #388841).
+
+ [ Arnaud Fontaine ]
+ * Switch to cdbs.
+ * debian/patches:
+ + Move upstream tarball modifications from diff.gz.
+ * debian/control:
+ + Add the Homepage field.
+ + Add myself as uploader.
+ * debian/compat:
+ + Update to debhelper 5.
+ * debian/copyright:
+ + Add the current maintainers.
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Fri, 29 Dec 2006 01:14:21 -0400
+
+libtorrent (0.10.4-1) unstable; urgency=low
+
+ * New upstream release
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Fri, 27 Oct 2006 22:46:57 -0400
+
+libtorrent (0.10.3-1) unstable; urgency=low
+
+ * New upstream release
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Wed, 18 Oct 2006 22:21:32 -0400
+
+libtorrent (0.10.2-1) unstable; urgency=low
+
+ * New upstream release.
+ * New maintainer.(Closes: #388528)
+ * Updated Build-Depends on `debian/control' to debhelper (>= 5.0.37.2).
+
+ -- Jose Luis Rivas <ghostbar38@gmail.com> Wed, 20 Sep 2006 19:02:10 -0400
+
+libtorrent (0.10.1-1) unstable; urgency=low
+
+ * New upstream release.
+ * Changed soname to libtorrent.so.9, changed binary package names
+ accordingly.
+ * Force alignment by passing --enable-aligned to ./configure.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Tue, 22 Aug 2006 20:49:54 +0100
+
+libtorrent (0.10.0-1) unstable; urgency=low
+
+ * New upstream release.
+ * Changed soname to libtorrent.so.8, changed binary package names
+ accordingly.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Sat, 15 Jul 2006 16:40:29 +0100
+
+libtorrent (0.9.3-1) unstable; urgency=low
+
+ * New upstream release.
+ * Build with g++-4.1.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Sun, 25 Jun 2006 10:06:06 +0100
+
+libtorrent (0.9.1-1) unstable; urgency=low
+
+ * New upstream release.
+ - Added views of the downloads that can be sorted and filtered.
+ The keys '1' to '6' are bound to a set which can be modified with
+ the 'view_*' options. (See man page)
+ - Disconnect incoming connections early if the download is full.
+ (Patch by Josef Drexler)
+ - Made IPv6 and ncursesw configurable, neither of which are actually
+ used yet.
+ - Added a "session_save" option which is scheduled by default every
+ 30 minutes.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Wed, 10 May 2006 21:43:03 +0100
+
+libtorrent (0.9.0-1) unstable; urgency=low
+
+ * New upstream release.
+ - Rewrote the chunk selector with support for rarity-first.
+ - Added scrape information to the tracker list.
+ - The uploaded field in tracker requests get reset every time a
+ torrent is restarted, so buggy trackers don't think the client has
+ uploaded more than it really did.
+ - Show the client names and version in the peer list.
+ - Added "send_buffer_size" and "receive_buffer_size" options that set
+ the socket SND/RCBBUF sizes.
+ - Added signal that allows the client to filter connections based on
+ ip and port. Not implemented in the client yet.
+ - Added "tos = default|lowdelay|throughput|reliability|mincost".
+ - Close torrents with ^K.
+ - Show seen chunks and seeder count with 'i', improved by Josef
+ Drexler.
+ - Added "enable_trackers=yes|no" option that can turn on/off the use
+ of trackers on all torrents.
+ - Re-added 'tracker_dump' option which takes a filename and output
+ better formatted dumps.
+ - A larger number of bugs fixed, minor features and cleanup of the
+ API.
+
+ * Changed soname to libtorrent.so.7, changed binary package names
+ accordingly.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Thu, 6 Apr 2006 23:08:02 +0100
+
+libtorrent (0.8.5-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Thu, 9 Mar 2006 19:28:11 +0000
+
+libtorrent (0.8.4-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Mon, 13 Feb 2006 20:28:42 +0000
+
+libtorrent (0.8.2-1) unstable; urgency=low
+
+ * New upstream release.
+ - Fixed a crash when changing file priorities (Closes: #347429)
+ * Build with g++-3.4, (because rtorrent crashes if built with
+ g++-4.0).
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Thu, 12 Jan 2006 20:47:33 +0000
+
+libtorrent (0.8.1-1) unstable; urgency=low
+
+ * New upstream release (Closes: #344948).
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Wed, 28 Dec 2005 12:46:48 +0000
+
+libtorrent (0.8.0-1) unstable; urgency=low
+
+ * New upstream release.
+ - Changed soname to libtorrent.so.5, changed binary package names
+ accordingly. This also sloves the C++ library rename issue
+ (Closes: #339222).
+ * 0.8.0 has new throttling code, so this throttling bug should be
+ fixed now (Closes: #335176).
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Tue, 6 Dec 2005 22:00:17 +0000
+
+libtorrent (0.7.6-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Tue, 18 Oct 2005 21:28:51 +0100
+
+libtorrent (0.7.5-2) unstable; urgency=low
+
+ * Bug 331256 is actually fixed by upstream 0.7.5 (Closes: #331256).
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Wed, 12 Oct 2005 22:53:34 +0100
+
+libtorrent (0.7.5-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Thu, 29 Sep 2005 19:55:00 +0100
+
+libtorrent (0.7.4-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Wed, 21 Sep 2005 21:27:30 +0100
+
+libtorrent (0.7.3-1) unstable; urgency=low
+
+ * New upstream release.
+ - Changed soname to libtorrent.so.5, changed binary package names
+ accordingly.
+ * Fix FSF address in debian/copyright.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Sun, 4 Sep 2005 15:32:31 +0100
+
+libtorrent (0.7.2-2) unstable; urgency=low
+
+ * Fix a compiling error with regard to std::mem_fun_ref (Thanks
+ Lucas Wall).
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Mon, 22 Aug 2005 21:12:51 +0100
+
+libtorrent (0.7.2-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Thu, 18 Aug 2005 21:19:00 +0100
+
+libtorrent (0.7.1-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Sun, 14 Aug 2005 11:40:38 +0100
+
+libtorrent (0.7.0-2) unstable; urgency=low
+
+ * Apply upstream patch libtorrent-0.7.0-1.diff:
+ - Fixed a bug that gave a 1/16 chance of a torrent messing up
+ the request url by adding an space. This would require the
+ torrent to be removed and re-added to properly connect with
+ the tracker.
+ * Make libtorrent4-dev depends on libsigc++-2.0-dev.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Thu, 28 Jul 2005 21:33:15 +0100
+
+libtorrent (0.7.0-1) unstable; urgency=low
+
+ * New upstream release:
+ - Changed SONAME to libtorrent.so.4.
+ * Changed binary package names to libtorrent4[-dev].
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Sat, 23 Jul 2005 17:24:23 +0100
+
+libtorrent (0.6.7-1) unstable; urgency=low
+
+ * New upstream release.
+ * Use Standards-Version: 3.6.2.
+ * g++ 4.0 transition.
+ * Add libssl-dev to Build-Depends.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Sun, 10 Jul 2005 22:33:52 +0100
+
+libtorrent (0.6.6-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Tue, 28 Jun 2005 21:51:35 +0100
+
+libtorrent (0.6.5-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Thu, 16 Jun 2005 21:02:02 +0100
+
+libtorrent (0.6.4-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Sun, 12 Jun 2005 18:39:26 +0100
+
+libtorrent (0.6.3-1) unstable; urgency=low
+
+ * New upstream release:
+ - Changed SONAME to libtorrent.so.3.
+ * Changed binary package names to libtorrent3[-dev].
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Tue, 31 May 2005 21:55:28 +0100
+
+libtorrent (0.6.2-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Mon, 9 May 2005 21:37:02 +0100
+
+libtorrent (0.6.1-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Mon, 25 Apr 2005 20:57:45 +0100
+
+libtorrent (0.6.0-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Sat, 23 Apr 2005 10:29:29 +0100
+
+libtorrent (0.5.4-1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Thu, 31 Mar 2005 23:19:00 +0100
+
+libtorrent (0.5.2-1) unstable; urgency=low
+
+ * Initial Release. (Closes: #298973)
+
+ -- Qingning Huo <qhuo@mayhq.co.uk> Wed, 16 Mar 2005 21:32:03 +0000
+
--- libtorrent-0.12.6.orig/debian/copyright
+++ libtorrent-0.12.6/debian/copyright
@@ -0,0 +1,73 @@
+Format-Specification:
+ http://wiki.debian.org/Proposals/CopyrightFormat?action=recall&rev=196
+Upstream-Author: Jari Sundell <jaris@ifi.uio.no>
+Packaged-By: Qingning Huo <qhuo@mayhq.co.uk>
+Upstream-Name: LibTorrent
+Original-Source-Location: http://libtorrent.rakshasa.no/
+Original-Source-Command: uscan --force-download
+Original-Source-Depends: devscripts
+
+Files: *
+Copyright: © 2005-2007 Jari Sundell <jaris@ifi.uio.no>
+License: GPL-2+ with a special exception
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this package; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
+
+ In addition, as a special exception, the copyright holders give
+ permission to link the code of portions of this program with the
+ OpenSSL library under certain conditions as described in each
+ individual source file, and distribute linked combinations
+ including the two.
+
+ You must obey the GNU General Public License in all respects for
+ all of the code used other than OpenSSL. If you modify file(s)
+ with this exception, you may extend this exception to your version
+ of the file(s), but you are not obligated to do so. If you do not
+ wish to do so, delete this exception statement from your version.
+ If you delete this exception statement from all source files in the
+ program, then also delete it here.
+
+Files: debian/*
+Copyright: © 2005-2006 Qingning Huo <qhuo@mayhq.co.uk>
+ © 2006-2008 Jose Luis Rivas <ghostbar38@gmail.com>
+License: GPL-2+
+
+Files: src/utils/sha_fast.*
+Copyright: © 1995-1999 by Cryptography Research, Inc.
+License: MPL 1.1 | GPL-2+
+ The contents of this file are subject to the Mozilla Public
+ License Version 1.1 (the "License"); you may not use this file
+ except in compliance with the License. You may obtain a copy of
+ the License at http://www.mozilla.org/MPL/
+
+ Software distributed under the License is distributed on an "AS
+ IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
+ implied. See the License for the specific language governing
+ rights and limitations under the License.
+
+ Alternatively, the contents of this file may be used under the
+ terms of the GNU General Public License Version 2 or later (the
+ "GPL"), in which case the provisions of the GPL are applicable
+ instead of those above. If you wish to allow use of your
+ version of this file only under the terms of the GPL and not to
+ allow others to use your version of this file under the MPL,
+ indicate your decision by deleting the provisions above and
+ replace them with the notice and other provisions required by
+ the GPL. If you do not delete the provisions above, a recipient
+ may use your version of this file under either the MPL or the
+ GPL.
+
+On Debian GNU/Linux systems, the complete text of the GNU General
+Public License can be found in `/usr/share/common-licenses/GPL-2'.
+
--- libtorrent-0.12.6.orig/debian/libtorrent11.dirs
+++ libtorrent-0.12.6/debian/libtorrent11.dirs
@@ -0,0 +1 @@
+usr/lib
--- libtorrent-0.12.6.orig/debian/ChangeLog
+++ libtorrent-0.12.6/debian/ChangeLog
@@ -0,0 +1,511 @@
+2009-06-18 Jari Sundell <sundell.software@gmail.com>
+
+ * Add support for any number of custom download values identified by
+ string keys.
+ d.set_custom=key,value
+ d.get_custom=key (returns "" if not set)
+ d.get_custom_throw=key (returns error if not set)
+
+ * With this patch, rtorrent will detect and complain about .torrent
+ files with broken bencode representation (e.g. where the order of
+ dictionary keys is not lexicographic).
+
+ * Choose a different poll type using the RTORRENT_POLL env. variable
+ (if it's implemented), probably only useful as RTORRENT_POLL=select.
+
+ * Add the commands execute_capture and execute_capture_nothrow that
+ work like their other counterparts but return the OUTPUT (stdout) of
+ the given command.
+
+ * Fixes the code that detects which peer was sending bad data. Peers
+ are then automatically banned after sending three bad chunks.
+
+ * Stops rtorrent from always creating and resizing ALL files, even
+ those set to "off". Files will still be created, but with a size of
+ zero, until a part of them is getting downloaded. This helps with
+ filesystems that don't support sparse files (such as FAT, HFS+, and
+ others).
+
+ * Fix inefficient piece distribution due to linear chunk request
+ strategy by randomizing position every few (on average 32) chunks, see
+ ticket #190.
+
+ * Enable custom throttles, both per-download or per-IP. See
+ http://libtorrent.rakshasa.no/ticket/20 for info and instructions.
+
+ * Fix crashes/errors due to rtorrent attempting to pass non-utf-8
+ strings to xmlrpc.
+
+ * Added support for using posix_fallocate on newly resized files.
+
+ * Include locally available chunks in the "chunks seen" statistics for
+ completed/distributed copies. Patch by Josef Drexler.
+
+ * Added 'd.get_bitfield' command for retrieving the bitfield in hex
+ format. Patch by Thomas Rosner.
+
+ * Fixed include headers for gcc-4.4.0. Patch by 'kloeri'.
+
+2008-11-19 Jari Sundell <sundell.software@gmail.com>
+
+ * Work-around for OpenBSD's broken sys/event.h, which fails to compile
+ if it's the first (or only) included header. (Ticket #1470)
+
+ * Fixes compilation with old libcurl versions. (Ticket #1471)
+
+ * Fix compile error on systems that lack mincore(2).
+
+ * Fixes a crash in epoll due to libcurl/c-ares bug:
+ PollEPoll::modify(...) epoll_ctl call failed.
+
+ * Enforce an http transfer timeout when libcurl fails to honor
+ it. Also set a 5-minute timeout for (previously unlimited) torrent
+ transfers and fixes the argument type for curl_easy_setopt values.
+
+ * Allows bandwidth throttles to work without floating point support.
+
+ * Added the 'd.add_peer=host[:port]' command to manually add a peer
+ (not for torrents marked "private"), port 6881 is the default.
+
+ * Allows banning the selected peer with "B". No unbanning is possible
+ yet.
+
+ All the above patches were written by Josef Drexler.
+
+
+ * Added system.method.{insert,erase} commands that allows
+ user-specified commands. E.g "system.method.insert=foo,print=Bar".
+
+ * Differentiate between commands that have no target, and those that
+ take generic targets, when using XMLRPC.
+
+ * Added 'event.download.inserted_{new,session}' that are triggered
+ when a new or a session torrent is added. Ticket #1516.
+
+ * Added 'system.method.get', 'ui.current_view.set' and 'group.insert'
+ commands.
+
+ * Enabled different ratio settings for different groups of
+ downloads.
+
+ * Added 'view.persistance' command that makes downloads inserted into
+ that view persist across sessions. Only call on user-created views.
+
+ * Added 'ratio.*' commands that call the 'group.seeding.ratio.*'
+ equivalents.
+
+ * Changed torrent::DownloadList::close_directly() so doesn't save the
+ session if the underlying file/directory has been moved or
+ removed. This change, in addition to calling 'd.set_directory=' before
+ 'execute=mv,...', as previously shown in the examples, will make
+ rtorrent behave correctly when 'check_hash=no' is set.
+
+2008-10-15 Jari Sundell <jaris@student.matnat.uiu.no>
+
+ * Added a work-around for the stdin kqueue bug in MacOSX. Original
+ patch by Josef Drexler.
+
+ * Numerous bug-fixes and patches by Josef Drexler.
+
+
+2008-05-13 Jari Sundell <jaris@student.matnat.uio.no>
+
+ * Fixed EINTR handling in execute command. Patch by anonymous.
+
+ * Fixed a couple of memory leaks in xmlrpc.cc. Reported by Novik.
+
+ * Initial seeding support added. Patch by Josef Drexler.
+
+2008-04-29 Jari Sundell <jaris@student.matnat.uio.no>
+
+ * Added {get/set}_xmlrpc_size_limit to allow the user to specify
+ larger buffer size for handling direct loading of torrents through
+ xmlrpc.
+
+ * Allow file and tracker targets with the compact xmlrpc syntax,
+ e.g. "<infohash>:f<id>".
+
+ * Fixed an alignment bug in the DHT code.
+
+ * Replaced View sort and filter code with commands, allowing the user
+ to create custom download list views.
+
+ * Fixed a memory corruption bug in scgi_task.cc.
+
+2008-01-29 Jari Sundell <jaris@student.matnat.uio.no>
+ * Added support for DHT. Patch by Josef Drexler.
+
+ * Cleanup and refactoring of the API.
+
+ * Enable PEX by default.
+
+ * Added 'p.multicall', 'd.set_directory_base',
+ 'get_{up,down}_{rate,total}', and more.
+
+ * Support for lazy creation and resize of file has been added. This also
+ ensures deleted files are properly detected and the user notified. The
+ files can be recreated by using the ^E key.
+
+ * Keep a cache listing all, including failed, torrent loads and the
+ mtimes of those files. This is used to ensure that e.g. the watch dir
+ does not try to load bad/duplicate torrents, in addition to optimizing
+ the pruning of those already loaded.
+
+ * Fixed a crash in apply_on_ratio when an iterator got invalidated by
+ erasing the download currently pointed to.
+
+ * Fixed the --with-xmlrpc-c autoconf check so that you can pass an
+ alternative path to an xmlrpc-c-config script.
+
+ * Fixed a race condition in the handshake read/write code. Patch by
+ Josef Drexler.
+
+ * Fixed a bug causing empty PEX messages to stall piece writing. Patch
+ by Josef Drexler.
+
+2007-10-25 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Improved detection of unnecessary handshakes to decrease
+ the load when using PEX.
+
+ * Limit the number of PEX connections to 8 per download.
+
+ * Fixed several bugs in PEX.
+
+ * Fixed several sigc++ 2.1 compile errors.
+
+ * Print to the log when close_on_diskspace gets triggered.
+
+2007-09-07 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Several new commands for use with XMLRPC. See the SVN log for a
+ complete list.
+
+ * Fixed the wrong tracker requests being sent when finishing a torrent.
+
+ * Added Peer Exchange support, enable with the "peer_exchange=yes"
+ option. Patch by Josef Drexler.
+
+ * Don't skip the last line in rc files missing the final newline. Patch
+ by Jussi Judin.
+
+ * The torrent is no longer closed on finished for on_finished commands
+ as it did last release. Instead d.set_directory causes the download to
+ call close_directly to allow moving of finished torrents.
+
+ * Added "close_on_ratio".
+
+ * Allow commands to be appended to "{stop,close}_on_ratio", so you can
+ e.g. erase a torrent that has finished.
+
+ * Set "encryption=allow_incoming,prefer_plaintext,enable_retry" by
+ default.
+
+2007-08-16 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Renamed all commands to from e.g "get_d_*" to "d.get_*". Remember to
+ update your rc file.
+
+ * Removed support for appending multiple commands to 'schedule'.
+ Multiple commands must now be quoted, e.g "print=cmd1 ;print=cmd2".
+
+ * Enabled 'max_downloads_div' by default. This should give better
+ connection responsiveness if a reasonable download throttle rate is set.
+
+ * Added a default low_diskspace check for 500MB. It is scheduled with
+ the id "low_diskspace".
+
+ * Allow lists as arguments in commands by using '{' and '}'. The list
+ will be recursed and all '$' will be called, while '~' will only be
+ expanded when in the first element in the list. E.g "execute =
+ touch,{~/tmp/,$get_client_version=}".
+
+ * Added 'execute_log' for logging the result of calls to 'execute'.
+
+ * Dynamically sized SCGI read buffer, system.multicall should work
+ properly now.
+
+ * Added 'call_download' that takes a view as the first parameter and
+ then a list of commands. It will return a list of lists containing the
+ results from those commands.
+
+ * Allow loading torrents from https and ftp uri's.
+
+2007-08-01 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Improved XMLRPC support, including support for 64bit ints, removed
+ defective FastCGI support.
+
+ * Added a large number of commands for use with XMLRPC. See
+ system.listMethods for a complete list.
+
+ * Fixed a bug where the tracker re-announce interval for the previous
+ tracker was being used. Now the announce intervals for each tracker is
+ stored seperately.
+
+ * Commands that pass through rpc::parse_command_* now support inline
+ commands that start with a '$'. E.g 'print="$get_ip="'.
+
+ * Allow ';' as a separator for multi-command lines. Not recognized by
+ the string parser, so it must be preceded by whitespace.
+
+ * Allow escaping of newlines in the resource file.
+
+ * The "load_*" commands now allow a list of commands to be appended.
+ These commands will be called on the newly loaded download.
+
+2007-06-20 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * The old option handler has been rewritten.
+
+ * Added support for SCGI rpc calls.
+
+ * Added "http_ca{path/cert}" options. Patch by Johan Gunnarsson
+
+ * Added configure options that allow building universal binaries.
+
+ * Fixed a bug that caused piped requests to be lost.
+
+2007-03-29 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Allow properly quoted and escaped arguments to options. F.ex
+ "schedule = wd,10,10,load_start=~/Foo\ Bar/*.torrent" and "schedule =
+ wd,10,10,load_start="~/Foo Bar/*.torrent"" now works.
+
+ * Added unlimited setting for max unchoked in ChokeManager and made it
+ the default. Set with 0 as a temporary hack.
+
+ * Don't resize empty files used for creating directories. Fixed for the
+ n'th time.
+
+2007-03-25 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Added support for dvorak keyboard layout. Patch by matled at gmx.net.
+
+ * The STOPPED request was being canceled when a download was closed
+ with f.ex ^K, moved it so it only happens when the download is removed.
+
+ * Added support for dvorak keyboard layout. Patch by matled at gmx.net.
+
+ * The STOPPED request was being canceled when a download was closed wit
+ f.ex ^K, moved it so it only happens when the download is removed.
+
+ * The "tos" option was parsing the hex value with unit == 0, which
+ caused it to always zero it.
+
+ * Forgot to check if there were any torrents hashing before starting new
+ non-fast-resume checks, which would cause multiple torrents to be hashed
+ at once.
+
+ * File progress is now updated when hash_check is called, and no longer
+ cleared on close. This fixes a bug with >100% file progress being
+ reported and optimizes file progress updating for completed torrents.
+
+ * Disabled IPv6 http requests so the trackers won't think we support it
+ and enabled curl's support for gzip encodings.
+
+ * Added 'seeding' view on key 8.
+
+ * Added "max_{up,down}loads_{div,global}" options. See the man page for
+ more information.
+
+ * Added support for dvorak keyboard layout. Patch by matled at gmx.net.
+
+ * The STOPPED request was being canceled when a download was closed with
+ f.ex ^K, moved it so it only happens when the download is removed.
+
+2007-01-26 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Added "max_open_http" option that limits the max number of
+ simultaneous http connections. By default set to 32.
+
+ * Directory structured view of the file list. The '/' key collapses
+ directories, while the right arrow or ^F enters the selected directory.
+ Changing the priority for a directory changes all contained files.
+
+ * Replaced old autoconf scripts with pkg-config checks. If the curl or
+ openssl check now fails, make sure pkg-config can find them.
+
+ * Added "create_link" and "delete_link" options which apply to a
+ download. These must be used with the new "on_*" options, so as to
+ allow you to create symbolic links when starting, stopping, finishing,
+ etc, a torrent.
+
+2006-12-28 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Added dired view of files and allow priority to be changed for all
+ files within a directory.
+
+ * Allow initial hash checking to be paused and resumed.
+
+ * Minor bug fixes.
+
+2006-12-13 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Added "tracker_numwant", "encryption", "connection_proxy",
+ 'preload_type', 'preload_min_size', 'preload_required_rate',
+ "split_file_size", "split_suffix", "max_file_size",
+
+ * Encrypted (obfuscated) handshake and connection support. Patch by
+ Josef Drexler, public domain as per earlier agreement.
+
+ * Append '&' instead of '?' to the tracker url when the url already
+ has '?'.
+
+ * Added support for tunneling through HTTP 1.0 proxies.
+
+ * Cut the size of the libtorrent binary from 925kb to 617kb by using
+ GCC's symbol export attributes and changes to how exceptions are
+ constructed.
+
+ * Moved client info, etc, from rtorrent to libtorrent and cleaned up
+ the API.
+
+ * Support for the CANCEL piece request message. (Finally)
+
+ * Allow the user to configure the max file size a torrent is allowed
+ to create, and the option to split large files.
+
+2006-10-27 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * Use the actual completed torrent data in the 'downloaded' field
+ sent to the tracker, rather than the download rate total. This should
+ fix someproblems with too much downloaded data being reported to the
+ tracker.
+
+2004-11-21 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * library: Properly update interested/not interested depending on
+ file priorities.
+
+2004-11-15 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * library: Variable pipe size depending on download speed.
+
+2004-10-27 <jaris@ifi.uio.no>
+
+ * client: On 'T' key, retrive 250 peers from tracker.
+
+ * library: Added tracker numwant and key.
+
+2004-10-02 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * torrent: New class for selecting the chunks to download.
+
+ * client: File priority added.
+
+2004-09-25 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * client: View files in torrent and their size. Will be used for priority later.
+
+2004-09-19 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * all: Forgotten to update this file for a while. Lot's of stuff happen with the code. ;)
+
+ * client: Added resume of torrents and snubbing.
+
+2004-08-23 Jari Petter Sundell <jaris@student.matnat.uio.no>
+
+ * torrent/data: Wrote new and cleaner files to chunk abstraction. Much prettier.
+
+2004-08-14 <jaris@ifi.uio.no>
+
+ * torrent/tracker: New tracker request code. Modular using sigc++
+ and ready for extension.
+
+ * torrent: Moved over to using libcurl for http downloads.
+
+2004-08-07 <jaris@ifi.uio.no>
+
+ * configure: Added sigc++-2.0 to dependencies.
+
+ * torrent/url: Shiny new http interface with sigc++ signals.
+
+2004-08-05 <jaris@ifi.uio.no>
+
+ * client: Added support for http urls.
+
+ * delegator: Fixed a bug that caused us to request pieces the peer
+ didn't have. (DOH!)
+
+2004-08-04 <jaris@ifi.uio.no>
+
+ * bitfield: Clean up bitfield class and opimized .notIn().
+
+ * torrent: Finished http class, testing remains.
+
+2004-08-03 <jaris@ifi.uio.no>
+
+ * torrent: Don't throw on zero length piece messages. Why do they
+ send these?
+
+2004-07-28 <jaris@ifi.uio.no>
+
+ * torrent: Fixed a few bugs in the throttle and added min chunk
+ size.
+
+2004-07-25 <jaris@ifi.uio.no>
+
+ * torrent: Fixed bug that made it skip sending the stop message to
+ the tracker when quiting.
+
+ * torrent: Changed stdint.h to inttypes.h and made it easy to
+ disable execinfo.h in client.
+
+ * torrent: Added throttle with tree structure. Bandwidth
+ delegation needs work.
+
+2004-07-20 <jaris@ifi.uio.no>
+
+ * torrent: Using deque instead of list to increase performance.
+
+ * torrent: Don't close the connection if errno == EINTR.
+
+ * client: Added view of the exceptions log.
+
+2004-07-11 <jaris@ifi.uio.no>
+
+ * torrent: Choosing new chunks to download according to how many
+ we see.
+
+2004-07-10 <jaris@ifi.uio.no>
+
+ * torrent: BitField::allSet() now works right, fixes problems with
+ finished peers not being disconnected.
+
+ * client: No longer breaks when it receives resize interrupts
+ during select.
+
+2004-07-08 <jaris@ifi.uio.no>
+
+ * torrent: Fixed mangling of outgoing commands.
+
+2004-07-07 <jaris@ifi.uio.no>
+
+ * torrent: Cleaned up the BitField class.
+
+ * client: Cleaned up the UI.
+
+2004-07-04 <jaris@ifi.uio.no>
+
+ * client: Added scrolling when selecting peers or downloads. View
+ the local bitfield.
+
+ * torrent: Fixed some unchoking bugs and made it better at
+ choosing whom to unchoke.
+
+2004-06-29 <jaris@ifi.uio.no>
+
+ * torrent: Cleaned up PeerConnection::write and made it buffer
+ more commands in one send.
+
+2004-06-27 <jaris@ifi.uio.no>
+
+ * torrent: Added automatic creation of directories.
+
+ * configure: Added tests for OpenSSL's crypto lib.
+
+2004-06-26 <jaris@ifi.uio.no>
+
+ * client: Made the display code more maintainable. Added chunks
+ seen amongst peers
--- libtorrent-0.12.6.orig/debian/libtorrent-dev.install
+++ libtorrent-0.12.6/debian/libtorrent-dev.install
@@ -0,0 +1,4 @@
+usr/include/*
+usr/lib/lib*.so
+usr/lib/pkgconfig/*
+usr/lib/*.la
--- libtorrent-0.12.6.orig/debian/patches/561232.patch
+++ libtorrent-0.12.6/debian/patches/561232.patch
@@ -0,0 +1,36 @@
+--- build-tree/libtorrent-0.12.6/src/protocol/handshake_manager.cc
++++ build-tree/libtorrent-0.12.6/src/protocol/handshake_manager.cc
+@@ -134,8 +134,12 @@
+
+ void
+ HandshakeManager::create_outgoing(const rak::socket_address& sa, DownloadMain* download, int encryptionOptions) {
++ int peerlist_options = PeerList::connect_keep_handshakes;
++ if (!(encryptionOptions & ConnectionManager::encryption_dont_filter_recent)) {
++ peerlist_options |= PeerList::connect_filter_recent;
++ }
+ PeerInfo* peerInfo = download->peer_list()->connected(sa.c_sockaddr(),
+- PeerList::connect_keep_handshakes | PeerList::connect_filter_recent);
++ peerlist_options);
+
+ if (peerInfo == NULL || peerInfo->failed_counter() > max_failed)
+ return;
+@@ -266,6 +270,7 @@
+ e_none,
+ &download->info()->hash());
+
++ retry_options |= ConnectionManager::encryption_dont_filter_recent;
+ create_outgoing(*sa, download, retry_options);
+ }
+
+--- build-tree/libtorrent-0.12.6/src/torrent/connection_manager.h
++++ build-tree/libtorrent-0.12.6/src/torrent/connection_manager.h
+@@ -86,6 +86,7 @@
+
+ // Internal to libtorrent.
+ static const uint32_t encryption_use_proxy = (1 << 6);
++ static const uint32_t encryption_dont_filter_recent = (1 << 7);
+
+ enum {
+ handshake_incoming = 1,
+
+