summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch
diff options
context:
space:
mode:
authorRobert Yang <liezhi.yang@windriver.com>2025-06-08 03:43:10 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2025-06-09 17:43:41 +0100
commitbcf6af00f4f3fb31eca11b2439c57a540c6fc986 (patch)
tree2f8e94172f3f20d21a7855086d7b08ab414718b1 /meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch
parent140fde4c343963235556c3793e56b51b50f4acb4 (diff)
downloadpoky-bcf6af00f4f3fb31eca11b2439c57a540c6fc986.tar.gz
rpm: 4.20.0 -> 4.20.1
* Rebased: 0001-When-cross-installing-execute-package-scriptlets-wit.patch 0016-rpmscript.c-change-logging-level-around-scriptlets-t.patch * Removed the one which already merged: 0001-Set-RPM_PLUGINDIR-in-top-level-CMakeLists.txt.patch * Added a patch to fix rpm-native build error: gcc: error: unrecognized command-line option -fhardened 0001-CMakeLists.txt-Fix-checking-for-CFLAGS.patch * License-Update: Minor formatting changes as the commit messages said in 41143b27b6f7320f280aea6014e8f532eb0239d6 (From OE-Core rev: 5d25e1ba4d8850e2c281fc7f24493239bf2f9866) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch')
-rw-r--r--meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch24
1 files changed, 13 insertions, 11 deletions
diff --git a/meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch b/meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch
index fc6d7e0d29..b71156fe12 100644
--- a/meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch
+++ b/meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch
@@ -24,15 +24,18 @@ Amended 2018-07-03 by Olof Johansson <olofjn@axis.com>:
24 24
25Upstream-Status: Inappropriate [oe-core specific] 25Upstream-Status: Inappropriate [oe-core specific]
26Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> 26Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
27
28Rebased to 4.20.1
29Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
27--- 30---
28 lib/rpmscript.c | 11 ++++++++--- 31 lib/rpmscript.c | 9 +++++++--
29 1 file changed, 8 insertions(+), 3 deletions(-) 32 1 file changed, 7 insertions(+), 2 deletions(-)
30 33
31diff --git a/lib/rpmscript.c b/lib/rpmscript.c 34diff --git a/lib/rpmscript.c b/lib/rpmscript.c
32index 097c9055a..060fd8124 100644 35index eb14870b3..1785e8f30 100644
33--- a/lib/rpmscript.c 36--- a/lib/rpmscript.c
34+++ b/lib/rpmscript.c 37+++ b/lib/rpmscript.c
35@@ -447,8 +447,7 @@ exit: 38@@ -456,8 +456,7 @@ exit:
36 Fclose(out); /* XXX dup'd STDOUT_FILENO */ 39 Fclose(out); /* XXX dup'd STDOUT_FILENO */
37 40
38 if (fn) { 41 if (fn) {
@@ -42,18 +45,17 @@ index 097c9055a..060fd8124 100644
42 free(fn); 45 free(fn);
43 } 46 }
44 free(mline); 47 free(mline);
45@@ -482,7 +481,13 @@ rpmRC rpmScriptRun(rpmScript script, int arg1, int arg2, FD_t scriptFd, 48@@ -491,7 +490,13 @@ rpmRC rpmScriptRun(rpmScript script, int arg1, int arg2, FD_t scriptFd,
46 49
47 if (rc != RPMRC_FAIL) { 50 if (rc != RPMRC_FAIL) {
48 if (script_type & RPMSCRIPTLET_EXEC) { 51 if (script_type & RPMSCRIPTLET_EXEC) {
49- rc = runExtScript(plugins, prefixes, script->descr, lvl, scriptFd, &args, script->body, arg1, arg2, script->nextFileFunc);
50+ if (getenv("RPM_NO_CHROOT_FOR_SCRIPTS") != NULL) { 52+ if (getenv("RPM_NO_CHROOT_FOR_SCRIPTS") != NULL) {
51+ rpmChrootOut(); 53+ rpmChrootOut();
52+ rc = runExtScript(plugins, prefixes, script->descr, lvl, scriptFd, &args, script->body, arg1, arg2, script->nextFileFunc); 54 rc = runExtScript(plugins, prefixes, script, lvl, scriptFd, &args, arg1, arg2);
53+ rpmChrootIn(); 55+ rpmChrootIn();
54+ } else { 56+ } else {
55+ rc = runExtScript(plugins, prefixes, script->descr, lvl, scriptFd, &args, script->body, arg1, arg2, script->nextFileFunc); 57+ rc = runExtScript(plugins, prefixes, script, lvl, scriptFd, &args, arg1, arg2);
56+ } 58+ }
57 } else { 59 } else {
58 rc = runLuaScript(plugins, prefixes, script->descr, lvl, scriptFd, &args, script->body, arg1, arg2, script->nextFileFunc); 60 rc = runLuaScript(plugins, prefixes, script, lvl, scriptFd, &args, arg1, arg2);
59 } 61 }