diff options
author | Peter Kjellerstedt <peter.kjellerstedt@axis.com> | 2021-03-06 14:46:22 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-03-06 22:39:04 +0000 |
commit | a7e117c8ed063eb11266de3f696d12a2b7b9708e (patch) | |
tree | 54b5559f149510408ba83806acaeee1fb39f92ee /meta/recipes-devtools | |
parent | fac55b36a41b3a17a810a4ec54224dd7f3086e47 (diff) | |
download | poky-a7e117c8ed063eb11266de3f696d12a2b7b9708e.tar.gz |
meson: Correctly set uid/gid of installed files
In 0.57.0, the uid and gid arguments passed to os.chown() when using
install_mode were accidentally swapped, causing files to end up with
incorrect owner/group if the owner and group are not the same.
(From OE-Core rev: 8f19fb08b66cd75616345e96fa5718048daae7fe)
Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools')
-rw-r--r-- | meta/recipes-devtools/meson/meson.inc | 1 | ||||
-rw-r--r-- | meta/recipes-devtools/meson/meson/0001-minstall-Correctly-set-uid-gid-of-installed-files.patch | 28 |
2 files changed, 29 insertions, 0 deletions
diff --git a/meta/recipes-devtools/meson/meson.inc b/meta/recipes-devtools/meson/meson.inc index 622c22affd..8454d18c28 100644 --- a/meta/recipes-devtools/meson/meson.inc +++ b/meta/recipes-devtools/meson/meson.inc | |||
@@ -14,6 +14,7 @@ SRC_URI = "https://github.com/mesonbuild/meson/releases/download/${PV}/meson-${P | |||
14 | file://disable-rpath-handling.patch \ | 14 | file://disable-rpath-handling.patch \ |
15 | file://cross-prop-default.patch \ | 15 | file://cross-prop-default.patch \ |
16 | file://0001-modules-python.py-do-not-substitute-python-s-install.patch \ | 16 | file://0001-modules-python.py-do-not-substitute-python-s-install.patch \ |
17 | file://0001-minstall-Correctly-set-uid-gid-of-installed-files.patch \ | ||
17 | " | 18 | " |
18 | SRC_URI[sha256sum] = "72e1c782ba9bda204f4a1ed57f98d027d7b6eb9414c723eebbd6ec7f1955c8a6" | 19 | SRC_URI[sha256sum] = "72e1c782ba9bda204f4a1ed57f98d027d7b6eb9414c723eebbd6ec7f1955c8a6" |
19 | 20 | ||
diff --git a/meta/recipes-devtools/meson/meson/0001-minstall-Correctly-set-uid-gid-of-installed-files.patch b/meta/recipes-devtools/meson/meson/0001-minstall-Correctly-set-uid-gid-of-installed-files.patch new file mode 100644 index 0000000000..d55b7cc7c7 --- /dev/null +++ b/meta/recipes-devtools/meson/meson/0001-minstall-Correctly-set-uid-gid-of-installed-files.patch | |||
@@ -0,0 +1,28 @@ | |||
1 | From 3f6f4964dc79ae986f44afe1687922381f237edd Mon Sep 17 00:00:00 2001 | ||
2 | From: Peter Kjellerstedt <pkj@axis.com> | ||
3 | Date: Wed, 3 Mar 2021 12:47:28 +0100 | ||
4 | Subject: [PATCH] minstall: Correctly set uid/gid of installed files | ||
5 | |||
6 | In commit caab4d3d, the uid and gid arguments passed to os.chown() by | ||
7 | set_chown() were accidentally swapped, causing files to end up with | ||
8 | incorrect owner/group if the owner and group are not the same. | ||
9 | |||
10 | Upstream-Status: Backport [https://github.com/mesonbuild/meson/commit/6226ac26ef63335bfb817db02b3f295c78214a82] | ||
11 | Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> | ||
12 | --- | ||
13 | mesonbuild/minstall.py | 2 +- | ||
14 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
15 | |||
16 | diff --git a/mesonbuild/minstall.py b/mesonbuild/minstall.py | ||
17 | index 785ff5869..07da408aa 100644 | ||
18 | --- a/mesonbuild/minstall.py | ||
19 | +++ b/mesonbuild/minstall.py | ||
20 | @@ -148,7 +148,7 @@ def set_chown(path: str, user: T.Optional[str] = None, group: T.Optional[str] = | ||
21 | Use a real function rather than a lambda to help mypy out. Also real | ||
22 | functions are faster. | ||
23 | """ | ||
24 | - real_os_chown(path, gid, uid, dir_fd=dir_fd, follow_symlinks=follow_symlinks) | ||
25 | + real_os_chown(path, uid, gid, dir_fd=dir_fd, follow_symlinks=follow_symlinks) | ||
26 | |||
27 | try: | ||
28 | os.chown = chown | ||