$ fwupdtool -h
fwupdtool: error while loading shared libraries: libpassim.so.1:
cannot open shared object file: No such file or directory
Comment by CS (JMP64i) - Thursday,
07 September 2023, 23:46 GMT
Hmm... It's inconvenient because I don't want to install avahi and
passim, which I actually don't need either. Passim can't start
without avahi and my monitoring always gives an error for this. Is
there a way to make it optional?
It is optional, but since it's a build-time decision there would
need to be two packages (e.g. fwupd and fwupd-nopassim).
Up to the package owners if they want to build without it (IMHO
preferable, passim depending on avahi isn't great as evidenced by
this request).
Could you report this upstream and check with them if they could
make libpassim an optional runtime dependency? I think this would
be the best way for everyone.
It already is an optional dependency (see the release notes
https://github.com/fwupd/fwupd/releases/tag/1.9.5), hence that flag existing.
You as the packager need to decide if you want to build without it
or not. With will force Arch users to have passim and its
dependencies (the current way), without will prevent Arch users
from using the new passim cache (unless they build it themselves
or make an aur version with passim enabled).
Feel free to suggest this to upstream, for now they seem to have
decided to go for the easier option.
Please note that tons of packages and projects have
build-time-only decisions about what is and isn't optional, fwupd
isn't being weird here.
As currently built, it's not optional.
$ readelf -d /usr/lib/fwupd-1.9.5/libfwupdengine.so | grep passim
0x0000000000000001 (NEEDED) Shared library: [libpassim.so.1]
$ fwupdtool -h
fwupdtool: error while loading shared libraries: libpassim.so.1: cannot open shared object file: No such file or directory
Hmm... It's inconvenient because I don't want to install avahi and passim, which I actually don't need either. Passim can't start without avahi and my monitoring always gives an error for this. Is there a way to make it optional?
> Is there a way to make it optional?
Dunno. Maybe if passim libs were split out? Someone would need to test it. But is it worth it? Maybe there's another way to prevent the service fail?
It is optional, but since it's a build-time decision there would need to be two packages (e.g. fwupd and fwupd-nopassim).
Up to the package owners if they want to build without it (IMHO preferable, passim depending on avahi isn't great as evidenced by this request).
FWIW the required changes are:
--- PKGBUILD
+++ PKGBUILD
@@ -26,7 +26,6 @@
libjcat
libjson-glib-1.0.so
libmm-glib.so
- libpassim.so
libprotobuf-c.so
libqmi-glib.so
libsmbios
@@ -78,7 +77,8 @@
-D docs=enabled \
-D plugin_intel_spi=true \
-D supported_build=enabled \
- -D efi_binary=false
+ -D efi_binary=false \
+ -D passim=disabled
meson compile -C build
}
Could you report this upstream and check with them if they could make libpassim an optional runtime dependency? I think this would be the best way for everyone.
It already is an optional dependency (see the release notes https://github.com/fwupd/fwupd/releases/tag/1.9.5), hence that flag existing.
You as the packager need to decide if you want to build without it or not. With will force Arch users to have passim and its dependencies (the current way), without will prevent Arch users from using the new passim cache (unless they build it themselves or make an aur version with passim enabled).
There are dlopen() and dlsym() to be able to depend on shared objects at runtime optionally.
Feel free to suggest this to upstream, for now they seem to have decided to go for the easier option.
Please note that tons of packages and projects have build-time-only decisions about what is and isn't optional, fwupd isn't being weird here.
That was already suggested above...