python-boost-py3: don't obsolete python3-boost provided by legacy package [release 1.71.0-5mamba;Mon Dec 23 2019]
This commit is contained in:
parent
d82b943b28
commit
a501656768
140
libboost.spec
140
libboost.spec
@ -2,7 +2,7 @@
|
||||
%define pckmajver %(echo %version | cut -d. -f1-2 | tr . _)
|
||||
Name: libboost
|
||||
Version: 1.71.0
|
||||
Release: 3mamba
|
||||
Release: 5mamba
|
||||
Summary: Free peer-reviewed portable C++ source libraries
|
||||
Group: System/Libraries
|
||||
Vendor: openmamba
|
||||
@ -24,8 +24,12 @@ BuildRequires: libstdc++6-devel
|
||||
BuildRequires: libz-devel
|
||||
## AUTOBUILDREQ-END
|
||||
BuildRequires: libicu-devel >= 54
|
||||
BuildRequires: python-devel >= 2.3.3
|
||||
BuildRequires: python3-devel
|
||||
BuildRequires: libpython27-devel
|
||||
BuildRequires: libpython3-devel
|
||||
BuildRequires: libpython36-devel
|
||||
BuildRequires: python-numpy
|
||||
BuildRequires: python-numpy-py3
|
||||
BuildRequires: python-numpy-py36
|
||||
BuildRequires: boost-jam
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot
|
||||
|
||||
@ -41,10 +45,11 @@ Ten Boost libraries will be included in the C++ Standards Committee's upcoming C
|
||||
Group: Development/Libraries
|
||||
Summary: Devel package for libboost
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
Requires: python27-boost = %{version}-%{release}
|
||||
Requires: python3-boost = %{version}-%{release}
|
||||
Provides: python-boost-devel
|
||||
Obsoletes: python-boost-devel
|
||||
Requires: python-boost-py27 = %{?epoch:%epoch:}%{version}-%{release}
|
||||
Requires: python-boost-py3 = %{?epoch:%epoch:}%{version}-%{release}
|
||||
Requires: python-boost-py36 = %{?epoch:%epoch:}%{version}-%{release}
|
||||
|
||||
%description devel
|
||||
The Boost libraries provide free peer-reviewed portable C++ source libraries.
|
||||
@ -56,14 +61,16 @@ Ten Boost libraries will be included in the C++ Standards Committee's upcoming C
|
||||
|
||||
This is the devel package.
|
||||
|
||||
%package -n python27-boost
|
||||
%package -n python-boost-py27
|
||||
Group: System/Libraries
|
||||
Summary: Boost.Python library for Python 2.7
|
||||
Provides: libboost-python
|
||||
Obsoletes: libboost-python
|
||||
Provides: python27-boost
|
||||
Obsoletes: python27-boost
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
|
||||
%description -n python27-boost
|
||||
%description -n python-boost-py27
|
||||
The Boost libraries provides free peer-reviewed portable C++ source libraries.
|
||||
The emphasis is on libraries which work well with the C++ Standard Library.
|
||||
The libraries are intended to be widely useful, and are in regular use by thousands of programmers across a broad spectrum of applications.
|
||||
@ -73,12 +80,12 @@ Ten Boost libraries will be included in the C++ Standards Committee's upcoming C
|
||||
|
||||
This package contains then Boost.python library
|
||||
|
||||
%package -n python3-boost
|
||||
%package -n python-boost-py3
|
||||
Group: System/Libraries
|
||||
Summary: Boost.Python library for Python 3
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
|
||||
%description -n python3-boost
|
||||
%description -n python-boost-py3
|
||||
The Boost libraries provides free peer-reviewed portable C++ source libraries.
|
||||
The emphasis is on libraries which work well with the C++ Standard Library.
|
||||
The libraries are intended to be widely useful, and are in regular use by thousands of programmers across a broad spectrum of applications.
|
||||
@ -88,18 +95,37 @@ Ten Boost libraries will be included in the C++ Standards Committee's upcoming C
|
||||
|
||||
This package contains then Boost.python library for Python 3.
|
||||
|
||||
%package -n python-boost-py36
|
||||
Group: System/Libraries
|
||||
Summary: Boost.Python library for Python 3.6
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
|
||||
%description -n python-boost-py36
|
||||
The Boost libraries provides free peer-reviewed portable C++ source libraries.
|
||||
The emphasis is on libraries which work well with the C++ Standard Library.
|
||||
The libraries are intended to be widely useful, and are in regular use by thousands of programmers across a broad spectrum of applications.
|
||||
|
||||
A further goal is to establish "existing practice" and provide reference implementations so that Boost libraries are suitable for eventual standardization.
|
||||
Ten Boost libraries will be included in the C++ Standards Committee's upcoming C++ Standard Library Technical Report as a step toward becoming part of a future C++ Standard.
|
||||
|
||||
This package contains then Boost.python library for Python 3.6.
|
||||
|
||||
|
||||
%debug_package
|
||||
|
||||
%prep
|
||||
%setup -q -n boost_%{pckver} -a0 -D -T
|
||||
:<< _EOF
|
||||
|
||||
%setup -q -n boost_%{pckver} -a0
|
||||
#-D -T
|
||||
#:<< _EOF
|
||||
mv boost_%{pckver} boost_python
|
||||
|
||||
cp -a boost_python boost_python36
|
||||
|
||||
#%patch0 -p1
|
||||
#%patch1 -p1
|
||||
|
||||
%build
|
||||
:<< _EOF
|
||||
#:<< _EOF
|
||||
# Build boost with python3
|
||||
./bootstrap.sh \
|
||||
--with-icu \
|
||||
@ -114,6 +140,7 @@ EXPAT_LIBPATH=%{_libdir} \
|
||||
./b2 \
|
||||
--prefix=%{_prefix} \
|
||||
--layout=system -d2 \
|
||||
python=3.7 \
|
||||
runtime-link=shared \
|
||||
link=shared,static \
|
||||
toolset=gcc \
|
||||
@ -141,6 +168,7 @@ EXPAT_LIBPATH=%{_libdir} \
|
||||
-a \
|
||||
--prefix=%{_prefix} \
|
||||
--layout=system -d2 \
|
||||
python=2.7 \
|
||||
runtime-link=shared \
|
||||
link=shared,static \
|
||||
toolset=gcc \
|
||||
@ -152,6 +180,36 @@ EXPAT_LIBPATH=%{_libdir} \
|
||||
cflags="-fPIC"
|
||||
%endif
|
||||
|
||||
cd ../boost_python36
|
||||
# Rebuild boost with Python 3.6
|
||||
rm -f user-config.jam
|
||||
|
||||
./bootstrap.sh \
|
||||
--with-icu \
|
||||
--with-python-root=%{_prefix} \
|
||||
--with-python-version=%{python36_version} \
|
||||
--with-libraries=python
|
||||
|
||||
sed -i "s|using python.*|using python : %{python36_version} : %{_prefix} : %{python36_inc} ;|" project-config.jam
|
||||
echo "using mpi ;" >> project-config.jam
|
||||
|
||||
EXPAT_INCLUDE=%{_includedir} \
|
||||
EXPAT_LIBPATH=%{_libdir} \
|
||||
./b2 \
|
||||
-a \
|
||||
--prefix=%{_prefix} \
|
||||
--layout=system -d2 \
|
||||
python=3.6 \
|
||||
runtime-link=shared \
|
||||
link=shared,static \
|
||||
toolset=gcc \
|
||||
variant=release \
|
||||
threading=multi \
|
||||
debug-symbols=on \
|
||||
stage \
|
||||
%ifarch x86_64
|
||||
cflags="-fPIC"
|
||||
%endif
|
||||
|
||||
%install
|
||||
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
||||
@ -163,6 +221,7 @@ EXPAT_LIBPATH=%{_libdir} \
|
||||
--execprefix=%{buildroot}%{_libexecdir} \
|
||||
--includedir=%{buildroot}%{_includedir} \
|
||||
--layout=system -d2 \
|
||||
python=3.7 \
|
||||
runtime-link=shared \
|
||||
link=shared,static \
|
||||
toolset=gcc \
|
||||
@ -180,6 +239,7 @@ EXPAT_LIBPATH=%{_libdir} \
|
||||
--execprefix=%{buildroot}%{_libexecdir} \
|
||||
--includedir=%{buildroot}%{_includedir} \
|
||||
--layout=system -d2 \
|
||||
python=2.7 \
|
||||
runtime-link=shared \
|
||||
link=shared,static \
|
||||
toolset=gcc \
|
||||
@ -188,17 +248,29 @@ EXPAT_LIBPATH=%{_libdir} \
|
||||
debug-symbols=on \
|
||||
install
|
||||
|
||||
#cp stage/lib/libboost_python.* %{buildroot}%{_libdir}/
|
||||
#cp stage/lib/libboost_python-mt.* %{buildroot}%{_libdir}/
|
||||
cd ../boost_python36
|
||||
EXPAT_INCLUDE=%{_includedir} \
|
||||
EXPAT_LIBPATH=%{_libdir} \
|
||||
./b2 \
|
||||
--prefix=%{buildroot}%{_prefix} \
|
||||
--libdir=%{buildroot}%{_libdir} \
|
||||
--execprefix=%{buildroot}%{_libexecdir} \
|
||||
--includedir=%{buildroot}%{_includedir} \
|
||||
--layout=system -d2 \
|
||||
python=3.6 \
|
||||
runtime-link=shared \
|
||||
link=shared,static \
|
||||
toolset=gcc \
|
||||
variant=release \
|
||||
threading=multi \
|
||||
debug-symbols=on \
|
||||
install
|
||||
|
||||
#for f in %{buildroot}%{_libdir}/libboost_*-mt.so; do
|
||||
# mv $f ${f/-mt}.%{version}
|
||||
# ln -s `basename ${f/-mt}.%{version}` ${f/-mt}
|
||||
#done
|
||||
|
||||
#for f in %{buildroot}%{_libdir}/libboost_*-mt.a; do
|
||||
# mv $f ${f/-mt}
|
||||
#done
|
||||
# https://github.com/boostorg/python/issues/203#issuecomment-391477685
|
||||
for _lib in python numpy; do
|
||||
ln -srL %{buildroot}%{_libdir}/libboost_${_lib}{27,}.so
|
||||
ln -srL %{buildroot}%{_libdir}/libboost_${_lib}3{7,}.so
|
||||
done
|
||||
|
||||
%clean
|
||||
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
||||
@ -259,18 +331,34 @@ EXPAT_LIBPATH=%{_libdir} \
|
||||
%{_libdir}/cmake/Boost*.cmake
|
||||
%{_libdir}/cmake/boost_*/*.cmake
|
||||
|
||||
%files -n python27-boost
|
||||
%files -n python-boost-py27
|
||||
%defattr(-,root,root)
|
||||
%ifnarch arm
|
||||
%{_libdir}/libboost_numpy27.so.*
|
||||
%endif
|
||||
%{_libdir}/libboost_python27*.so.*
|
||||
|
||||
%files -n python3-boost
|
||||
%files -n python-boost-py3
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/libboost_python3*.so.*
|
||||
%{_libdir}/libboost_python37.so.*
|
||||
%ifnarch arm
|
||||
%{_libdir}/libboost_numpy37.so.*
|
||||
%endif
|
||||
|
||||
%files -n python-boost-py36
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/libboost_python36.so.*
|
||||
%ifnarch arm
|
||||
%{_libdir}/libboost_numpy36.so.*
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Mon Dec 23 2019 Silvan Calarco <silvan.calarco@mambasoft.it> 1.71.0-5mamba
|
||||
- python-boost-py3: don't obsolete python3-boost provided by legacy package
|
||||
|
||||
* Sun Dec 22 2019 Silvan Calarco <silvan.calarco@mambasoft.it> 1.71.0-4mamba
|
||||
- added python-boost-py36 package, rename python3-boost to python-boost-py3
|
||||
|
||||
* Wed Nov 27 2019 Silvan Calarco <silvan.calarco@mambasoft.it> 1.71.0-3mamba
|
||||
- fix build for python3
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user