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

Allow building with elogind #178

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

craftyguy
Copy link

This makes the runtime systemd dep requirement optional when building with -Dsystemd=true so that colord can be built with support for libsystemd on distros that use elogind. There should be no impact here when building colord on distros that use systemd, both libsystemd and systemd should exist in that case.

This makes the runtime systemd dep requirement optional when building
with -Dsystemd=true so that colord can be built with support for
libsystemd on distros that use elogind. There should be no impact here
when building colord on distros that use systemd, both libsystemd and
systemd should exist in that case.
@hughsie
Copy link
Owner

hughsie commented Jan 8, 2025

Why can't we use -Dsystemd=disabled for the elogind case?

@craftyguy
Copy link
Author

craftyguy commented Jan 8, 2025

@hughsie because the meson doesn't pull in libsystemd (and HAVE_SYSTEMD is unset for the #ifdef in code) if that option is not enabled, so elogind isn't actually used for the seat stuff, etc

Sorry this might not be obvious, but elogind provides libsystemd.pc and is compatible with libsystemd

@hughsie
Copy link
Owner

hughsie commented Jan 8, 2025

but elogind provides libsystemd.pc and is compatible with libsystemd

Then I'm double confused; why can't systems using elogind just use -Dsystemd=enabled??

@craftyguy
Copy link
Author

Because dependency('systemd') fails, nothing from elogind provides that, and you only use it to determine install paths for unit files, which is a runtime thing.

So this patch makes that 'systemd' dependency optional so it builds on systems with elogind, but still supports finding libsystemd (which elogind can provide) when using -Dsystemd=true for supporting the api

@hughsie
Copy link
Owner

hughsie commented Jan 9, 2025

I think elogind either needs to provide full compatibility with systemd or none; providing one of the two pkg-config files is super weird and adds to the maintenance burden.

@craftyguy
Copy link
Author

craftyguy commented Jan 9, 2025 via email

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.

2 participants