File gr-satellites.spec of Package gr-satellites
#
# spec file for package gr-satellites
#
# Copyright (c) 2024 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define soname 5_6_0
%define libname libgnuradio-satellites%{soname}
Name: gr-satellites
Version: 5.6.0
Release: 0
Summary: Collection of telemetry decoders for GNU Radio
License: GPL-3.0-only
URL: https://github.com/daniestevez/gr-satellites
Source0: %{name}-%{version}.tar.gz
BuildRequires: cmake
BuildRequires: dos2unix
BuildRequires: doxygen
BuildRequires: gcc-c++
BuildRequires: gnuradio-devel
BuildRequires: gmp-devel
BuildRequires: libboost_date_time-devel
BuildRequires: libboost_program_options-devel
BuildRequires: libboost_regex-devel
BuildRequires: libboost_system-devel
BuildRequires: libboost_test-devel
BuildRequires: libboost_thread-devel
BuildRequires: python3-devel
BuildRequires: python3-pybind11-devel
BuildRequires: python3-numpy-devel
BuildRequires: volk-devel
Requires : python3-construct
Requires : python3-websocket-client
%package -n %{libname}
Summary: Library for %{name}
%package devel
Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release}
%package devel-doc
Summary: Documentation for %{name}
Requires: %{name} = %{version}-%{release}
BuildArch: noarch
%description
%{name} is a GNU Radio out-of-tree module encompassing a collection of telemetry decoders that supports many different Amateur satellites
%description -n %{libname}
Library files for %{name}
%description devel
Development files for %{name} module for GNURadio
%description devel-doc
Documentation for %{name} module for GNU Radio.
%prep
%autosetup
%build
%cmake
%cmake_build
%install
%cmake_install
# fix documentation location
mkdir -p %{buildroot}%{_docdir}/%{name}
mv %{buildroot}/%{_datadir}/doc/%{name}/html %{buildroot}%{_docdir}/%{name}
mv %{buildroot}/%{_datadir}/doc/%{name}/xml %{buildroot}%{_docdir}/%{name}
# file line ending
dos2unix %{buildroot}%{python3_sitearch}/satellites/telemetry/*.py
%ldconfig_scriptlets -n %{libname}
%files
%license LICENSE
%doc README.md
%{_mandir}/man1/gr_satellites.1.gz
%{_mandir}/man1/jy1sat_ssdv.1.gz
%{_mandir}/man1/smog_p_spectrum.1.gz
%{_bindir}/erminaz_ssdv
%{_bindir}/gr_satellites
%{_bindir}/jy1sat_ssdv
%{_bindir}/smog_p_spectrum
%{_datadir}/gnuradio/grc/blocks/satellites_*.yml
%{_datadir}/gnuradio/grc/blocks/variable_time_format_parameters.block.yml
%{python3_sitearch}/satellites/
%files -n %{libname}
%{_libdir}/libgnuradio-satellites.so.*
%files devel
%{_includedir}/satellites/
%{_libdir}/libgnuradio-satellites.so
%{_libdir}/cmake/satellites/
%files devel-doc
%{_docdir}/%{name}/html
%{_docdir}/%{name}/xml
%changelog