Blame SPECS/fwupd.spec

f35dbb
# Enable hardening in RHEL 7
f35dbb
%global _hardened_build 1
f35dbb
af0569
%global glib2_version 2.45.8
f35dbb
%global libappstream_version 0.7.4
af0569
%global libgusb_version 0.2.9
af0569
%global libsoup_version 2.51.92
58cc86
%global systemd_version 219
f35dbb
%global json_glib_version 1.1.1
f35dbb
f35dbb
%global enable_tests 0
f35dbb
%global enable_dummy 0
af0569
f35dbb
# fwupdate is only available on these arches
af0569
%ifarch x86_64 aarch64
af0569
%global have_uefi 1
af0569
%endif
af0569
58cc86
# libsmbios is only available on x86, and fwupdate is available on just x86_64
58cc86
%ifarch x86_64
58cc86
%global have_dell 1
58cc86
%endif
58cc86
58cc86
# valgrind is not available on s390
58cc86
%ifarch x86_64 aarch64
58cc86
%global have_valgrind 1
58cc86
%endif
58cc86
af0569
Summary:   Firmware update daemon
af0569
Name:      fwupd
f35dbb
Version:   1.0.8
58cc86
Release:   4%{?dist}
f35dbb
License:   LGPLv2+
af0569
URL:       https://github.com/hughsie/fwupd
af0569
Source0:   http://people.freedesktop.org/~hughsient/releases/%{name}-%{version}.tar.xz
af0569
58cc86
# neuter the LVFS
af0569
Patch2:    0001-Do-not-use-the-LVFS.patch
f35dbb
Patch3:    0002-Do-not-use-Python-version-3.patch
58cc86
f35dbb
# backport
f35dbb
Patch6:    0001-Allow-running-on-an-older-systemd.patch
58cc86
af0569
BuildRequires: gettext
af0569
BuildRequires: glib2-devel >= %{glib2_version}
af0569
BuildRequires: libappstream-glib-devel >= %{libappstream_version}
af0569
BuildRequires: libgudev1-devel
af0569
BuildRequires: libgusb-devel >= %{libgusb_version}
af0569
BuildRequires: libsoup-devel >= %{libsoup_version}
af0569
BuildRequires: polkit-devel >= 0.103
af0569
BuildRequires: sqlite-devel
af0569
BuildRequires: gpgme-devel
58cc86
BuildRequires: systemd >= %{systemd_version}
af0569
BuildRequires: libarchive-devel
af0569
BuildRequires: gobject-introspection-devel
af0569
BuildRequires: gcab
58cc86
%if 0%{?have_valgrind}
58cc86
BuildRequires: valgrind
58cc86
BuildRequires: valgrind-devel
58cc86
%endif
f35dbb
BuildRequires: elfutils-libelf-devel
f35dbb
BuildRequires: gtk-doc
f35dbb
BuildRequires: libuuid-devel
f35dbb
BuildRequires: meson
f35dbb
BuildRequires: help2man
f35dbb
BuildRequires: json-glib-devel >= %{json_glib_version}
f35dbb
BuildRequires: vala
58cc86
58cc86
%if 0%{?have_dell}
58cc86
BuildRequires: efivar-devel
58cc86
BuildRequires: libsmbios-devel >= 2.3.0
58cc86
%endif
af0569
af0569
%if 0%{?have_uefi}
f35dbb
BuildRequires: fwupdate-devel >= 10
af0569
%endif
af0569
af0569
Requires(post): systemd
af0569
Requires(preun): systemd
af0569
Requires(postun): systemd
af0569
af0569
Requires: glib2%{?_isa} >= %{glib2_version}
af0569
Requires: libappstream-glib%{?_isa} >= %{libappstream_version}
af0569
Requires: libgusb%{?_isa} >= %{libgusb_version}
af0569
Requires: libsoup%{?_isa} >= %{libsoup_version}
af0569
af0569
Obsoletes: fwupd-sign < 0.1.6
af0569
Obsoletes: libebitdo < 0.7.5-3
af0569
af0569
%description
af0569
fwupd is a daemon to allow session software to update device firmware.
af0569
af0569
%package devel
af0569
Summary: Development package for %{name}
af0569
Requires: %{name}%{?_isa} = %{version}-%{release}
af0569
Obsoletes: libebitdo-devel < 0.7.5-3
f35dbb
Obsoletes: libdfu-devel < 1.0.0
af0569
af0569
%description devel
af0569
Files for development with %{name}.
af0569
af0569
%prep
af0569
%setup -q
af0569
%patch2 -p1 -b .no-lvfs
f35dbb
%patch3 -p1 -b .no-python3
f35dbb
%patch6 -p1 -b .old-systemd
af0569
af0569
%build
f35dbb
f35dbb
%meson \
f35dbb
    -Dpkcs7=false \
