diff options
Diffstat (limited to 'meta-python/recipes-devtools/python')
3 files changed, 59 insertions, 0 deletions
diff --git a/meta-python/recipes-devtools/python/python3-cmake/CMakeLists.txt b/meta-python/recipes-devtools/python/python3-cmake/CMakeLists.txt new file mode 100644 index 0000000000..8ba81970ff --- /dev/null +++ b/meta-python/recipes-devtools/python/python3-cmake/CMakeLists.txt | |||
| @@ -0,0 +1,11 @@ | |||
| 1 | cmake_minimum_required(VERSION 3.6) | ||
| 2 | |||
| 3 | # | ||
| 4 | # For more details, see docs/building.rst | ||
| 5 | # | ||
| 6 | |||
| 7 | project(CMakePythonDistributions NONE) | ||
| 8 | |||
| 9 | install(CODE " | ||
| 10 | message(STATUS \"Install CMake project\") | ||
| 11 | ") | ||
diff --git a/meta-python/recipes-devtools/python/python3-cmake/run-cmake-from-path.patch b/meta-python/recipes-devtools/python/python3-cmake/run-cmake-from-path.patch new file mode 100644 index 0000000000..5c38fadce0 --- /dev/null +++ b/meta-python/recipes-devtools/python/python3-cmake/run-cmake-from-path.patch | |||
| @@ -0,0 +1,11 @@ | |||
| 1 | --- cmake-3.25.2/src/cmake/__init__.py.old 2023-03-10 09:40:43.582315753 +0100 | ||
| 2 | +++ cmake-3.25.2/src/cmake/__init__.py 2023-03-10 09:41:38.030874047 +0100 | ||
| 3 | @@ -36,7 +36,7 @@ | ||
| 4 | |||
| 5 | |||
| 6 | def _program(name, args): | ||
| 7 | - return subprocess.call([os.path.join(CMAKE_BIN_DIR, name)] + args, close_fds=False) | ||
| 8 | + return subprocess.call([name] + args, close_fds=False) | ||
| 9 | |||
| 10 | |||
| 11 | def cmake(): | ||
diff --git a/meta-python/recipes-devtools/python/python3-cmake_3.25.2.bb b/meta-python/recipes-devtools/python/python3-cmake_3.25.2.bb new file mode 100644 index 0000000000..d0e11f9a61 --- /dev/null +++ b/meta-python/recipes-devtools/python/python3-cmake_3.25.2.bb | |||
| @@ -0,0 +1,37 @@ | |||
| 1 | SUMMARY = "CMake is an open-source, cross-platform family of tools designed to build, test and package software" | ||
| 2 | LICENSE = "BSD-3-Clause & Apache-2.0" | ||
| 3 | LIC_FILES_CHKSUM = " \ | ||
| 4 | file://LICENSE_BSD_3;md5=9134cb61aebbdd79dd826ccb9ae6afcd \ | ||
| 5 | file://LICENSE_Apache_20;md5=19cbd64715b51267a47bf3750cc6a8a5 \ | ||
| 6 | " | ||
| 7 | |||
| 8 | DEPENDS = "ninja-native cmake-native python3-scikit-build-native" | ||
| 9 | |||
| 10 | PYPI_PACKAGE = "cmake" | ||
| 11 | PYPI_ARCHIVE_NAME_PREFIX = "pypi-" | ||
| 12 | |||
| 13 | inherit pypi python_setuptools_build_meta | ||
| 14 | SRC_URI[sha256sum] = "bcf9f0369743278ec26961542b31ed1610e6f4cfc20c00a3f1c61985abb3b0d2" | ||
| 15 | |||
| 16 | SRC_URI += " \ | ||
| 17 | file://CMakeLists.txt \ | ||
| 18 | file://run-cmake-from-path.patch \ | ||
| 19 | " | ||
| 20 | |||
| 21 | addtask do_patchbuild after do_patch before do_configure | ||
| 22 | |||
| 23 | do_patchbuild () { | ||
| 24 | rm -f ${S}/CMakeLists.txt | ||
| 25 | cp ${WORKDIR}/CMakeLists.txt ${S}/ | ||
| 26 | } | ||
| 27 | |||
| 28 | do_install:append () { | ||
| 29 | rm -rf ${D}${bindir} | ||
| 30 | } | ||
| 31 | |||
| 32 | RDEPENDS:${PN} = " \ | ||
| 33 | cmake \ | ||
| 34 | python3-scikit-build \ | ||
| 35 | " | ||
| 36 | |||
| 37 | BBCLASSEXTEND = "native nativesdk" | ||
