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

remove libsystemd dependency #5660

Merged
merged 4 commits into from Apr 20, 2024
Merged

remove libsystemd dependency #5660

merged 4 commits into from Apr 20, 2024

Conversation

cnt0
Copy link
Contributor

@cnt0 cnt0 commented Apr 20, 2024

(I messed stuff up with git branches so decided to create a new PR instead of the old one)

Hello. This PR introduces home-baked sd_booted and sd_notify functions, so it's now possible to completely remove the libsystemd dependency as per Lennart Poettering's advice

I'd recommend apps to just embed their own minimal version of the sd_notify() protocol, in their native language. It's trivial, and nowadays even in crazy languages like Java you have AF_UNIX support that is sufficient to implement it in a few lines of code.

I copied sd_booted almost as-is from libsystemd. As for sd_notify, I've been looking at python implementation and its documented behavior.

This code is entirely untested, other than "it compiles", so please test it before merging (if you'd like to merge this PR, that is)

@cnt0
Copy link
Contributor Author

cnt0 commented Apr 20, 2024

#5582 (comment) - also adressed this review

vaxerski
vaxerski previously approved these changes Apr 20, 2024
Copy link
Member

@vaxerski vaxerski left a comment

Choose a reason for hiding this comment

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

lgtm

@vaxerski
Copy link
Member

but yeah needs testing + nix fails @fufexan

@vaxerski vaxerski merged commit a945346 into hyprwm:main Apr 20, 2024
9 checks passed
@cnt0 cnt0 deleted the ditch-systemd2 branch April 21, 2024 06:32
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.

None yet

3 participants