f35dbb
    -Dgtkdoc=true \
f35dbb
%if 0%{?enable_tests}
f35dbb
    -Dtests=true \
f35dbb
%else
f35dbb
    -Dtests=false \
f35dbb
%endif
f35dbb
%if 0%{?enable_dummy}
f35dbb
    -Dplugin_dummy=true \
f35dbb
%else
f35dbb
    -Dplugin_dummy=false \
f35dbb
%endif
f35dbb
    -Dplugin_thunderbolt=true \
af0569
%if 0%{?have_uefi}
f35dbb
    -Dplugin_uefi=true \
f35dbb
    -Dplugin_uefi_labels=false \
af0569
%else
f35dbb
    -Dplugin_uefi=false \
f35dbb
    -Dplugin_uefi_labels=false \
af0569
%endif
58cc86
%if 0%{?have_dell}
f35dbb
    -Dplugin_dell=true \
f35dbb
    -Dplugin_synaptics=true \
58cc86
%else
f35dbb
    -Dplugin_dell=false \
f35dbb
    -Dplugin_synaptics=false \
58cc86
%endif
f35dbb
    -Dman=true
af0569
f35dbb
%meson_build
f35dbb
f35dbb
%if 0%{?enable_tests}
f35dbb
%check
f35dbb
%meson_test
f35dbb
%endif
af0569
af0569
%install
f35dbb
%meson_install
af0569
f35dbb
mkdir -p --mode=0700 $RPM_BUILD_ROOT%{_localstatedir}/lib/fwupd/gnupg
af0569
af0569
%find_lang %{name}
af0569
af0569
%post
af0569
/sbin/ldconfig
af0569
%systemd_post fwupd.service
af0569
af0569
%preun
af0569
%systemd_preun fwupd.service
af0569
af0569
%postun
af0569
/sbin/ldconfig
af0569
%systemd_postun_with_restart fwupd.service
af0569
af0569
%files -f %{name}.lang
af0569
%doc README.md AUTHORS NEWS
af0569
%license COPYING
58cc86
%config(noreplace)%{_sysconfdir}/fwupd/daemon.conf
f35dbb
%if 0%{?have_uefi}
f35dbb
%config(noreplace)%{_sysconfdir}/fwupd/uefi.conf
f35dbb
%endif
af0569
%dir %{_libexecdir}/fwupd
af0569
%{_libexecdir}/fwupd/fwupd
f35dbb
%{_libexecdir}/fwupd/fwupdtool
58cc86
%{_bindir}/dfu-tool
af0569
%{_bindir}/fwupdmgr
58cc86
%dir %{_sysconfdir}/fwupd
58cc86
%dir %{_sysconfdir}/fwupd/remotes.d
f35dbb
%config(noreplace)%{_sysconfdir}/fwupd/remotes.d/fwupd.conf
f35dbb
%config(noreplace)%{_sysconfdir}/fwupd/remotes.d/lvfs.conf
f35dbb
%config(noreplace)%{_sysconfdir}/fwupd/remotes.d/lvfs-testing.conf
f35dbb
%config(noreplace)%{_sysconfdir}/fwupd/remotes.d/vendor.conf
f35dbb
%config(noreplace)%{_sysconfdir}/pki/fwupd
af0569
%{_sysconfdir}/pki/fwupd-metadata
af0569
%{_sysconfdir}/dbus-1/system.d/org.freedesktop.fwupd.conf
f35dbb
%{_datadir}/fwupd/metainfo/org.freedesktop.fwupd*.metainfo.xml
58cc86
%{_datadir}/fwupd/remotes.d/fwupd/metadata.xml
58cc86
%{_datadir}/fwupd/remotes.d/vendor/firmware/README.md
af0569
%{_datadir}/dbus-1/interfaces/org.freedesktop.fwupd.xml
af0569
%{_datadir}/polkit-1/actions/org.freedesktop.fwupd.policy
af0569
%{_datadir}/polkit-1/rules.d/org.freedesktop.fwupd.rules
af0569
%{_datadir}/dbus-1/system-services/org.freedesktop.fwupd.service
58cc86
%{_datadir}/man/man1/dfu-tool.1.gz
af0569
%{_datadir}/man/man1/fwupdmgr.1.gz
58cc86
%{_datadir}/metainfo/org.freedesktop.fwupd.metainfo.xml
f35dbb
%{_datadir}/fwupd/firmware-packager
af0569
%{_unitdir}/fwupd-offline-update.service
af0569
%{_unitdir}/fwupd.service
af0569
%{_unitdir}/system-update.target.wants/
af0569
%dir %{_localstatedir}/lib/fwupd
58cc86
%dir %{_datadir}/fwupd/quirks.d
58cc86
%{_datadir}/fwupd/quirks.d/*.quirk
58cc86
%{_localstatedir}/lib/fwupd/builder/README.md
af0569
%{_libdir}/libfwupd*.so.*
58cc86
%{_libdir}/girepository-1.0/Fwupd-2.0.typelib
af0569
/usr/lib/udev/rules.d/*.rules
58cc86
%dir %{_libdir}/fwupd-plugins-3
f35dbb
%{_libdir}/fwupd-plugins-3/libfu_plugin_altos.so
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_amt.so
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_colorhug.so
f35dbb
%{_libdir}/fwupd-plugins-3/libfu_plugin_csr.so
58cc86
%if 0%{?have_dell}
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_dell.so
58cc86
%endif
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_dfu.so
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_ebitdo.so
f35dbb
%{_libdir}/fwupd-plugins-3/libfu_plugin_nitrokey.so
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_steelseries.so
f35dbb
%if 0%{?have_dell}
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_synapticsmst.so
f35dbb
%endif
f35dbb
%if 0%{?enable_dummy}
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_test.so
f35dbb
%endif
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_thunderbolt.so
f35dbb
%{_libdir}/fwupd-plugins-3/libfu_plugin_thunderbolt_power.so
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_udev.so
af0569
%if 0%{?have_uefi}
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_uefi.so
af0569
%endif
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_unifying.so
58cc86
%{_libdir}/fwupd-plugins-3/libfu_plugin_upower.so
f35dbb
%{_libdir}/fwupd-plugins-3/libfu_plugin_wacomhid.so
af0569
%ghost %{_localstatedir}/lib/fwupd/gnupg
af0569
af0569
%files devel
58cc86
%{_datadir}/gir-1.0/Fwupd-2.0.gir
af0569
%{_datadir}/gtk-doc/html/libfwupd
f35dbb
%{_datadir}/vala/vapi
af0569
%{_includedir}/fwupd-1
af0569
%{_libdir}/libfwupd*.so
af0569
%{_libdir}/pkgconfig/fwupd.pc
af0569
af0569
%changelog
f35dbb
* Wed Sep 05 2018 Kalev Lember <klember@redhat.com> 1.0.8-4
f35dbb
- Build with full hardening enabled
f35dbb
- Resolves: #1616185
f35dbb
f35dbb
* Mon Jul 16 2018 Richard Hughes <rhughes@redhat.com> 1.0.8-3
f35dbb
- Backport a fix to allow properly running on older systemd versions.
f35dbb
- Resolves: #1601550
f35dbb
f35dbb
* Thu Jun 14 2018 Richard Hughes <rhughes@redhat.com> 1.0.8-2
f35dbb
- Build against the new libfwupdate
f35dbb
- Resolves: #1570028
f35dbb
f35dbb
* Fri Jun 08 2018 Richard Hughes <rhughes@redhat.com> 1.0.8-1
f35dbb
- New upstream release
f35dbb
- Resolves: #1570028
f35dbb
58cc86
* Mon Jan 08 2018 Richard Hughes <richard@hughsie.com> 1.0.1-4
58cc86
- Enable the libsmbios dependency to get the Dell plugin
58cc86
- Resolves: #1420913
58cc86
58cc86
* Thu Nov 23 2017 Richard Hughes <richard@hughsie.com> 1.0.1-3
58cc86
- Remove the runtime dep on bubblewrap.
58cc86
- Resolves: #1512620
58cc86
58cc86
* Tue Nov 14 2017 Richard Hughes <richard@hughsie.com> 1.0.1-2
58cc86
- Enable Synaptics MST hub updates.
58cc86
- Resolves: #1420913
58cc86
58cc86
* Thu Nov 09 2017 Richard Hughes <richard@hughsie.com> 1.0.1-1
58cc86
- Rebase to 1.0.1, specifically the wip/hughsie/rhel75 branch which adds
58cc86
  back the automake build system and lowers the required versions of deps.
58cc86
- This also un-neuters fwupd so that most of the plugins are functional,
58cc86
  for instance allowing updates of Thunderbolt controllers and Logitech
58cc86
  Unifying devices. However, the LVFS is still disabled.
58cc86
- Resolves: #1313086
af0569
af0569
* Mon May 08 2017 Richard Hughes <richard@hughsie.com> 0.8.2-2
af0569
- Do not use the LVFS by default.
af0569
- Resolves: #1380827
af0569
af0569
* Thu Apr 20 2017 Richard Hughes <richard@hughsie.com> 0.8.2-1
af0569
- Initial upload for RHEL.
af0569
- Resolves: #1380827