From: Jörg Sommer <joerg.som...@navimatix.de>

This reverts "systemd: Fix rootfs transaction error when PACKAGECONFIG has
polkit" [1], because the opposite situation came true. When building with

```
INIT_MANAGER = "systemd"
DISTRO_FEATURES:append = " polkit usrmerge"
IMAGE_INSTALL:append = " polkit"
```

the build fails with

```
Error: Transaction test error:
  file /usr/share/polkit-1/rules.d conflicts between attempted installs of 
polkit-125-r0.core2_64 and systemd-1:256.5-r0.core2_64
```

Looking at the rpms you can see the mismatch:

```
% rpm2archive - <build/tmp/deploy/rpm/core2_64/systemd-256.5-r0.core2_64.rpm 
|tar vtz ./usr/share/polkit-1/rules.d
drwx------ polkitd/root      0 2024-08-15 22:46 ./usr/share/polkit-1/rules.d/
-rw-r--r-- root/root       527 2024-08-15 22:46 
./usr/share/polkit-1/rules.d/systemd-networkd.rules
% rpm2archive - <build/tmp/deploy/rpm/core2_64/polkit-125-r0.core2_64.rpm |tar 
vtz ./usr/share/polkit-1/rules.d
drwxr-xr-x root/root         0 2024-08-08 15:12 ./usr/share/polkit-1/rules.d/
-rw-r--r-- root/root       326 2024-08-08 15:12 
./usr/share/polkit-1/rules.d/50-default.rules
```

[1] 086ef2e5959ba3b6032a0c704e079f7eeadd1f25.

Signed-off-by: Jörg Sommer <joerg.som...@navimatix.de>
---
 meta/recipes-core/systemd/systemd_256.5.bb | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/meta/recipes-core/systemd/systemd_256.5.bb 
b/meta/recipes-core/systemd/systemd_256.5.bb
index 1485614c71..9d2b06472c 100644
--- a/meta/recipes-core/systemd/systemd_256.5.bb
+++ b/meta/recipes-core/systemd/systemd_256.5.bb
@@ -368,14 +368,6 @@ do_install() {
                rm -r ${D}${sysconfdir}/X11
        fi
 
-       # If polkit is setup fixup permissions and ownership
-       if ${@bb.utils.contains('PACKAGECONFIG', 'polkit', 'true', 'false', 
d)}; then
-               if [ -d ${D}${datadir}/polkit-1/rules.d ]; then
-                       chmod 700 ${D}${datadir}/polkit-1/rules.d
-                       chown polkitd:root ${D}${datadir}/polkit-1/rules.d
-               fi
-       fi
-
        # If polkit is not available and a fallback was requested, install a 
drop-in that allows networkd to
        # request hostname changes via DBUS without elevating its privileges
        if ${@bb.utils.contains('PACKAGECONFIG', 'polkit_hostnamed_fallback', 
'true', 'false', d)}; then
-- 
2.34.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#203967): 
https://lists.openembedded.org/g/openembedded-core/message/203967
Mute This Topic: https://lists.openembedded.org/mt/108178747/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to