commit bffe8fa7b51ac8da083a839fca89f8dee14a45493332c3849933c345f69d4d28 Author: Stephan Kulow Date: Thu May 10 12:33:20 2012 +0000 Accepting request 120544 from devel:libraries:c_c++ resubmit after SR#106185 was turned down due to merge conflicts OBS-URL: https://build.opensuse.org/request/show/120544 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/libtorrent?expand=0&rev=1 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/libtorrent-0.12.2.tar.bz2 b/libtorrent-0.12.2.tar.bz2 new file mode 100644 index 0000000..e666f0a --- /dev/null +++ b/libtorrent-0.12.2.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:310a3d42b828cabd8cdb8fcfb1c737feba26a7e7bd3da0ed9145c04239a5c9b9 +size 411023 diff --git a/libtorrent-decls.diff b/libtorrent-decls.diff new file mode 100644 index 0000000..8ecf62a --- /dev/null +++ b/libtorrent-decls.diff @@ -0,0 +1,87 @@ +From: Jan Engelhardt +Date: 2012-01-31 11:09:58.559664592 +0100 + +Fix build errors regarding unknown snprintf, std::scanf, +ptrdiff_t, NULL. + +--- + src/data/memory_chunk.cc | 1 + + src/protocol/extensions.cc | 1 + + src/torrent/data/block.h | 1 + + src/torrent/data/block_transfer.h | 1 + + src/tracker/tracker_dht.cc | 1 + + src/tracker/tracker_udp.cc | 1 + + 6 files changed, 6 insertions(+) + +Index: libtorrent-0.12.2/src/data/memory_chunk.cc +=================================================================== +--- libtorrent-0.12.2.orig/src/data/memory_chunk.cc ++++ libtorrent-0.12.2/src/data/memory_chunk.cc +@@ -36,6 +36,7 @@ + + #include "config.h" + ++#include + #include + + #include +Index: libtorrent-0.12.2/src/protocol/extensions.cc +=================================================================== +--- libtorrent-0.12.2.orig/src/protocol/extensions.cc ++++ libtorrent-0.12.2/src/protocol/extensions.cc +@@ -36,6 +36,7 @@ + + #include "config.h" + ++#include + #include + #include + +Index: libtorrent-0.12.2/src/torrent/data/block.h +=================================================================== +--- libtorrent-0.12.2.orig/src/torrent/data/block.h ++++ libtorrent-0.12.2/src/torrent/data/block.h +@@ -37,6 +37,7 @@ + #ifndef LIBTORRENT_BLOCK_H + #define LIBTORRENT_BLOCK_H + ++#include + #include + #include + #include +Index: libtorrent-0.12.2/src/torrent/data/block_transfer.h +=================================================================== +--- libtorrent-0.12.2.orig/src/torrent/data/block_transfer.h ++++ libtorrent-0.12.2/src/torrent/data/block_transfer.h +@@ -37,6 +37,7 @@ + #ifndef LIBTORRENT_BLOCK_TRANSFER_H + #define LIBTORRENT_BLOCK_TRANSFER_H + ++#include + #include + #include + +Index: libtorrent-0.12.2/src/tracker/tracker_dht.cc +=================================================================== +--- libtorrent-0.12.2.orig/src/tracker/tracker_dht.cc ++++ libtorrent-0.12.2/src/tracker/tracker_dht.cc +@@ -36,6 +36,7 @@ + + #include "config.h" + ++#include + #include + + #include "dht/dht_router.h" +Index: libtorrent-0.12.2/src/tracker/tracker_udp.cc +=================================================================== +--- libtorrent-0.12.2.orig/src/tracker/tracker_udp.cc ++++ libtorrent-0.12.2/src/tracker/tracker_udp.cc +@@ -36,6 +36,7 @@ + + #include "config.h" + ++#include + #include + #include + diff --git a/libtorrent-gcc4.3-0.12.2.patch b/libtorrent-gcc4.3-0.12.2.patch new file mode 100644 index 0000000..b68d553 --- /dev/null +++ b/libtorrent-gcc4.3-0.12.2.patch @@ -0,0 +1,97 @@ +Index: rak/functional.h +=================================================================== +--- rak/functional.h.orig 2008-05-07 14:19:14.000000000 +0200 ++++ rak/functional.h 2009-05-09 17:00:38.000000000 +0200 +@@ -37,6 +37,7 @@ + #ifndef RAK_FUNCTIONAL_H + #define RAK_FUNCTIONAL_H + ++#include + #include + + namespace rak { +Index: src/data/chunk.cc +=================================================================== +--- src/data/chunk.cc.orig 2008-05-07 14:19:13.000000000 +0200 ++++ src/data/chunk.cc 2009-05-09 17:00:24.000000000 +0200 +@@ -36,6 +36,7 @@ + + #include "config.h" + ++#include + #include + #include + +Index: src/data/chunk_list.h +=================================================================== +--- src/data/chunk_list.h.orig 2008-05-07 14:19:13.000000000 +0200 ++++ src/data/chunk_list.h 2009-05-09 17:01:02.000000000 +0200 +@@ -38,6 +38,7 @@ + #define LIBTORRENT_DATA_CHUNK_LIST_H + + #include ++#include + #include + #include + +Index: src/net/address_list.cc +=================================================================== +--- src/net/address_list.cc.orig 2008-05-07 14:19:12.000000000 +0200 ++++ src/net/address_list.cc 2009-05-09 17:01:29.000000000 +0200 +@@ -36,6 +36,8 @@ + + #include "config.h" + ++#include ++ + #include + + #include "download/download_info.h" // for SocketAddressCompact +Index: src/torrent/data/file_list_iterator.h +=================================================================== +--- src/torrent/data/file_list_iterator.h.orig 2008-05-07 14:19:13.000000000 +0200 ++++ src/torrent/data/file_list_iterator.h 2009-05-09 17:02:03.000000000 +0200 +@@ -37,6 +37,7 @@ + #ifndef LIBTORRENT_FILE_LIST_ITERATOR_H + #define LIBTORRENT_FILE_LIST_ITERATOR_H + ++#include + #include + #include + +Index: src/torrent/exceptions.cc +=================================================================== +--- src/torrent/exceptions.cc.orig 2008-05-07 14:19:13.000000000 +0200 ++++ src/torrent/exceptions.cc 2009-05-09 17:02:28.000000000 +0200 +@@ -37,6 +37,7 @@ + #include "config.h" + + #include ++#include + + #include "exceptions.h" + +Index: src/torrent/tracker_list.h +=================================================================== +--- src/torrent/tracker_list.h.orig 2008-05-07 14:19:13.000000000 +0200 ++++ src/torrent/tracker_list.h 2009-05-09 17:02:51.000000000 +0200 +@@ -38,6 +38,7 @@ + #define LIBTORRENT_TRACKER_LIST_H + + #include ++#include + #include + #include + +Index: src/utils/diffie_hellman.cc +=================================================================== +--- src/utils/diffie_hellman.cc.orig 2008-05-07 14:19:12.000000000 +0200 ++++ src/utils/diffie_hellman.cc 2009-05-09 17:03:16.000000000 +0200 +@@ -36,6 +36,7 @@ + + #include "config.h" + ++#include + #include + + #ifdef USE_OPENSSL diff --git a/libtorrent.changes b/libtorrent.changes new file mode 100644 index 0000000..2d6b23e --- /dev/null +++ b/libtorrent.changes @@ -0,0 +1,25 @@ +------------------------------------------------------------------- +Wed Mar 7 09:29:56 UTC 2012 - cfarrell@suse.com + +- license update: SUSE-GPL-2.0+-with-openssl-exception + Package allows linking against openSSL. Use the SUSE- proprietary prefix + until upstream spdx.org accepts the linking exception + +------------------------------------------------------------------- +Tue Feb 21 01:23:04 UTC 2012 - jengelh@medozas.de + +- Run format_spec_file to please the automatic factory + pre-checkin checker scripts + +------------------------------------------------------------------- +Tue Jan 31 09:59:10 UTC 2012 - jengelh@medozas.de + +- Remove redundant tags/sections per specfile guideline suggestions +- Parallel building using %_smp_mflags +- New patch libtorrent-decls.diff: add missing includes to + fix build errors + +------------------------------------------------------------------- +Sat May 9 00:00:00 UTC 2009 - bitshuffler#suse@irc.freenode.org + +- Initial RPM diff --git a/libtorrent.spec b/libtorrent.spec new file mode 100644 index 0000000..6bcc9b1 --- /dev/null +++ b/libtorrent.spec @@ -0,0 +1,80 @@ +# +# spec file for package libtorrent +# +# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# +%define soname 9 + +Name: libtorrent +Version: 0.12.2 +Release: 1.0 +Url: http://libtorrent.rakshasa.no/ +Source: %{name}-%{version}.tar.bz2 +Patch1: libtorrent-gcc4.3-0.12.2.patch +Patch2: libtorrent-decls.diff +BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: gcc-c++ +BuildRequires: libsigc++2-devel +BuildRequires: openssl-devel +BuildRequires: pkg-config +Summary: A BitTorrent library written in C++ for *nix +License: SUSE-GPL-2.0+-with-openssl-exception +Group: Productivity/Networking/File Sharing + +%description +LibTorrent is a BitTorrent library written in C++ for *nix, with a focus on high performance and good code. The library differentiates itself from other implementations by transfering directly from file pages to the network stack. On high-bandwidth connections it is able to seed at 3 times the speed of the official client. + +%package -n %{name}%{soname} +Summary: A BitTorrent library written in C++ for *nix +Group: System/Libraries + +%description -n %{name}%{soname} +LibTorrent is a BitTorrent library written in C++ for *nix, with a focus on high performance and good code. The library differentiates itself from other implementations by transfering directly from file pages to the network stack. On high-bandwidth connections it is able to seed at 3 times the speed of the official client. + +%package -n %{name}-devel +Requires: %{name}%{soname} = %{version} +Summary: A BitTorrent library written in C++ for *nix +Group: Development/Libraries/C and C++ + +%description -n %{name}-devel +LibTorrent is a BitTorrent library written in C++ for *nix, with a focus on high performance and good code. The library differentiates itself from other implementations by transfering directly from file pages to the network stack. On high-bandwidth connections it is able to seed at 3 times the speed of the official client. + +%prep +%setup -q +%patch -P 1 -p0 +%patch -P 2 -p1 + +%build +%configure --enable-ipv6 --with-posix-fallocate +make %{?_smp_mflags} + +%install +%makeinstall +find "%{buildroot}" -type f -name "*.la" -delete + +%post -n %{name}%{soname} -p /sbin/ldconfig + +%postun -n %{name}%{soname} -p /sbin/ldconfig + +%files -n %{name}%{soname} +%defattr(-,root,root) +%{_libdir}/%{name}.so.%{soname}* + +%files -n %{name}-devel +%defattr(-,root,root) +%{_includedir}/torrent +%{_libdir}/%{name}.so +%{_libdir}/pkgconfig/libtorrent.pc + +%changelog