forked from pool/gnuradio
- Add patches to fix builds on Factory + 0001-gr-fec-switch-possible-C-11-code-from-constexpr-to-j.patch + CMake-set-C++-standard-to-c++11-and-C-standard-to-C99.diff OBS-URL: https://build.opensuse.org/request/show/497388 OBS-URL: https://build.opensuse.org/package/show/hardware:sdr/gnuradio?expand=0&rev=10
353 lines
13 KiB
RPMSpec
353 lines
13 KiB
RPMSpec
#
|
|
# spec file for package gnuradio
|
|
#
|
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
|
#
|
|
# 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 http://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
Name: gnuradio
|
|
Version: 3.7.11
|
|
Release: 0
|
|
%define sover 3_7_11-0_0_0
|
|
%define sover_volk 1_3
|
|
Summary: GNU software radio
|
|
License: GPL-3.0+
|
|
Group: Productivity/Hamradio/Other
|
|
Url: http://gnuradio.org
|
|
Source: http://gnuradio.org/releases/gnuradio/gnuradio-%{version}.tar.gz
|
|
Source1: %{name}-rpmlintrc
|
|
# http://www.nathanwest.us/grc_to_37.sh
|
|
Source2: grc_to_37.sh
|
|
Patch0: CMake-set-C++-standard-to-c++11-and-C-standard-to-C99.diff
|
|
Patch1: 0001-gr-fec-switch-possible-C-11-code-from-constexpr-to-j.patch
|
|
BuildRequires: alsa-devel
|
|
BuildRequires: boost-devel
|
|
BuildRequires: cmake
|
|
BuildRequires: cppunit-devel
|
|
BuildRequires: doxygen
|
|
BuildRequires: fdupes
|
|
BuildRequires: fftw3-threads-devel
|
|
BuildRequires: gcc-c++
|
|
BuildRequires: gsl-devel
|
|
BuildRequires: libSDL-devel
|
|
BuildRequires: libjack-devel
|
|
BuildRequires: libxslt-python
|
|
BuildRequires: orc
|
|
BuildRequires: pkg-config
|
|
BuildRequires: portaudio-devel
|
|
BuildRequires: python-Cheetah
|
|
BuildRequires: python-Sphinx
|
|
BuildRequires: python-gtk
|
|
BuildRequires: python-lxml
|
|
BuildRequires: python-numpy
|
|
BuildRequires: python-qt4-devel
|
|
%if 0%{?suse_version} > 1320
|
|
BuildRequires: python-wxWidgets-3_0
|
|
%else
|
|
BuildRequires: python-wxWidgets
|
|
%endif
|
|
BuildRequires: qwt6-devel
|
|
BuildRequires: swig
|
|
BuildRequires: texlive-dvips
|
|
BuildRequires: texlive-latex
|
|
BuildRequires: uhd-devel
|
|
BuildRequires: update-desktop-files
|
|
BuildRequires: pkgconfig(libusb-1.0)
|
|
BuildRequires: pkgconfig(libxml-2.0)
|
|
Requires: python
|
|
Requires: python-Cheetah
|
|
Requires: python-gtk
|
|
Requires: python-lxml
|
|
Requires: python-numpy
|
|
Requires: python-qt4
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
%description
|
|
GNU Radio is a collection of software that when combined with minimal
|
|
hardware, allows the construction of radios where the actual waveforms
|
|
transmitted and received are defined by software. What this means is
|
|
that it turns the digital modulation schemes used in today's high
|
|
performance wireless devices into software problems.
|
|
|
|
%package wxgui
|
|
Summary: Libraries for GNU Radio
|
|
Group: System/Libraries
|
|
%if 0%{?suse_version} > 1320
|
|
Requires: python-wxWidgets-3_0
|
|
%else
|
|
Requires: python-wxWidgets
|
|
%endif
|
|
|
|
%description wxgui
|
|
GNU Radio is a collection of software that when combined with minimal
|
|
hardware, allows the construction of radios where the actual waveforms
|
|
transmitted and received are defined by software. What this means is
|
|
that it turns the digital modulation schemes used in today's high
|
|
performance wireless devices into software problems.
|
|
|
|
This package contains the wxgui blocks
|
|
|
|
%package -n libgnuradio-%{sover}
|
|
Summary: Libraries for GNU Radio
|
|
Group: System/Libraries
|
|
Obsoletes: libgnuradio0
|
|
|
|
%description -n libgnuradio-%{sover}
|
|
GNU Radio is a collection of software that when combined with minimal
|
|
hardware, allows the construction of radios where the actual waveforms
|
|
transmitted and received are defined by software. What this means is
|
|
that it turns the digital modulation schemes used in today's high
|
|
performance wireless devices into software problems.
|
|
|
|
This package contains the libraries for GNU Radio.
|
|
|
|
%package -n libvolk%{sover_volk}
|
|
Summary: Libraries for GNU Radio
|
|
Group: System/Libraries
|
|
Conflicts: libgnuradio0
|
|
Obsoletes: libvolk0_0_0
|
|
|
|
%description -n libvolk%{sover_volk}
|
|
GNU Radio is a collection of software that when combined with minimal
|
|
hardware, allows the construction of radios where the actual waveforms
|
|
transmitted and received are defined by software. What this means is
|
|
that it turns the digital modulation schemes used in today's high
|
|
performance wireless devices into software problems.
|
|
|
|
This package contains the Vector-Optimized Library of Kernels (VOLK)
|
|
|
|
%package devel
|
|
Summary: Deveopment files for GNU Radio
|
|
Group: Development/Libraries/C and C++
|
|
Requires: %{name} = %{version}
|
|
|
|
%description devel
|
|
GNU Radio is a collection of software that when combined with minimal
|
|
hardware, allows the construction of radios where the actual waveforms
|
|
transmitted and received are defined by software. What this means is
|
|
that it turns the digital modulation schemes used in today's high
|
|
performance wireless devices into software problems.
|
|
|
|
This package contains libraries and header files for developing
|
|
applications that use GNU Radio.
|
|
|
|
%package doc
|
|
Summary: GNU Radio documentation
|
|
Group: Documentation/HTML
|
|
Requires: %{name} = %{version}
|
|
BuildArch: noarch
|
|
|
|
%description doc
|
|
GNU Radio is a collection of software that when combined with minimal
|
|
hardware, allows the construction of radios where the actual waveforms
|
|
transmitted and received are defined by software. What this means is
|
|
that it turns the digital modulation schemes used in today's high
|
|
performance wireless devices into software problems.
|
|
|
|
This package contains documentation for GNU Radio.
|
|
|
|
%package examples
|
|
Summary: GNU Radio examples
|
|
Group: Productivity/Hamradio/Other
|
|
Requires: %{name} = %{version}
|
|
|
|
%description examples
|
|
GNU Radio is a collection of software that when combined with minimal
|
|
hardware, allows the construction of radios where the actual waveforms
|
|
transmitted and received are defined by software. What this means is
|
|
that it turns the digital modulation schemes used in today's high
|
|
performance wireless devices into software problems.
|
|
|
|
This package contains some examples of using GNU Radio.
|
|
|
|
%package examples-wxgui
|
|
Summary: GNU Radio wxgui examples
|
|
Group: Productivity/Hamradio/Other
|
|
Requires: %{name}-wxgui = %{version}
|
|
|
|
%description examples-wxgui
|
|
GNU Radio is a collection of software that when combined with minimal
|
|
hardware, allows the construction of radios where the actual waveforms
|
|
transmitted and received are defined by software. What this means is
|
|
that it turns the digital modulation schemes used in today's high
|
|
performance wireless devices into software problems.
|
|
|
|
This package contains the examples of using GNU Radio depending on wxWidgets.
|
|
|
|
%prep
|
|
%setup -q
|
|
# Workaround for Tumbleweed until GNURadio 3.8 is released
|
|
%if 0%{?suse_version} > 1320
|
|
%patch0 -p1
|
|
%patch1 -p1
|
|
%endif
|
|
# remove buildtime from documentation
|
|
sed -i 's|^HTML_TIMESTAMP = YES|HTML_TIMESTAMP = NO|' docs/doxygen/Doxyfile.in
|
|
sed -i 's|^HTML_TIMESTAMP = YES|HTML_TIMESTAMP = NO|' docs/doxygen/Doxyfile.swig_doc.in
|
|
|
|
%build
|
|
%cmake \
|
|
-DCMAKE_SHARED_LINKER_FLAGS=""
|
|
make -j2
|
|
|
|
%install
|
|
%cmake_install
|
|
|
|
install -d %{buildroot}%{_docdir}/%{name}
|
|
mv %{buildroot}/%{_datadir}/doc/%{name}-*/* %{buildroot}%{_docdir}/%{name}/
|
|
|
|
# recompile python modules to avoid timestamp problems
|
|
%py_compile %{buildroot}%{python_sitearch}
|
|
%py_compile -O %{buildroot}%{python_sitearch}
|
|
|
|
# install icons and desktop file
|
|
mkdir -p %{buildroot}%{_datadir}/icons/hicolor/32x32/apps
|
|
cp %{buildroot}%{_datadir}/gnuradio/grc/freedesktop/grc-icon-32.png %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/gnuradio-grc.png
|
|
mkdir -p %{buildroot}%{_datadir}/icons/hicolor/48x48/apps
|
|
cp %{buildroot}%{_datadir}/gnuradio/grc/freedesktop/grc-icon-48.png %{buildroot}%{_datadir}/icons/hicolor/48x48/apps/gnuradio-grc.png
|
|
mkdir -p %{buildroot}%{_datadir}/icons/hicolor/64x64/apps
|
|
cp %{buildroot}%{_datadir}/gnuradio/grc/freedesktop/grc-icon-64.png %{buildroot}%{_datadir}/icons/hicolor/64x64/apps/gnuradio-grc.png
|
|
mkdir -p %{buildroot}%{_datadir}/icons/hicolor/128x128/apps
|
|
cp %{buildroot}%{_datadir}/gnuradio/grc/freedesktop/grc-icon-128.png %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/gnuradio-grc.png
|
|
mkdir -p %{buildroot}%{_datadir}/icons/hicolor/256x256/apps
|
|
cp %{buildroot}%{_datadir}/gnuradio/grc/freedesktop/grc-icon-256.png %{buildroot}%{_datadir}/icons/hicolor/256x256/apps/gnuradio-grc.png
|
|
|
|
mkdir -p %{buildroot}%{_datadir}/applications
|
|
cp %{buildroot}%{_datadir}/gnuradio/grc/freedesktop/gnuradio-grc.desktop %{buildroot}%{_datadir}/applications
|
|
%suse_update_desktop_file -r %{buildroot}%{_datadir}/applications/gnuradio-grc.desktop Network HamRadio
|
|
|
|
install -m 755 %{SOURCE2} %{buildroot}/%{_bindir}
|
|
|
|
#remove unneeded stuff
|
|
rm -rf %{buildroot}%{_datadir}/%{name}/grc/freedesktop
|
|
rm -rf %{buildroot}%{_prefix}/libexec
|
|
|
|
%fdupes -s %{buildroot}%{_docdir}
|
|
%fdupes -s %{buildroot}%{_includedir}
|
|
%fdupes -s %{buildroot}%{_libdir}
|
|
|
|
%post -n libgnuradio-%{sover} -p /sbin/ldconfig
|
|
|
|
%post -n libvolk%{sover_volk} -p /sbin/ldconfig
|
|
|
|
%postun -n libgnuradio-%{sover} -p /sbin/ldconfig
|
|
|
|
%postun -n libvolk%{sover_volk} -p /sbin/ldconfig
|
|
|
|
%files
|
|
%defattr(-,root,root,-)
|
|
%doc COPYING
|
|
%{_bindir}/*
|
|
%dir %{_datadir}/gnuradio
|
|
%{_datadir}/gnuradio/grc/
|
|
%{_datadir}/gnuradio/modtool/
|
|
%{_datadir}/gnuradio/themes/
|
|
%{_datadir}/gnuradio/fec/
|
|
%{_datadir}/icons/hicolor/*/apps/gnuradio-grc.png
|
|
%{_datadir}/applications/gnuradio-grc.desktop
|
|
%{python_sitearch}/*
|
|
%dir %{_sysconfdir}/gnuradio
|
|
%dir %{_sysconfdir}/gnuradio/conf.d
|
|
%config(noreplace) %{_sysconfdir}/gnuradio/conf.d/*.conf
|
|
%dir %{_docdir}/%{name}/
|
|
%{_docdir}/%{name}/README*
|
|
# doc package
|
|
%exclude %{_docdir}/%{name}/html/
|
|
%exclude %{_docdir}/%{name}/xml/
|
|
%exclude %{_docdir}/%{name}/*.py
|
|
%exclude %{_docdir}/%{name}/*.grc
|
|
# wxgui package
|
|
%exclude %{python_sitearch}/gnuradio/wxgui/
|
|
%exclude %{_datadir}/gnuradio/grc/blocks/wxgui*.xml
|
|
%exclude %{_datadir}/gnuradio/grc/blocks/notebook.xml
|
|
%exclude %{_datadir}/gnuradio/grc/blocks/variable_check_box.xml
|
|
%exclude %{_datadir}/gnuradio/grc/blocks/variable_chooser.xml
|
|
%exclude %{_datadir}/gnuradio/grc/blocks/variable_slider.xml
|
|
%exclude %{_datadir}/gnuradio/grc/blocks/variable_static_text.xml
|
|
%exclude %{_datadir}/gnuradio/grc/blocks/variable_text_box.xml
|
|
|
|
%files wxgui
|
|
%defattr(-,root,root,-)
|
|
%{python_sitearch}/gnuradio/wxgui/
|
|
%{_datadir}/gnuradio/grc/blocks/wxgui*.xml
|
|
%{_datadir}/gnuradio/grc/blocks/notebook.xml
|
|
%{_datadir}/gnuradio/grc/blocks/variable_check_box.xml
|
|
%{_datadir}/gnuradio/grc/blocks/variable_chooser.xml
|
|
%{_datadir}/gnuradio/grc/blocks/variable_slider.xml
|
|
%{_datadir}/gnuradio/grc/blocks/variable_static_text.xml
|
|
%{_datadir}/gnuradio/grc/blocks/variable_text_box.xml
|
|
|
|
%files -n libgnuradio-%{sover}
|
|
%defattr(-,root,root,-)
|
|
%{_libdir}/libgnuradio*.so.*
|
|
|
|
%files -n libvolk%{sover_volk}
|
|
%defattr(-,root,root,-)
|
|
%{_libdir}/libvolk*.so.*
|
|
|
|
%files devel
|
|
%defattr(-,root,root,-)
|
|
%{_includedir}/%{name}/
|
|
%{_includedir}/pmt/
|
|
%{_includedir}/volk/
|
|
%{_libdir}/lib*.so
|
|
%{_libdir}/pkgconfig/*.pc
|
|
%{_libdir}/cmake/gnuradio/
|
|
%{_libdir}/cmake/volk/
|
|
|
|
%files doc
|
|
%defattr(-,root,root,-)
|
|
%dir %{_docdir}/%{name}
|
|
%{_docdir}/%{name}/html/
|
|
%{_docdir}/%{name}/xml/
|
|
%{_docdir}/%{name}/*.py
|
|
%{_docdir}/%{name}/*.grc
|
|
|
|
%files examples
|
|
%defattr(-,root,root,-)
|
|
%{_datadir}/gnuradio/examples/
|
|
%exclude %{_datadir}/gnuradio/examples/audio/audio_fft.py
|
|
%exclude %{_datadir}/gnuradio/examples/hf_explorer/
|
|
%exclude %{_datadir}/gnuradio/examples/hf_radio/
|
|
%exclude %{_datadir}/gnuradio/examples/noaa/usrp_rx_hrpt.grc
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/fm_tx4.py
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/usrp_am_mw_rcv.py
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/usrp_nbfm_ptt.py
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/usrp_nbfm_rcv.py
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/usrp_tv_rcv.py
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/usrp_wfm_rcv_fmdet.py
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/usrp_wfm_rcv_pll.py
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/usrp_wfm_rcv.py
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/usrp_wfm_rcv_sca.py
|
|
%exclude %{_datadir}/gnuradio/examples/uhd/usrp_wxapt_rcv.py
|
|
|
|
%files examples-wxgui
|
|
%defattr(-,root,root,-)
|
|
%{_datadir}/gnuradio/examples/audio/audio_fft.py
|
|
%{_datadir}/gnuradio/examples/hf_explorer/
|
|
%{_datadir}/gnuradio/examples/hf_radio/
|
|
%{_datadir}/gnuradio/examples/noaa/usrp_rx_hrpt.grc
|
|
%{_datadir}/gnuradio/examples/uhd/fm_tx4.py
|
|
%{_datadir}/gnuradio/examples/uhd/usrp_am_mw_rcv.py
|
|
%{_datadir}/gnuradio/examples/uhd/usrp_nbfm_ptt.py
|
|
%{_datadir}/gnuradio/examples/uhd/usrp_nbfm_rcv.py
|
|
%{_datadir}/gnuradio/examples/uhd/usrp_tv_rcv.py
|
|
%{_datadir}/gnuradio/examples/uhd/usrp_wfm_rcv_fmdet.py
|
|
%{_datadir}/gnuradio/examples/uhd/usrp_wfm_rcv_pll.py
|
|
%{_datadir}/gnuradio/examples/uhd/usrp_wfm_rcv.py
|
|
%{_datadir}/gnuradio/examples/uhd/usrp_wfm_rcv_sca.py
|
|
%{_datadir}/gnuradio/examples/uhd/usrp_wxapt_rcv.py
|
|
|
|
%changelog
|