Actually use /usr/libexec/fwupd/fwupd

It appears the enormity of replacing a directory with a file is just too much
for package managers in 2017.

I guess we might ship other things in /usr/libexec/fwupd/ in the future.
This commit is contained in:
Richard Hughes 2017-04-19 08:50:49 +01:00
parent e07a6ddf6e
commit a9a99bdb48
4 changed files with 5 additions and 13 deletions

View File

@ -119,15 +119,6 @@ mkdir -p --mode=0700 $RPM_BUILD_ROOT%{_localstatedir}/lib/fwupd/gnupg
%find_lang %{name}
# /usr/libexec/fwupd used to be a directory, and now it's a file and
# rpm seems completely unable to cope with this
# see https://bugzilla.redhat.com/show_bug.cgi?id=447156 for details
%pretrans -p <lua>
st = posix.stat("/usr/libexec/fwupd")
if st and st.type == "directory" then
os.execute("rm -rf /usr/libexec/fwupd")
end
%post
/sbin/ldconfig
%systemd_post fwupd.service
@ -146,7 +137,8 @@ end
%doc README.md AUTHORS NEWS
%license COPYING
%config(noreplace)%{_sysconfdir}/fwupd.conf
%{_libexecdir}/fwupd
%dir %{_libexecdir}/fwupd
%{_libexecdir}/fwupd/fwupd
%{_bindir}/fwupdmgr
%{_sysconfdir}/pki/fwupd
%{_sysconfdir}/pki/fwupd-metadata

View File

@ -7,7 +7,7 @@ Before=gdm.service
[Service]
Type=dbus
BusName=org.freedesktop.fwupd
ExecStart=@libexecdir@/fwupd
ExecStart=@libexecdir@/fwupd/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=@libexecdir@/fwupd
Exec=@libexecdir@/fwupd/fwupd
User=root
SystemdService=fwupd.service

View File

@ -74,7 +74,7 @@ executable(
'-DFU_OFFLINE_DESTDIR=""',
],
install : true,
install_dir : 'libexec'
install_dir : 'libexec/fwupd'
)
if get_option('enable-tests')