1
0
Alexei Sorokin
2016-12-05 16:01:01 +00:00
committed by Git OBS Bridge
parent fcf143d185
commit 399adb9c9c
4 changed files with 45 additions and 5 deletions

View File

@@ -0,0 +1,11 @@
--- a/src/lsd.cpp
+++ b/src/lsd.cpp
@@ -87,7 +87,7 @@ lsd::lsd(io_service& ios, peer_callback_
, m_log_cb(log)
#endif
, m_broadcast_timer(ios)
- , m_cookie((random() ^ boost::uintptr_t(this)) & 0x7fffffff)
+ , m_cookie((random() ^ std::uintptr_t(this)) & 0x7fffffff)
, m_disabled(false)
#if TORRENT_USE_IPV6
, m_disabled6(false)

View File

@@ -0,0 +1,14 @@
--- a/bindings/python/setup.py
+++ b/bindings/python/setup.py
@@ -116,6 +116,11 @@ else:
extra_link = flags.parse(ldflags)
extra_compile = flags.parse(extra_cmd)
+ if 'CXX' in os.environ:
+ os.environ['CC'] = os.environ['CXX']
+ if 'CXXFLAGS' in os.environ:
+ os.environ['CFLAGS'] = os.environ['CXXFLAGS']
+
ext = [Extension('libtorrent',
sources = source_list,
language='c++',

View File

@@ -1,3 +1,12 @@
-------------------------------------------------------------------
Mon Dec 5 15:43:14 UTC 2016 - sor.alexei@meowr.ru
- Require boost 1.54+ instead of 1.61+ again.
- Add libtorrent-rasterbar-fix-build-boost-1.54.patch: Fix
building with Boost 1.54.
- Add libtorrent-rasterbar-python-cxxflags.patch: Fix Python
bindings crash with non-default C++11 (boo#1013570).
-------------------------------------------------------------------
Mon Oct 10 18:48:42 UTC 2016 - fisiu@opensuse.org

View File

@@ -29,7 +29,11 @@ License: BSD-3-Clause
Group: Development/Libraries/C and C++
Url: http://libtorrent.org/
Source: https://github.com/arvidn/%{_name}/releases/download/%{_name}-%{_version}/%{name}-%{version}.tar.gz
BuildRequires: boost-devel >= 1.61
# PATCH-FIX-UPSTREAM libtorrent-rasterbar-fix-build-boost-1.54.patch sor.alexei@meowr.ru -- Fix building with Boost 1.54.
Patch0: libtorrent-rasterbar-fix-build-boost-1.54.patch
# PATCH-FIX-OPENSUSE libtorrent-rasterbar-python-cxxflags.patch boo#1013570 sor.alexei@meowr.ru -- Fix Python bindings CXXFLAGS.
Patch1: libtorrent-rasterbar-python-cxxflags.patch
BuildRequires: boost-devel >= 1.54
BuildRequires: gcc-c++
BuildRequires: pkgconfig
BuildRequires: python-devel
@@ -99,7 +103,7 @@ Example tools from the libtorrent-rasterbar package.
Summary: Libtorrent is a C++ implementation of the BitTorrent protocol
Group: Development/Libraries/C and C++
Requires: %{name}%{sover} = %{version}
Requires: boost-devel >= 1.53
Requires: boost-devel >= 1.54
Requires: gcc-c++
Requires: pkgconfig(openssl)
@@ -125,6 +129,8 @@ Documentation for the libtorrent-rasterbar package.
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%build
export CFLAGS="%{optflags} -fno-strict-aliasing"
@@ -158,7 +164,7 @@ for py in python; do
%endif
--with-boost-python="libboost_$py" \
--enable-python-binding
make %{?_smp_mflags}
make %{?_smp_mflags} V=1
popd
done
@@ -182,9 +188,9 @@ rm -v %{buildroot}%{_bindir}/{client_test,connection_tester,enum_if} \
%if %{with tests}
%check
make check %{?_smp_mflags} -C build-python
make check %{?_smp_mflags} V=1 -C build-python
%if 0%{?suse_version} > 1320
make check %{?_smp_mflags} -C build-python3
make check %{?_smp_mflags} V=1 -C build-python3
%endif
%endif