Accepting request 348685 from home:Dremor:branches:devel:libraries:c_c++

Adding Python3 support to Boost (boo#951902) . This should cause any compatibility issues, as the new library and the python2 library have different sonames.
I've split python support into 2 package. The old one have the Python2 library, the new one have the Python3 one.

OBS-URL: https://build.opensuse.org/request/show/348685
OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/boost?expand=0&rev=156
This commit is contained in:
Ismail Dönmez 2015-12-13 17:12:24 +00:00 committed by Git OBS Bridge
parent f7b7cf010e
commit 591d482b53
2 changed files with 36 additions and 1 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Sun Dec 13 15:31:10 UTC 2015 - egeorget@openmailbox.org
- Add support to Boost:Python3 (boo#951902)
* New library: python3
-------------------------------------------------------------------
Tue Dec 8 15:52:49 CET 2015 - pth@suse.de

View File

@ -94,6 +94,7 @@ BuildRequires: libbz2-devel
BuildRequires: libexpat-devel
BuildRequires: libicu-devel >= 4.4
BuildRequires: python-devel
BuildRequires: python3-devel
#!BuildIgnore: python
BuildRequires: zlib-devel
Recommends: %{all_libs}
@ -311,6 +312,14 @@ Requires: boost-license%{lib_appendix}
%description -n libboost_python%{lib_appendix}
This package contains the Boost::Python Runtime libraries.
%package -n libboost_python3-%{lib_appendix}
Summary: Boost::Python Runtime Libraries
Group: System/Libraries
Requires: boost-license%{lib_appendix}
%description -n libboost_python3-%{lib_appendix}
This package contains the Boost::Python3 Runtime libraries.
%package -n libboost_serialization%{lib_appendix}
Summary: Boost::Serialization Runtime Libraries
Group: System/Libraries
@ -458,6 +467,8 @@ export LONG_DOUBLE_FLAGS="--disable-long-double"
%endif
BJAM_CONFIG="-d2 -j$JOBS -sICU_PATH=%{_prefix}"
PYTHON_VERSION=$(python -c 'import sys; print sys.version[:3]')
PYTHON3_VERSION=$(python3 -c 'import sys; print (sys.version[:3])')
PYTHON3_INCLUDE=m
PYTHON_FLAGS="--with-python-root=%{_prefix} --with-python-version=$PYTHON_VERSION"
export REGEX_FLAGS="--with-icu"
export EXPAT_INCLUDE=%{_includedir} EXPAT_LIBPATH=%{_libdir}
@ -488,6 +499,16 @@ import os ;
local RPM_OPT_FLAGS = [ os.environ RPM_OPT_FLAGS ] ;
using gcc : : : <compileflags>\$(RPM_OPT_FLAGS) ;
using python
: $PYTHON3_VERSION
: /usr/bin/python$PYTHON3_VERSION
: /usr/include/python$PYTHON3_VERSION$PYTHON3_INCLUDE
: /usr/lib/python$PYTHON3_VERSION
:
:
;
EOF
%if %{build_docs}
@ -611,6 +632,8 @@ install -m 0755 dist/bin/quickbook %{buildroot}%{_bindir}/quickbook
%post -n libboost_python%{lib_appendix} -p /sbin/ldconfig
%post -n libboost_python3-%{lib_appendix} -p /sbin/ldconfig
%post -n libboost_regex%{lib_appendix} -p /sbin/ldconfig
%post -n libboost_serialization%{lib_appendix} -p /sbin/ldconfig
@ -662,6 +685,8 @@ install -m 0755 dist/bin/quickbook %{buildroot}%{_bindir}/quickbook
%postun -n libboost_python%{lib_appendix} -p /sbin/ldconfig
%postun -n libboost_python3-%{lib_appendix} -p /sbin/ldconfig
%postun -n libboost_regex%{lib_appendix} -p /sbin/ldconfig
%postun -n libboost_serialization%{lib_appendix} -p /sbin/ldconfig
@ -759,7 +784,11 @@ install -m 0755 dist/bin/quickbook %{buildroot}%{_bindir}/quickbook
%files -n libboost_python%{lib_appendix}
%defattr(-, root, root, -)
%{_libdir}/libboost_python*.so.*
%{_libdir}/libboost_python.so.*
%files -n libboost_python3-%{lib_appendix}
%defattr(-, root, root, -)
%{_libdir}/libboost_python3.so.*
%files -n libboost_serialization%{lib_appendix}
%defattr(-, root, root, -)