Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

meson: use meson-make-symlink.sh helper script instead of install_symlink() #327

Merged
merged 1 commit into from
Feb 27, 2023

Conversation

slyon
Copy link
Collaborator

@slyon slyon commented Feb 27, 2023

Description

meson: use meson-make-symlink.sh helper script instead of install_symlink()

This will allow to dynamically adopt the symlinks for usrmerged and non-usrmerged installations, especially:
root@ll:~# pkgconf --variable=systemdsystemgeneratordir systemd /lib/systemd/system-generators

[root@f37 ~]# pkgconf --variable=systemdsystemgeneratordir systemd /usr/lib/systemd/system-generators

Helper script inspired by util-linux 238.1-5 (tools/meson-make-symlink.sh)

Related to #323

Checklist

  • Runs make check successfully.
  • Retains 100% code coverage (make check-coverage).
  • New/changed keys in YAML format are documented.
  • (Optional) Adds example YAML for new feature.
  • (Optional) Closes an open bug in Launchpad.

…link()

This will allow to dynamically adopt the symlinks for usrmerged and
non-usrmerged installations, especially:
root@ll:~# pkgconf --variable=systemdsystemgeneratordir systemd
/lib/systemd/system-generators

[root@f37 ~]# pkgconf --variable=systemdsystemgeneratordir systemd
/usr/lib/systemd/system-generators

Helper script inspired by util-linux 238.1-5 (tools/meson-make-symlink.sh)
@slyon
Copy link
Collaborator Author

slyon commented Feb 27, 2023

This seems to be working for both cases:

$ tree tmproot/
tmproot/                                                   
├── lib                                                    
│   └── systemd                                            
│       └── system-generators
│           └── netplan -> ../../../usr/libexec/netplan/generate
└── usr
    ├── libexec
    │   └── netplan
    │       ├── generate

$ tree tmproot/
tmproot/                                                   
└── usr                                                    
    ├── lib
    │   ├── systemd
    │   │   └── system-generators
    │   │       └── netplan -> ../../../libexec/netplan/generate
    │   └── [...]
    ├── libexec
    │   └── netplan
    │       ├── generate

@slyon
Copy link
Collaborator Author

slyon commented Feb 27, 2023

I've also talked to our systemd maintainer, and we will coordinate with Debian to adopt the systemd packaging to install stuff in /usr/lib/systemd/... instead of /lib/systemd/... (+ adopting corresponding pkgconf files).

@slyon
Copy link
Collaborator Author

slyon commented Feb 27, 2023

cc @Conan-Kudo @xnox WDYT about this?

@Conan-Kudo
Copy link
Contributor

I've also talked to our systemd maintainer, and we will coordinate with Debian to adopt the systemd packaging to install stuff in /usr/lib/systemd/... instead of /lib/systemd/... (+ adopting corresponding pkgconf files).

This needs to be done anyway, since systemd is ripping out support for non-usrmerged systems soon. It'd be great to see this in place for Lunar at least.

Copy link
Contributor

@xnox xnox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, --relative is best, as this avoids the need for distro packaging tools to fix things up later, like rpm scriplets do, or like dh_link in debian world.

@slyon
Copy link
Collaborator Author

slyon commented Feb 27, 2023

This needs to be done anyway, since systemd is ripping out support for non-usrmerged systems soon. It'd be great to see this in place for Lunar at least.

Agreed. Lunar is post-FeatureFreeze already, so unfortunately I doubt the systemd change will still be landed in Lunar. But should be in Lunar+1

@slyon slyon merged commit 2cded2f into canonical:main Feb 27, 2023
@Conan-Kudo
Copy link
Contributor

This needs to be done anyway, since systemd is ripping out support for non-usrmerged systems soon. It'd be great to see this in place for Lunar at least.

Agreed. Lunar is post-FeatureFreeze already, so unfortunately I doubt the systemd change will still be landed in Lunar. But should be in Lunar+1

I think this is honestly worthy of an exception, but my voice doesn't really matter here...

@slyon
Copy link
Collaborator Author

slyon commented Feb 27, 2023

This needs to be done anyway, since systemd is ripping out support for non-usrmerged systems soon. It'd be great to see this in place for Lunar at least.

Agreed. Lunar is post-FeatureFreeze already, so unfortunately I doubt the systemd change will still be landed in Lunar. But should be in Lunar+1

I think this is honestly worthy of an exception, but my voice doesn't really matter here...

Your voice and input is highly appreciated! I've been told that some discussion around this usrmerge change has been happening in IRC #debian-systemd recently. But as both Debian and Ubuntu are currently in freeze, I assume the maintainers won't land such impactful change anymore (it will require changes to many more packages, like Netplan, which use systemd's pkgconf data). I'll try to re-ping people about, tho, and make them aware of this discussion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants