Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-emulation/virtualbox/
Date: Mon, 05 Sep 2022 01:22:45
Message-Id: 1662340743.6abf35b9907a61390aef371e6ead261ef036ab1d.sam@gentoo
1 commit: 6abf35b9907a61390aef371e6ead261ef036ab1d
2 Author: Viorel Munteanu <ceamac.paragon <AT> gmail <DOT> com>
3 AuthorDate: Sun Sep 4 08:28:24 2022 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Mon Sep 5 01:19:03 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6abf35b9
7
8 app-emulation/virtualbox: add check to pkg_pretend
9
10 Check /usr, /usr/lib are owned by root.
11
12 Closes: https://bugs.gentoo.org/749273
13 Signed-off-by: Viorel Munteanu <ceamac.paragon <AT> gmail.com>
14 Signed-off-by: Sam James <sam <AT> gentoo.org>
15
16 app-emulation/virtualbox/virtualbox-6.1.38.ebuild | 9 +++++++++
17 1 file changed, 9 insertions(+)
18
19 diff --git a/app-emulation/virtualbox/virtualbox-6.1.38.ebuild b/app-emulation/virtualbox/virtualbox-6.1.38.ebuild
20 index 25ec67b18ade..93c8ac5113f7 100644
21 --- a/app-emulation/virtualbox/virtualbox-6.1.38.ebuild
22 +++ b/app-emulation/virtualbox/virtualbox-6.1.38.ebuild
23 @@ -195,6 +195,15 @@ pkg_pretend() {
24 einfo "You have disabled the \"python\" USE flag. This will only"
25 einfo "disable the python bindings being installed."
26 fi
27 +
28 + # 749273
29 + local d=${ROOT}
30 + for i in usr "$(get_libdir)"; do
31 + d="${d}/$i"
32 + if [[ "$(stat -L -c "%g %u" "${d}")" != "0 0" ]]; then
33 + die "${d} should be owned by root, VirtualBox will not start otherwise"
34 + fi
35 + done
36 }
37
38 pkg_setup() {