Name: nqptp Version: 1.2.4 Release: 1%{?dist} Summary: Not Quite PTP License: GPLv2+ URL: https://github.com/mikebrady/nqptp Source: https://github.com/mikebrady/nqptp/archive/%{version}/nqptp-%{version}.tar.gz BuildRequires: gcc BuildRequires: autoconf BuildRequires: automake BuildRequires: make BuildRequires: systemd-rpm-macros %description nqptp is a daemon that monitors timing data from any PTP clocks – up to 64 – it sees on ports 319 and 320. It maintains records for each clock, identified by Clock ID and IP. It is a companion application to Shairport Sync and provides timing information for AirPlay 2 operation. %prep %autosetup -n %{name}-%{version} %build # Avoid creating user and groups during package build sed -i '/getent/d' Makefile.am # Fix systemd unit path sed -i 's!$(libdir)!/usr/lib!g' Makefile.am # Do not setcap during build sed -i '/setcap/d' Makefile.am # Fix systemd unit privileges sed -i 's!Group=nqptp!Group=nqptp\nAmbientCapabilities=CAP_NET_BIND_SERVICE!' nqptp.service.in autoreconf -fi %configure --with-systemd-startup %make_build %install %make_install %pre getent group %{name} &>/dev/null || groupadd -r %{name} &>/dev/null getent passwd %{name} &> /dev/null || useradd -r -M -g %{name} -s /sbin/nologin nqptp &>/dev/null %post %systemd_post %{name}.service %preun %systemd_preun %{name}.service %postun %systemd_postun_with_restart %{name}.service %files %license LICENSE %{_bindir}/%{name} %{_unitdir}/%{name}.service %changelog * Tue Oct 10 2023 Luca Magrone - 1.2.4 - Update to version 1.2.4 * Wed Mar 01 2023 Luca Magrone - 1.1.git.5672c33 - Initial package release