Do not link Python extensions to libpython

Boost upstream does not link Boost.Python libraries to libpython, which
matches the advice from Python upstream as well. Drop the Fedora patches
which cause libpython to be linked to. Those patches have been causing
problems for a while anyway.
This commit is contained in:
Jonathan Wakely 2020-05-22 16:37:20 +01:00
parent 1f2e448e09
commit fb6db033ed
3 changed files with 2 additions and 82 deletions

View File

@ -1,13 +0,0 @@
Index: boost_1_57_0/tools/build/src/tools/python.jam
===================================================================
--- boost_1_57_0/tools/build/src/tools/python.jam (revision 50406)
+++ boost_1_57_0/tools/build/src/tools/python.jam (working copy)
@@ -994,7 +994,7 @@
else
{
alias python_for_extensions
- :
+ : python
: $(target-requirements)
:
: $(usage-requirements)

View File

@ -1,62 +0,0 @@
--- boost_1_57_0/tools/build/src/tools/python.jam 2013-05-21 06:14:18.000000000 +0200
+++ boost_1_55_0/tools/build/src/tools/python.jam 2014-05-29 19:09:12.115413877 +0200
@@ -94,7 +94,7 @@ feature.feature pythonpath : : free opti
# using python : 2.3 : /usr/local/bin/python ;
#
rule init ( version ? : cmd-or-prefix ? : includes * : libraries ?
- : condition * : extension-suffix ? )
+ : condition * : extension-suffix ? : abi-letters ? )
{
project.push-current $(.project) ;
@@ -107,7 +107,7 @@ rule init ( version ? : cmd-or-prefix ?
}
}
- configure $(version) : $(cmd-or-prefix) : $(includes) : $(libraries) : $(condition) : $(extension-suffix) ;
+ configure $(version) : $(cmd-or-prefix) : $(includes) : $(libraries) : $(condition) : $(extension-suffix) : $(abi-letters) ;
project.pop-current ;
}
@@ -653,7 +653,7 @@ local rule system-library-dependencies (
# Declare a target to represent Python's library.
#
-local rule declare-libpython-target ( version ? : requirements * )
+local rule declare-libpython-target ( version ? : requirements * : abi-letters ? )
{
# Compute the representation of Python version in the name of Python's
# library file.
@@ -677,13 +677,13 @@ local rule declare-libpython-target ( ve
}
# Declare it.
- lib python.lib : : <name>python$(lib-version) $(requirements) ;
+ lib python.lib : : <name>python$(lib-version)$(abi-letters) $(requirements) ;
}
# Implementation of init.
local rule configure ( version ? : cmd-or-prefix ? : includes * : libraries ? :
- condition * : extension-suffix ? )
+ condition * : extension-suffix ? : abi-letters ? )
{
local prefix ;
local exec-prefix ;
@@ -699,6 +699,7 @@ local rule configure ( version ? : cmd-o
extension-suffix ?= _d ;
}
extension-suffix ?= "" ;
+ abi-letters ?= "" ;
local cmds-to-try ;
@@ -922,7 +923,7 @@ local rule configure ( version ? : cmd-o
}
else
{
- declare-libpython-target $(version) : $(target-requirements) ;
+ declare-libpython-target $(version) : $(target-requirements) : $(abi-letters) ;
# This is an evil hack. On, Windows, when Python is embedded, nothing
# seems to set up sys.path to include Python's standard library

View File

@ -134,10 +134,6 @@ Patch15: boost-1.58.0-pool.patch
# https://svn.boost.org/trac/boost/ticket/9038
Patch51: boost-1.58.0-pool-test_linking.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1102667
Patch61: boost-1.57.0-python-libpython_dep.patch
Patch62: boost-1.66.0-python-abi_letters.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1190039
Patch65: boost-1.66.0-build-optflags.patch
@ -650,8 +646,6 @@ find ./boost -name '*.hpp' -perm /111 | xargs chmod a-x
%patch5 -p1
%patch15 -p0
%patch51 -p1
%patch61 -p1
%patch62 -p1
%patch65 -p1
%patch82 -p1
%patch83 -p1
@ -688,7 +682,7 @@ EOF
%if %{with python3}
cat >> ./tools/build/src/user-config.jam << EOF
using python : %{python3_version} : /usr/bin/python3 : /usr/include/python%{python3_version}${PYTHON3_ABIFLAGS} : : : : ${PYTHON3_ABIFLAGS} ;
using python : %{python3_version} : /usr/bin/python3 : /usr/include/python%{python3_version}${PYTHON3_ABIFLAGS} : : : ;
EOF
%endif
@ -1248,6 +1242,7 @@ fi
%changelog
* Fri May 22 2020 Jonathan Wakely <jwakely@redhat.com> - 1.69.0-20
- Require boost-python3 for boost, fold boost-python3-devel into boost-devel
- Do not link Python extensions to libpython
* Fri May 15 2020 Pete Walter <pwalter@fedoraproject.org> - 1.69.0-19
- Rebuild for ICU 67