summaryrefslogtreecommitdiffstats
path: root/meta/recipes-support/boost
diff options
context:
space:
mode:
authorMartin Jansa <Martin.Jansa@gmail.com>2021-10-19 14:43:32 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-10-23 17:42:27 +0100
commitf482f1d531028197bc38d67db7d2b895b95af4b5 (patch)
treebd8d85850b6c2ad09ce77de1f584df640fc2befc /meta/recipes-support/boost
parentcbfd377c7dc6c79749fc80508f5ac8c4bd1ce5d1 (diff)
downloadpoky-f482f1d531028197bc38d67db7d2b895b95af4b5.tar.gz
boost: allow searching for python310
(From OE-Core rev: a8add0bdec7c51c9a7f851b2c63017c79faaa273) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-support/boost')
-rw-r--r--meta/recipes-support/boost/boost/0001-BoostConfig.cmake-allow-searching-for-python310.patch50
-rw-r--r--meta/recipes-support/boost/boost_1.77.0.bb1
2 files changed, 51 insertions, 0 deletions
diff --git a/meta/recipes-support/boost/boost/0001-BoostConfig.cmake-allow-searching-for-python310.patch b/meta/recipes-support/boost/boost/0001-BoostConfig.cmake-allow-searching-for-python310.patch
new file mode 100644
index 0000000000..0a9ee2cc95
--- /dev/null
+++ b/meta/recipes-support/boost/boost/0001-BoostConfig.cmake-allow-searching-for-python310.patch
@@ -0,0 +1,50 @@
1From e193f080c7d209516ac9b712fa0c50bb08026fa2 Mon Sep 17 00:00:00 2001
2From: Martin Jansa <Martin.Jansa@gmail.com>
3Date: Tue, 19 Oct 2021 12:24:31 +0000
4Subject: [PATCH] BoostConfig.cmake: allow searching for python310
5
6* accept double digits in Python3_VERSION_MINOR
7
8* if someone is using e.g.:
9 find_package(Python3 REQUIRED)
10 find_package(Boost REQUIRED python${Python3_VERSION_MAJOR}${Python3_VERSION_MINOR})
11
12 with python-3.10 then it currently fails with:
13
14 -- Found PythonLibs: /usr/lib/libpython3.10.so (found version "3.10.0")
15 -- Found Python3: -native/usr/bin/python3-native/python3 (found version "3.10.0") found components: Interpreter
16 CMake Error at /usr/lib/cmake/Boost-1.77.0/BoostConfig.cmake:141 (find_package):
17 Could not find a package configuration file provided by "boost_python310"
18 (requested version 1.77.0) with any of the following names:
19
20 boost_python310Config.cmake
21 boost_python310-config.cmake
22
23 Add the installation prefix of "boost_python310" to CMAKE_PREFIX_PATH or
24 set "boost_python310_DIR" to a directory containing one of the above files.
25 If "boost_python310" provides a separate development package or SDK, be
26 sure it has been installed.
27 Call Stack (most recent call first):
28 /usr/lib/cmake/Boost-1.77.0/BoostConfig.cmake:258 (boost_find_component)
29 /usr/share/cmake-3.21/Modules/FindBoost.cmake:594 (find_package)
30 CMakeLists.txt:18 (find_package)
31
32Upstream-Status: Submitted [https://github.com/boostorg/boost_install/pull/53]
33Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
34---
35 tools/boost_install/BoostConfig.cmake | 2 +-
36 1 file changed, 1 insertion(+), 1 deletion(-)
37
38diff --git a/tools/boost_install/BoostConfig.cmake b/tools/boost_install/BoostConfig.cmake
39index fd17821..5dffa58 100644
40--- a/tools/boost_install/BoostConfig.cmake
41+++ b/tools/boost_install/BoostConfig.cmake
42@@ -113,7 +113,7 @@ macro(boost_find_component comp required quiet)
43 set(_BOOST_REQUIRED REQUIRED)
44 endif()
45
46- if("${comp}" MATCHES "^(python|numpy|mpi_python)([1-9])([0-9])$")
47+ if("${comp}" MATCHES "^(python|numpy|mpi_python)([1-9])([0-9][0-9]?)$")
48
49 # handle pythonXY and numpyXY versioned components for compatibility
50
diff --git a/meta/recipes-support/boost/boost_1.77.0.bb b/meta/recipes-support/boost/boost_1.77.0.bb
index df8e08ad76..ba60281950 100644
--- a/meta/recipes-support/boost/boost_1.77.0.bb
+++ b/meta/recipes-support/boost/boost_1.77.0.bb
@@ -6,4 +6,5 @@ SRC_URI += "file://boost-CVE-2012-2677.patch \
6 file://0001-Don-t-set-up-arch-instruction-set-flags-we-do-that-o.patch \ 6 file://0001-Don-t-set-up-arch-instruction-set-flags-we-do-that-o.patch \
7 file://0001-dont-setup-compiler-flags-m32-m64.patch \ 7 file://0001-dont-setup-compiler-flags-m32-m64.patch \
8 file://0001-fiber-libs-Define-SYS_futex-if-it-does-not-exist.patch \ 8 file://0001-fiber-libs-Define-SYS_futex-if-it-does-not-exist.patch \
9 file://0001-BoostConfig.cmake-allow-searching-for-python310.patch \
9 " 10 "