Re: [meta-arm] [PATCH v3 1/2] optee-client: use udev rule and systemd service from upstream

Ross Burton <[email protected]>
Newsgroups org.yoctoproject.lists.meta-arm
Message-ID <[email protected]>
On 26 Nov 2024, at 14:55, Mikko Rapeli via lists.yoctoproject.org <[email protected]> wrote:
> This would only work if optee-client has "systemd" build time dependency in DEPENDS.
> I don't think we should add this dependency. The sd_notify() support for example
> dlopen()'s systemd libs at runtime to avoid making systemd a hard build time
> dependency. I don't think we should add this dependency due to systemd
> service file install paths.

If this was all my code, I’d be flexible: add a cmake option so the caller can do -DSYSTEMD_UNIT_DIR=…, but if that isn’t set then ask pkg-config for the systemdsystemconfdir.

Then in our recipes as we know that path is fixed, we can simply pass -DSYSTEMD_UNIT_DIR=${systemd_system_unitdir} when configuring and we don’t need to add a DEPENDS on systemd.   You can always pass that option to cmake, and inheriting the systemd class will result in the units being deleted if systemd isn’t actually enabled in DISTRO_FEATURES.

Ross
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.