Install the daemon in libexecdir

I know Debian doesn't use libexecdir, but most other distros do. On Fedora it's
really strange to see a binary in /usr/libexec/fwupd/fwupd and supporting this
not-quite-servicedir is causing confusion in the Makefiles and also problems in
other external tools.

Simply redefine libexecdir if you need the daemon binary to be installed
somewhere different.
This commit is contained in:
Richard Hughes 2017-04-12 14:38:28 +01:00
parent c232db23df
commit a1585c6b7f
4 changed files with 4 additions and 5 deletions

View File

@ -143,8 +143,7 @@ make check VERBOSE=1
%doc README.md AUTHORS NEWS
%license COPYING
%config(noreplace)%{_sysconfdir}/fwupd.conf
%dir %{_libexecdir}/fwupd
%{_libexecdir}/fwupd/fwupd
%{_libexecdir}/fwupd
%{_bindir}/fwupdmgr
%{_sysconfdir}/pki/fwupd
%{_sysconfdir}/pki/fwupd-metadata

View File

@ -17,7 +17,7 @@ $(dbusservicemain_DATA): $(dbusservicemain_in_files) Makefile
sed -e "s|\@daemon_user\@|$(daemon_user)|" > $@
%.service: %.service.in Makefile
$(AM_V_GEN)sed -e 's|\@servicedir\@|$(libexecdir)|' \
$(AM_V_GEN)sed -e 's|\@libexecdir\@|$(libexecdir)|' \
-e 's|\@localstatedir\@|$(localstatedir)|' \
-e 's|\@bootdir\@|$(bootdir)|' \
-e 's|\@bindir\@|$(bindir)|' \

View File

@ -7,7 +7,7 @@ Before=gdm.service
[Service]
Type=dbus
BusName=org.freedesktop.fwupd
ExecStart=@servicedir@/fwupd/fwupd
ExecStart=@libexec@/fwupd
MemoryDenyWriteExecute=yes
PrivateTmp=yes
ProtectControlGroups=yes

View File

@ -1,6 +1,6 @@
[D-BUS Service]
Name=org.freedesktop.fwupd
Documentation=http://www.fwupd.org/
Exec=@servicedir@/fwupd/fwupd
Exec=@libexecdir@/fwupd
User=root
SystemdService=fwupd.service