diff options
Diffstat (limited to 'recipes-containers/criu')
6 files changed, 113 insertions, 69 deletions
diff --git a/recipes-containers/criu/criu_git.bb b/recipes-containers/criu/criu_git.bb index 09503624..8a7b5ad3 100644 --- a/recipes-containers/criu/criu_git.bb +++ b/recipes-containers/criu/criu_git.bb | |||
@@ -13,15 +13,17 @@ EXCLUDE_FROM_WORLD = "1" | |||
13 | 13 | ||
14 | LIC_FILES_CHKSUM = "file://COPYING;md5=412de458544c1cb6a2b512cd399286e2" | 14 | LIC_FILES_CHKSUM = "file://COPYING;md5=412de458544c1cb6a2b512cd399286e2" |
15 | 15 | ||
16 | SRCREV = "f8b14286b092853a4485813e1efd564109df9123" | 16 | SRCREV = "b6059ff193a9b0dff98e997134d662c3ccfd1600" |
17 | PV = "3.19.0+git" | 17 | PV = "4.1+git" |
18 | 18 | ||
19 | SRC_URI = "git://github.com/checkpoint-restore/criu.git;branch=master;protocol=https \ | 19 | SRC_URI = "git://github.com/checkpoint-restore/criu.git;branch=master;protocol=https \ |
20 | file://0001-criu-Skip-documentation-install.patch \ | 20 | file://0001-criu-Skip-documentation-install.patch \ |
21 | file://0002-criu-Change-libraries-install-directory.patch \ | 21 | file://0002-criu-Change-libraries-install-directory.patch \ |
22 | file://0003-crit-pycriu-build-and-install-wheels.patch \ | 22 | file://0003-crit-pycriu-build-and-install-wheels.patch \ |
23 | file://0004-pycriu-attr-pycriu.version.__version__.patch \ | 23 | file://0004-pycriu-attr-pycriu.version.__version__.patch \ |
24 | file://0005-pycriu-skip-dependency-check-during-build.patch \ | 24 | file://0005-pycriu-skip-dependency-check-during-build.patch \ |
25 | file://0001-crit-explicity-set-PEP517_SOURCE_PATH.patch \ | ||
26 | file://0001-plugins-cuda-pass-DEBUG_PREFIX_MAP.patch \ | ||
25 | " | 27 | " |
26 | 28 | ||
27 | COMPATIBLE_HOST = "(x86_64|arm|aarch64).*-linux" | 29 | COMPATIBLE_HOST = "(x86_64|arm|aarch64).*-linux" |
@@ -46,11 +48,11 @@ EXTRA_OEMAKE:append = " LOGROTATEDIR=${sysconfdir} SYSTEMDUNITDIR=${systemd_unit | |||
46 | CFLAGS += "-D__USE_GNU -D_GNU_SOURCE " | 48 | CFLAGS += "-D__USE_GNU -D_GNU_SOURCE " |
47 | 49 | ||
48 | CFLAGS += " -I${STAGING_INCDIR} -I${STAGING_INCDIR}/libnl3" | 50 | CFLAGS += " -I${STAGING_INCDIR} -I${STAGING_INCDIR}/libnl3" |
49 | CFLAGS:arm += "-D__WORDSIZE" | 51 | CFLAGS:append:arm = " -D__WORDSIZE" |
50 | 52 | ||
51 | # overide LDFLAGS to allow criu to build without: "x86_64-poky-linux-ld: unrecognized option '-Wl,-O1'" | 53 | # overide LDFLAGS to allow criu to build without: "x86_64-poky-linux-ld: unrecognized option '-Wl,-O1'" |
52 | export LDFLAGS="" | 54 | export LDFLAGS = "" |
53 | export C_INCLUDE_PATH="${STAGING_INCDIR}/libnl3" | 55 | export C_INCLUDE_PATH = "${STAGING_INCDIR}/libnl3" |
54 | 56 | ||
55 | export BUILD_SYS | 57 | export BUILD_SYS |
56 | export HOST_SYS | 58 | export HOST_SYS |
@@ -75,6 +77,7 @@ do_compile:prepend() { | |||
75 | } | 77 | } |
76 | 78 | ||
77 | do_compile () { | 79 | do_compile () { |
80 | export DEBUG_PREFIX_MAP="${DEBUG_PREFIX_MAP}" | ||
78 | oe_runmake FULL_PYTHON=${PYTHON} PYTHON=nativepython3 | 81 | oe_runmake FULL_PYTHON=${PYTHON} PYTHON=nativepython3 |
79 | } | 82 | } |
80 | 83 | ||
@@ -83,6 +86,7 @@ do_install () { | |||
83 | export PEP517_WHEEL_PATH="${PEP517_WHEEL_PATH}" | 86 | export PEP517_WHEEL_PATH="${PEP517_WHEEL_PATH}" |
84 | export USRBINPATH="${USRBINPATH}" | 87 | export USRBINPATH="${USRBINPATH}" |
85 | export PEP517_INSTALL_PYTHON="${PEP517_INSTALL_PYTHON}" | 88 | export PEP517_INSTALL_PYTHON="${PEP517_INSTALL_PYTHON}" |
89 | |||
86 | oe_runmake PREFIX=${exec_prefix} LIBDIR=${libdir} DESTDIR="${D}" PLUGINDIR="${localstatedir}/lib" FULL_PYTHON=${PYTHON} PYTHON=nativepython3 install | 90 | oe_runmake PREFIX=${exec_prefix} LIBDIR=${libdir} DESTDIR="${D}" PLUGINDIR="${localstatedir}/lib" FULL_PYTHON=${PYTHON} PYTHON=nativepython3 install |
87 | 91 | ||
88 | # python3's distutils has a feature of rewriting the interpeter on setup installed | 92 | # python3's distutils has a feature of rewriting the interpeter on setup installed |
diff --git a/recipes-containers/criu/files/0001-crit-explicity-set-PEP517_SOURCE_PATH.patch b/recipes-containers/criu/files/0001-crit-explicity-set-PEP517_SOURCE_PATH.patch new file mode 100644 index 00000000..ee37bc81 --- /dev/null +++ b/recipes-containers/criu/files/0001-crit-explicity-set-PEP517_SOURCE_PATH.patch | |||
@@ -0,0 +1,32 @@ | |||
1 | From 0af358f8ae5e671d78e3de32a2d26bb3cf2c23f8 Mon Sep 17 00:00:00 2001 | ||
2 | From: Bruce Ashfield <bruce.ashfield@gmail.com> | ||
3 | Date: Thu, 3 Apr 2025 17:08:01 +0000 | ||
4 | Subject: [PATCH] crit: explicity set PEP517_SOURCE_PATH | ||
5 | |||
6 | Similarly to the ./lib build, we need to explicitly set | ||
7 | this to avoid pyproject.toml errors during the build (the | ||
8 | project file cannot be found) | ||
9 | |||
10 | Upstream-Status: Inappropriate [oe specific] | ||
11 | |||
12 | Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com> | ||
13 | --- | ||
14 | crit/Makefile | 3 +++ | ||
15 | 1 file changed, 3 insertions(+) | ||
16 | |||
17 | diff --git a/crit/Makefile b/crit/Makefile | ||
18 | index 90f0ee635..329c7e85c 100644 | ||
19 | --- a/crit/Makefile | ||
20 | +++ b/crit/Makefile | ||
21 | @@ -1,5 +1,8 @@ | ||
22 | VERSION_FILE := $(if $(obj),$(addprefix $(obj)/,crit/version.py),crit/version.py) | ||
23 | |||
24 | +PEP517_SOURCE_PATH := ./crit | ||
25 | +PEP517_BUILD_OPTS := | ||
26 | + | ||
27 | all-y += ${VERSION_FILE} | ||
28 | cleanup-y += ${VERSION_FILE} | ||
29 | |||
30 | -- | ||
31 | 2.43.0 | ||
32 | |||
diff --git a/recipes-containers/criu/files/0001-criu-Skip-documentation-install.patch b/recipes-containers/criu/files/0001-criu-Skip-documentation-install.patch index dd33b1bd..39cbd1ef 100644 --- a/recipes-containers/criu/files/0001-criu-Skip-documentation-install.patch +++ b/recipes-containers/criu/files/0001-criu-Skip-documentation-install.patch | |||
@@ -12,12 +12,12 @@ Signed-off-by: Jianchuan Wang <jianchuan.wang@windriver.com> | |||
12 | Makefile.install | 2 +- | 12 | Makefile.install | 2 +- |
13 | 1 file changed, 1 insertion(+), 1 deletion(-) | 13 | 1 file changed, 1 insertion(+), 1 deletion(-) |
14 | 14 | ||
15 | diff --git a/Makefile.install b/Makefile.install | 15 | Index: git/Makefile.install |
16 | index aafb95469..1b02b70af 100644 | 16 | =================================================================== |
17 | --- a/Makefile.install | 17 | --- git.orig/Makefile.install |
18 | +++ b/Makefile.install | 18 | +++ git/Makefile.install |
19 | @@ -30,7 +30,7 @@ export PREFIX BINDIR SBINDIR MANDIR RUNDIR | 19 | @@ -53,7 +53,7 @@ |
20 | export LIBDIR INCLUDEDIR LIBEXECDIR PLUGINDIR | 20 | export SKIP_PIP_INSTALL PIPFLAGS |
21 | 21 | ||
22 | install-man: | 22 | install-man: |
23 | - $(Q) $(MAKE) -C Documentation install | 23 | - $(Q) $(MAKE) -C Documentation install |
@@ -25,6 +25,3 @@ index aafb95469..1b02b70af 100644 | |||
25 | .PHONY: install-man | 25 | .PHONY: install-man |
26 | 26 | ||
27 | install-lib: lib | 27 | install-lib: lib |
28 | -- | ||
29 | 2.25.1 | ||
30 | |||
diff --git a/recipes-containers/criu/files/0001-plugins-cuda-pass-DEBUG_PREFIX_MAP.patch b/recipes-containers/criu/files/0001-plugins-cuda-pass-DEBUG_PREFIX_MAP.patch new file mode 100644 index 00000000..0ccd6989 --- /dev/null +++ b/recipes-containers/criu/files/0001-plugins-cuda-pass-DEBUG_PREFIX_MAP.patch | |||
@@ -0,0 +1,31 @@ | |||
1 | From 816cad363c3c17636d8c6424578c3c70f0e87624 Mon Sep 17 00:00:00 2001 | ||
2 | From: Bruce Ashfield <bruce.ashfield@gmail.com> | ||
3 | Date: Thu, 3 Apr 2025 17:48:44 +0000 | ||
4 | Subject: [PATCH] plugins/cuda: pass DEBUG_PREFIX_MAP | ||
5 | |||
6 | If we don't explicitly pass the debug prefix map to the build | ||
7 | QA errors result in the debug package (host path). | ||
8 | |||
9 | Upstream-Status: Inappropriate [OE-Specific] | ||
10 | |||
11 | Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com> | ||
12 | --- | ||
13 | plugins/cuda/Makefile | 2 +- | ||
14 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
15 | |||
16 | diff --git a/plugins/cuda/Makefile b/plugins/cuda/Makefile | ||
17 | index cc3d98ac9..aac9027a7 100644 | ||
18 | --- a/plugins/cuda/Makefile | ||
19 | +++ b/plugins/cuda/Makefile | ||
20 | @@ -19,7 +19,7 @@ all: $(DEPS_CUDA) | ||
21 | |||
22 | cuda_plugin.so: cuda_plugin.c | ||
23 | $(call msg-gen, $@) | ||
24 | - $(Q) $(CC) $(PLUGIN_CFLAGS) $(shell $(COMPEL) includes) $^ -o $@ $(PLUGIN_INCLUDE) $(PLUGIN_LDFLAGS) | ||
25 | + $(Q) $(CC) $(PLUGIN_CFLAGS) $(DEBUG_PREFIX_MAP) $(shell $(COMPEL) includes) $^ -o $@ $(PLUGIN_INCLUDE) $(PLUGIN_LDFLAGS) | ||
26 | |||
27 | clean: | ||
28 | $(call msg-clean, $@) | ||
29 | -- | ||
30 | 2.43.0 | ||
31 | |||
diff --git a/recipes-containers/criu/files/0003-crit-pycriu-build-and-install-wheels.patch b/recipes-containers/criu/files/0003-crit-pycriu-build-and-install-wheels.patch index 0796bb24..c9c4b9b9 100644 --- a/recipes-containers/criu/files/0003-crit-pycriu-build-and-install-wheels.patch +++ b/recipes-containers/criu/files/0003-crit-pycriu-build-and-install-wheels.patch | |||
@@ -15,38 +15,26 @@ Signed-off-by: Tim Orling <tim.orling@konsulko.com> | |||
15 | lib/Makefile | 11 +++++++++-- | 15 | lib/Makefile | 11 +++++++++-- |
16 | 2 files changed, 15 insertions(+), 4 deletions(-) | 16 | 2 files changed, 15 insertions(+), 4 deletions(-) |
17 | 17 | ||
18 | diff --git a/crit/Makefile b/crit/Makefile | 18 | Index: git/crit/Makefile |
19 | index 9a856db6d..9b36f4be1 100644 | 19 | =================================================================== |
20 | --- a/crit/Makefile | 20 | --- git.orig/crit/Makefile |
21 | +++ b/crit/Makefile | 21 | +++ git/crit/Makefile |
22 | @@ -1,5 +1,7 @@ | 22 | @@ -8,8 +8,10 @@ |
23 | PYTHON_EXTERNALLY_MANAGED := $(shell $(PYTHON) -c 'import os, sysconfig; print(int(os.path.isfile(os.path.join(sysconfig.get_path("stdlib"), "EXTERNALLY-MANAGED"))))') | ||
24 | PIP_BREAK_SYSTEM_PACKAGES := 0 | ||
25 | +PEP517_SOURCE_PATH := ./crit | ||
26 | +PEP517_BUILD_OPTS := | ||
27 | |||
28 | VERSION_FILE := $(if $(obj),$(addprefix $(obj)/,crit/version.py),crit/version.py) | ||
29 | 23 | ||
30 | @@ -16,11 +18,13 @@ ifeq ($(PIP_BREAK_SYSTEM_PACKAGES),0) | 24 | install: ${VERSION_FILE} |
31 | $(E) " Consider using PIP_BREAK_SYSTEM_PACKAGES=1 make install" | 25 | ifeq ($(SKIP_PIP_INSTALL),0) |
32 | else | ||
33 | $(E) " INSTALL " crit | ||
34 | - $(Q) $(PYTHON) -m pip install --upgrade --ignore-installed --prefix=$(DESTDIR)$(PREFIX) ./crit | ||
35 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) | ||
36 | endif | ||
37 | else | ||
38 | + $(E) " BUILD " crit | 26 | + $(E) " BUILD " crit |
39 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) | 27 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) |
40 | $(E) " INSTALL " crit | 28 | $(E) " INSTALL " crit |
41 | - $(Q) $(PYTHON) -m pip install --upgrade --ignore-installed --prefix=$(DESTDIR)$(PREFIX) ./crit | 29 | - $(Q) $(PYTHON) -m pip install $(PIPFLAGS) --prefix=$(DESTDIR)$(PREFIX) ./crit |
42 | + $(Q) $(PYTHON) -m installer $(INSTALL_WHEEL_COMPILE_BYTECODE) --interpreter "$(USRBINPATH)/env $(PEP517_INSTALL_PYTHON)" --destdir=$(DESTDIR) $(PEP517_WHEEL_PATH)/crit-*.whl | 30 | + $(Q) $(PYTHON) -m installer $(INSTALL_WHEEL_COMPILE_BYTECODE) --interpreter "$(USRBINPATH)/env $(PEP517_INSTALL_PYTHON)" --destdir=$(DESTDIR) $(PEP517_WHEEL_PATH)/crit-*.whl |
31 | else | ||
32 | $(E) " SKIP INSTALL crit" | ||
43 | endif | 33 | endif |
44 | .PHONY: install | 34 | Index: git/lib/Makefile |
45 | 35 | =================================================================== | |
46 | diff --git a/lib/Makefile b/lib/Makefile | 36 | --- git.orig/lib/Makefile |
47 | index ae371e78e..b5f147482 100644 | 37 | +++ git/lib/Makefile |
48 | --- a/lib/Makefile | ||
49 | +++ b/lib/Makefile | ||
50 | @@ -1,6 +1,9 @@ | 38 | @@ -1,6 +1,9 @@ |
51 | CRIU_SO := libcriu.so | 39 | CRIU_SO := libcriu.so |
52 | CRIU_A := libcriu.a | 40 | CRIU_A := libcriu.a |
@@ -57,21 +45,15 @@ index ae371e78e..b5f147482 100644 | |||
57 | 45 | ||
58 | all-y += lib-c lib-a lib-py | 46 | all-y += lib-c lib-a lib-py |
59 | 47 | ||
60 | @@ -63,11 +66,15 @@ ifeq ($(PIP_BREAK_SYSTEM_PACKAGES),0) | 48 | @@ -55,8 +58,10 @@ |
61 | $(E) " Consider using PIP_BREAK_SYSTEM_PACKAGES=1 make install" | 49 | $(Q) sed -e 's,@version@,$(CRIU_VERSION),' -e 's,@libdir@,$(LIBDIR),' -e 's,@includedir@,$(dir $(INCLUDEDIR)/criu/),' lib/c/criu.pc.in > lib/c/criu.pc |
62 | else | 50 | $(Q) install -m 644 lib/c/criu.pc $(DESTDIR)$(LIBDIR)/pkgconfig |
63 | $(E) " INSTALL " pycriu | 51 | ifeq ($(SKIP_PIP_INSTALL),0) |
64 | - $(Q) $(PYTHON) -m pip install --upgrade --ignore-installed --prefix=$(DESTDIR)$(PREFIX) ./lib | ||
65 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) | ||
66 | endif | ||
67 | else | ||
68 | + $(E) " BUILD " pycriu | 52 | + $(E) " BUILD " pycriu |
69 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) | 53 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) |
70 | $(E) " INSTALL " pycriu | 54 | $(E) " INSTALL " pycriu |
71 | - $(Q) $(PYTHON) -m pip install --upgrade --ignore-installed --prefix=$(DESTDIR)$(PREFIX) ./lib | 55 | - $(Q) $(PYTHON) -m pip install $(PIPFLAGS) --prefix=$(DESTDIR)$(PREFIX) ./lib |
72 | + #nativepython3 -m installer ${INSTALL_WHEEL_COMPILE_BYTECODE} --interpreter "${USRBINPATH}/env ${PEP517_INSTALL_PYTHON}" --destdir=${D} ${PEP517_WHEEL_PATH}/*.whl | 56 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) |
73 | + | 57 | else |
74 | + $(Q) $(PYTHON) -m installer $(INSTALL_WHEEL_COMPILE_BYTECODE) --interpreter "$(USRBINPATH)/env $(PEP517_INSTALL_PYTHON)" --destdir=$(DESTDIR) $(PEP517_WHEEL_PATH)/pycriu-*.whl | 58 | $(E) " SKIP INSTALL pycriu" |
75 | endif | 59 | endif |
76 | .PHONY: install | ||
77 | |||
diff --git a/recipes-containers/criu/files/0005-pycriu-skip-dependency-check-during-build.patch b/recipes-containers/criu/files/0005-pycriu-skip-dependency-check-during-build.patch index 88872911..77c6c3e6 100644 --- a/recipes-containers/criu/files/0005-pycriu-skip-dependency-check-during-build.patch +++ b/recipes-containers/criu/files/0005-pycriu-skip-dependency-check-during-build.patch | |||
@@ -12,21 +12,19 @@ Signed-off-by: Tim Orling <tim.orling@konsulko.com> | |||
12 | lib/Makefile | 4 ++-- | 12 | lib/Makefile | 4 ++-- |
13 | 1 file changed, 2 insertions(+), 2 deletions(-) | 13 | 1 file changed, 2 insertions(+), 2 deletions(-) |
14 | 14 | ||
15 | diff --git a/lib/Makefile b/lib/Makefile | 15 | Index: git/lib/Makefile |
16 | index b5f147482..e3faa7a06 100644 | 16 | =================================================================== |
17 | --- a/lib/Makefile | 17 | --- git.orig/lib/Makefile |
18 | +++ b/lib/Makefile | 18 | +++ git/lib/Makefile |
19 | @@ -66,11 +66,11 @@ ifeq ($(PIP_BREAK_SYSTEM_PACKAGES),0) | 19 | @@ -59,9 +59,9 @@ |
20 | $(E) " Consider using PIP_BREAK_SYSTEM_PACKAGES=1 make install" | 20 | $(Q) install -m 644 lib/c/criu.pc $(DESTDIR)$(LIBDIR)/pkgconfig |
21 | else | 21 | ifeq ($(SKIP_PIP_INSTALL),0) |
22 | $(E) " INSTALL " pycriu | ||
23 | - $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) | ||
24 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --skip-dependency-check --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) | ||
25 | endif | ||
26 | else | ||
27 | $(E) " BUILD " pycriu | 22 | $(E) " BUILD " pycriu |
28 | - $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) | 23 | - $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) |
29 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --skip-dependency-check --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) | 24 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --skip-dependency-check --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) |
30 | $(E) " INSTALL " pycriu | 25 | $(E) " INSTALL " pycriu |
31 | #nativepython3 -m installer ${INSTALL_WHEEL_COMPILE_BYTECODE} --interpreter "${USRBINPATH}/env ${PEP517_INSTALL_PYTHON}" --destdir=${D} ${PEP517_WHEEL_PATH}/*.whl | 26 | - $(Q) $(PYTHON) -m build --no-isolation --wheel --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) |
32 | 27 | + $(Q) $(PYTHON) -m build --no-isolation --wheel --skip-dependency-check --outdir $(PEP517_WHEEL_PATH) $(PEP517_SOURCE_PATH) $(PEP517_BUILD_OPTS) | |
28 | else | ||
29 | $(E) " SKIP INSTALL pycriu" | ||
30 | endif | ||