summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2021-11-20 07:06:09 +0000
committerSam James <sam@gentoo.org>2021-11-20 07:07:25 +0000
commit6d3c1357a7c95b95ecdbf31b3c919890efbcd7f0 (patch)
treec71da0a7a403d76515b20b749e00f98e9625af68 /dev-libs/boost
parentmedia-gfx/darktable: Stabilize 3.6.1-r2 arm64, #822363 (diff)
downloadgentoo-6d3c1357a7c95b95ecdbf31b3c919890efbcd7f0.tar.gz
gentoo-6d3c1357a7c95b95ecdbf31b3c919890efbcd7f0.tar.bz2
gentoo-6d3c1357a7c95b95ecdbf31b3c919890efbcd7f0.zip
dev-libs/boost: add Python 3.10 patch
Been meaning to add this but was undecided given no problems seemed to pop up. Then made the connection (doh) between the linked OpenVDB bug after seeing another distro (Exherbo) pick up this patch. Let's see if it helps the situation there. Bug: https://bugs.gentoo.org/790350 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-libs/boost')
-rw-r--r--dev-libs/boost/boost-1.77.0-r3.ebuild (renamed from dev-libs/boost/boost-1.77.0-r2.ebuild)1
-rw-r--r--dev-libs/boost/files/boost-1.77.0-python-3.10.patch44
2 files changed, 45 insertions, 0 deletions
diff --git a/dev-libs/boost/boost-1.77.0-r2.ebuild b/dev-libs/boost/boost-1.77.0-r3.ebuild
index 05e615af56f6..f0f451a1432a 100644
--- a/dev-libs/boost/boost-1.77.0-r2.ebuild
+++ b/dev-libs/boost/boost-1.77.0-r3.ebuild
@@ -56,6 +56,7 @@ PATCHES=(
"${WORKDIR}"/${PN}-1.76-sparc-define.patch
"${WORKDIR}"/${PN}-1.77-math-deprecated-include.patch
"${WORKDIR}"/${PN}-1.77-geometry.patch
+ "${FILESDIR}"/${P}-python-3.10.patch
)
python_bindings_needed() {
diff --git a/dev-libs/boost/files/boost-1.77.0-python-3.10.patch b/dev-libs/boost/files/boost-1.77.0-python-3.10.patch
new file mode 100644
index 000000000000..69181b1fa42b
--- /dev/null
+++ b/dev-libs/boost/files/boost-1.77.0-python-3.10.patch
@@ -0,0 +1,44 @@
+https://github.com/boostorg/boost_install/commit/0605dadfacf51994dcd8c5c82fb733dc6fa24073
+
+From: Martin Jansa <martin.jansa@lge.com>
+Date: Tue, 19 Oct 2021 12:24:31 +0000
+Subject: [PATCH] BoostConfig.cmake: allow searching for python310
+
+* accept double digits in Python3_VERSION_MINOR
+
+* if someone is using e.g.:
+ find_package(Python3 REQUIRED)
+ find_package(Boost REQUIRED python${Python3_VERSION_MAJOR}${Python3_VERSION_MINOR})
+
+ with python-3.10 then it currently fails with:
+
+ -- Found PythonLibs: /usr/lib/libpython3.10.so (found version "3.10.0")
+ -- Found Python3: -native/usr/bin/python3-native/python3 (found version "3.10.0") found components: Interpreter
+ CMake Error at /usr/lib/cmake/Boost-1.77.0/BoostConfig.cmake:141 (find_package):
+ Could not find a package configuration file provided by "boost_python310"
+ (requested version 1.77.0) with any of the following names:
+
+ boost_python310Config.cmake
+ boost_python310-config.cmake
+
+ Add the installation prefix of "boost_python310" to CMAKE_PREFIX_PATH or
+ set "boost_python310_DIR" to a directory containing one of the above files.
+ If "boost_python310" provides a separate development package or SDK, be
+ sure it has been installed.
+ Call Stack (most recent call first):
+ /usr/lib/cmake/Boost-1.77.0/BoostConfig.cmake:258 (boost_find_component)
+ /usr/share/cmake-3.21/Modules/FindBoost.cmake:594 (find_package)
+ CMakeLists.txt:18 (find_package)
+
+Signed-off-by: Martin Jansa <martin.jansa@lge.com>
+--- a/tools/boost_install/BoostConfig.cmake
++++ b/tools/boost_install/BoostConfig.cmake
+@@ -113,7 +113,7 @@ macro(boost_find_component comp required quiet)
+ set(_BOOST_REQUIRED REQUIRED)
+ endif()
+
+- if("${comp}" MATCHES "^(python|numpy|mpi_python)([1-9])([0-9])$")
++ if("${comp}" MATCHES "^(python|numpy|mpi_python)([1-9])([0-9][0-9]?)$")
+
+ # handle pythonXY and numpyXY versioned components for compatibility
+