Convert EPEL9 gpsd to gpsd-epel with just gpsd-libs, gpsd-devel and python3-gpsd

epel9
Troy Dawson 1 year ago
parent 7ed95c9e87
commit dbd83e4a62

@ -1,3 +1,8 @@
# This spec file is derived from the EPEL9 gpsd spec file.
%global rhel_name gpsd
%global _debugsource_template %{nil}
%global debug_package %{nil}
%global _hardened_build 1 %global _hardened_build 1
%global with_qt 1 %global with_qt 1
@ -6,7 +11,7 @@
%endif %endif
Name: gpsd Name: gpsd-epel
Version: 3.23.1 Version: 3.23.1
Release: 1%{?dist} Release: 1%{?dist}
Epoch: 1 Epoch: 1
@ -14,7 +19,7 @@ Summary: Service daemon for mediating access to a GPS
License: BSD License: BSD
URL: http://catb.org/gpsd/ URL: http://catb.org/gpsd/
Source0: https://download-mirror.savannah.gnu.org/releases/gpsd/%{name}-%{version}.tar.gz Source0: https://download-mirror.savannah.gnu.org/releases/gpsd/%{rhel_name}-%{version}.tar.gz
Source11: gpsd.sysconfig Source11: gpsd.sysconfig
# Add old status names to gps.h for compatibility # Add old status names to gps.h for compatibility
@ -43,10 +48,6 @@ BuildRequires: qt-devel
BuildRequires: libusb1-devel BuildRequires: libusb1-devel
%endif %endif
Requires: %{name}-libs%{?_isa} = %{epoch}:%{version}-%{release}
Requires: udev
%{?systemd_requires}
%description %description
gpsd is a service daemon that mediates access to a GPS sensor gpsd is a service daemon that mediates access to a GPS sensor
connected to the host computer by serial or USB interface, making its connected to the host computer by serial or USB interface, making its
@ -57,60 +58,33 @@ can share access to a GPS without contention or loss of data. Also,
gpsd responds to queries with a format that is substantially easier to gpsd responds to queries with a format that is substantially easier to
parse than NMEA 0183. parse than NMEA 0183.
%package libs %package -n %{rhel_name}-libs
Summary: Client libraries in C for talking to a running gpsd or GPS Summary: Client libraries in C for talking to a running gpsd or GPS
%description libs %description -n %{rhel_name}-libs
This package contains the gpsd libraries that manage access This package contains the gpsd libraries that manage access
to a GPS for applications. to a GPS for applications.
%package -n python3-%{name} %package -n python3-%{rhel_name}
Summary: Python libraries and modules for use with gpsd Summary: Python libraries and modules for use with gpsd
Requires: %{name}-libs%{?_isa} = %{epoch}:%{version}-%{release} Requires: %{rhel_name}-libs%{?_isa} = %{epoch}:%{version}
%{?python_provide:%python_provide python3-%{name}} %{?python_provide:%python_provide python3-%{rhel_name}}
%description -n python3-%{name} %description -n python3-%{rhel_name}
This package contains the python3 modules that manage access to a GPS for This package contains the python3 modules that manage access to a GPS for
applications. applications.
%package devel %package -n %{rhel_name}-devel
Summary: Development files for the gpsd library Summary: Development files for the gpsd library
Requires: %{name}-libs%{?_isa} = %{epoch}:%{version}-%{release} Requires: %{rhel_name}-libs%{?_isa} = %{epoch}:%{version}
%description devel %description -n %{rhel_name}-devel
This package provides C header files for the gpsd shared libraries that This package provides C header files for the gpsd shared libraries that
manage access to a GPS for applications manage access to a GPS for applications
%if %{with_qt}
%package qt
Summary: C++/Qt5 bindings for the gpsd library
Requires: %{name}-libs%{?_isa} = %{epoch}:%{version}-%{release}
%description qt
This package provide C++ and Qt bindings for use with the libgps library from
gpsd.
%package qt-devel
Summary: Development files for the C++/Qt5 bindings for the gpsd library
Requires: %{name}-libs%{?_isa} = %{epoch}:%{version}-%{release}
Requires: %{name}-qt%{?_isa} = %{epoch}:%{version}-%{release}
%description qt-devel
This package provides the development files for the C++ and Qt bindings for use
with the libgps library from gpsd.
%endif
%package clients
Summary: Clients for gpsd
Requires: python3-%{name} = %{epoch}:%{version}-%{release}
Requires: python3-pyserial
Requires: %{name}-libs%{?_isa} = %{epoch}:%{version}-%{release}
%description clients
This package contains various clients using gpsd.
%prep %prep
%setup -q %setup -q -n %{rhel_name}-%{version}
%patch1 -p1 -b .apistatus %patch1 -p1 -b .apistatus
# don't try reloading systemd when installing in the build root # don't try reloading systemd when installing in the build root
@ -188,120 +162,35 @@ desktop-file-install \
rm -rf %{buildroot}%{_docdir}/gpsd rm -rf %{buildroot}%{_docdir}/gpsd
%post # remove files shipped in RHEL
%systemd_post gpsd.service gpsd.socket rm -rf %{buildroot}%{_sbindir}
rm -rf %{buildroot}%{_bindir}
%preun rm -rf %{buildroot}%{_sysconfdir}
%systemd_preun gpsd.service gpsd.socket rm -rf %{buildroot}%{_unitdir}
rm -rf %{buildroot}%{_udevrulesdir}
%postun rm -rf %{buildroot}%{_datadir}
# Don't restart the service rm -rf %{buildroot}%{_mandir}
%systemd_postun gpsd.service gpsd.socket
%ldconfig_scriptlets libs
%if %{with_qt} %files -n %{rhel_name}-libs
%ldconfig_scriptlets qt
%endif
%files
%doc README.adoc NEWS
%license COPYING
%config(noreplace) %{_sysconfdir}/sysconfig/%{name}
%{_sbindir}/gpsd
%{_sbindir}/gpsdctl
%{_sbindir}/gpsinit
%{_bindir}/gpsmon
%{_bindir}/gpsctl
%{_bindir}/ntpshmmon
%{_bindir}/ppscheck
%{_unitdir}/gpsd.service
%{_unitdir}/gpsd.socket
%{_unitdir}/gpsdctl@.service
%{_udevrulesdir}/*.rules
%{_mandir}/man8/gpsd.8*
%{_mandir}/man8/gpsdctl.8*
%{_mandir}/man8/gpsinit.8*
%{_mandir}/man8/ppscheck.8*
%{_mandir}/man1/gpsmon.1*
%{_mandir}/man1/gpsctl.1*
%{_mandir}/man1/ntpshmmon.1*
%files libs
%{_libdir}/libgps.so.29* %{_libdir}/libgps.so.29*
%files -n python3-%{name} %files -n python3-%{rhel_name}
%{_libdir}/libgpsdpacket.so* %{_libdir}/libgpsdpacket.so*
%{python3_sitearch}/gps* %{python3_sitearch}/gps*
%files devel %files -n %{rhel_name}-devel
%doc TODO HACKING %doc TODO HACKING
%{_libdir}/libgps.so %{_libdir}/libgps.so
%{_libdir}/pkgconfig/libgps.pc %{_libdir}/pkgconfig/libgps.pc
%{_includedir}/gps.h %{_includedir}/gps.h
%{_includedir}/libgpsmm.h %{_includedir}/libgpsmm.h
%{_mandir}/man3/libgps.3*
%{_mandir}/man3/libgpsmm.3*
%{_mandir}/man5/gpsd_json.5*
%if %{with_qt}
%files qt
%{_libdir}/libQgpsmm.so.29*
%files qt-devel
%{_libdir}/libQgpsmm.so
%{_libdir}/libQgpsmm.prl
%{_libdir}/pkgconfig/Qgpsmm.pc
%{_mandir}/man3/libQgpsmm.3*
%endif
%files clients
%{_bindir}/cgps
%{_bindir}/gegps
%{_bindir}/gps2udp
%{_bindir}/gpscat
%{_bindir}/gpscsv
%{_bindir}/gpsdebuginfo
%{_bindir}/gpsdecode
%{_bindir}/gpspipe
%{_bindir}/gpsplot
%{_bindir}/gpsprof
%{_bindir}/gpsrinex
%{_bindir}/gpssnmp
%{_bindir}/gpssubframe
%{_bindir}/gpxlogger
%{_bindir}/lcdgps
%{_bindir}/xgps
%{_bindir}/xgpsspeed
%{_bindir}/gpsfake
%{_bindir}/ubxtool
%{_bindir}/zerk
%{_mandir}/man1/gegps.1*
%{_mandir}/man1/gps.1*
%{_mandir}/man1/gps2udp.1*
%{_mandir}/man1/gpscsv.1*
%{_mandir}/man1/gpsdebuginfo.1*
%{_mandir}/man1/gpsdecode.1*
%{_mandir}/man1/gpspipe.1*
%{_mandir}/man1/gpsplot.1*
%{_mandir}/man1/gpsprof.1*
%{_mandir}/man1/gpsrinex.1*
%{_mandir}/man1/gpssnmp.1*
%{_mandir}/man1/gpssubframe.1*
%{_mandir}/man1/gpxlogger.1*
%{_mandir}/man1/lcdgps.1*
%{_mandir}/man1/xgps.1*
%{_mandir}/man1/xgpsspeed.1*
%{_mandir}/man1/cgps.1*
%{_mandir}/man1/gpscat.1*
%{_mandir}/man1/gpsfake.1*
%{_mandir}/man1/ubxtool.1*
%{_mandir}/man1/zerk.1*
%{_datadir}/applications/*.desktop
%dir %{_datadir}/gpsd
%{_datadir}/gpsd/gpsd-logo.png
%changelog %changelog
* Fri Sep 08 2023 Troy Dawson <tdawson@redhat.com> - 1:3.23.1-1
- Convert EPEL9 gpsd to gpsd-epel with just gpsd-libs, gpsd-devel and python3-gpsd
* Mon Sep 27 2021 Miroslav Lichvar <mlichvar@redhat.com> - 1:3.23.1-1 * Mon Sep 27 2021 Miroslav Lichvar <mlichvar@redhat.com> - 1:3.23.1-1
- update to 3.23.1 - update to 3.23.1
- add old status names to gps.h for compatibility - add old status names to gps.h for compatibility

Loading…
Cancel
Save