commit 8e8716018bbc1dba6f83de4e6bc8b7a8c710f4e1 Author: Zbigniew Jędrzejewski-Szmek Date: Sat Feb 20 13:06:34 2021 +0100 First version diff --git a/plocate.spec b/plocate.spec new file mode 100644 index 0000000..16eb1a2 --- /dev/null +++ b/plocate.spec @@ -0,0 +1,67 @@ +Name: plocate +Version: 1.1.4 +Release: 1%{?dist} +Summary: Much faster locate + +License: GPLv2+ +URL: https://plocate.sesse.net/ +Source0: https://git.sesse.net/?p=plocate;a=snapshot;h=1.1.4;sf=tgz#/plocate-%{version}.tar.gz +%global shortcommit 3c1980d +Source1: plocate.sysusers + +BuildRequires: meson +BuildRequires: gcc-c++ +BuildRequires: pkgconfig(systemd) +BuildRequires: pkgconfig(liburing) +BuildRequires: pkgconfig(libzstd) +BuildRequires: libatomic + +%description +plocate is a locate(1) based on posting lists, giving much faster +searches on a much smaller index. It is a drop-in replacement for +mlocate in nearly all aspects, and is fast on SSDs and non-SSDs alike. + +%prep +%autosetup -n plocate-%{version}-%{shortcommit} + +%build +%meson -Dupdatedb_progname=plocate-updatedb +%meson_build + +%install +%meson_install + +install -p -D -m 0644 %{SOURCE1} %{buildroot}%{_sysusersdir}/plocate.conf + +%pre +%sysusers_create_compat %{SOURCE1} + +%post +%systemd_post plocate-updatedb.service plocate-updatedb.timer + +%preun +%systemd_preun plocate-updatedb.service plocate-updatedb.timer + +%postun +%systemd_postun_with_restart plocate-updatedb.service plocate-updatedb.timer + +%files +%license COPYING +%doc README +%attr(02755,-,plocate) %_bindir/plocate +%_sbindir/plocate-build +%_sbindir/plocate-updatedb +%_unitdir/plocate-updatedb.service +%_unitdir/plocate-updatedb.timer +%_mandir/man1/plocate.1* +%_mandir/man5/updatedb.conf.5* +%_mandir/man8/plocate-build.8* +%_mandir/man8/plocate-updatedb.8* +%_sysusersdir/plocate.conf +%dir /var/lib/plocate +/var/lib/plocate/CACHEDIR.TAG +%exclude /usr/lib/debug + +%changelog +* Fri Feb 19 2021 Zbigniew Jędrzejewski-Szmek - 1.1.4-1 +- First version diff --git a/plocate.sysusers b/plocate.sysusers new file mode 100644 index 0000000..ed2917c --- /dev/null +++ b/plocate.sysusers @@ -0,0 +1 @@ +g plocate -