2012-06-06 22:07:49 +00:00
|
|
|
# By default include binary_firmware, otherwise try to rebuild
|
|
|
|
# the firmware from sources. If you want to rebuild all firmware
|
|
|
|
# images you need to install appropriate tools (e.g. Xilinx ISE).
|
|
|
|
%bcond_without binary_firmware
|
|
|
|
|
|
|
|
%global ver_major 3
|
2014-02-11 13:24:28 +00:00
|
|
|
%global ver_minor 6
|
|
|
|
%global ver_patch 2
|
2012-06-06 22:07:49 +00:00
|
|
|
|
|
|
|
%global ver %(printf "%03d.%03d.%03d" %{ver_major} %{ver_minor} %{ver_patch})
|
|
|
|
%global ver_ %(printf "%03d_%03d_%03d" %{ver_major} %{ver_minor} %{ver_patch})
|
|
|
|
|
2011-12-01 16:15:55 +00:00
|
|
|
Name: uhd
|
|
|
|
URL: http://code.ettus.com/redmine/ettus/projects/uhd/wiki
|
2012-06-06 22:07:49 +00:00
|
|
|
Version: %{ver_major}.%{ver_minor}.%{ver_patch}
|
2014-02-11 13:24:28 +00:00
|
|
|
Release: 1%{?dist}
|
2011-12-01 16:15:55 +00:00
|
|
|
License: GPLv3+
|
|
|
|
BuildRequires: cmake
|
|
|
|
BuildRequires: boost-devel libusb1-devel python-cheetah
|
|
|
|
BuildRequires: docutils doxygen pkgconfig
|
2012-06-06 22:07:49 +00:00
|
|
|
%if ! %{with binary_firmware}
|
|
|
|
BuildRequires: sdcc sed
|
|
|
|
%endif
|
2012-01-11 22:59:26 +00:00
|
|
|
Requires(pre): shadow-utils
|
|
|
|
Requires: tkinter
|
2011-12-01 16:15:55 +00:00
|
|
|
Group: Applications/Engineering
|
2011-12-01 16:28:30 +00:00
|
|
|
Summary: Universal Hardware Driver for Ettus Research products
|
2013-06-05 19:01:38 +00:00
|
|
|
Source0: http://github.com/EttusResearch/uhd/archive/release_%{ver_}.tar.gz#/uhd-release_%{ver_}.tar.gz
|
2012-02-10 10:14:18 +00:00
|
|
|
Source1: %{name}-limits.conf
|
2012-06-06 22:07:49 +00:00
|
|
|
Source2: http://files.ettus.com/binaries/uhd_stable/latest_release/uhd-images_%{ver}-release.tar.gz
|
2012-05-24 13:53:37 +00:00
|
|
|
# ARM convert_test fix (rhbz#813393)
|
2013-06-05 19:01:38 +00:00
|
|
|
Patch0: uhd-3.5.3-no-neon.patch
|
2012-06-06 22:07:49 +00:00
|
|
|
# Fix firmware build with sdcc-3
|
|
|
|
Patch1: uhd-3.4.2-sdcc-3-fix.patch
|
2011-12-01 16:15:55 +00:00
|
|
|
|
|
|
|
%description
|
|
|
|
The UHD is the universal hardware driver for Ettus Research products.
|
|
|
|
The goal of the UHD is to provide a host driver and API for current and
|
|
|
|
future Ettus Research products. It can be used standalone without GNU Radio.
|
|
|
|
|
2014-02-11 13:24:28 +00:00
|
|
|
%package firmware
|
|
|
|
Summary: Firmware files for UHD
|
|
|
|
Group: Applications/Engineering
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description firmware
|
|
|
|
Firmware files for the Universal Hardware driver (UHD).
|
|
|
|
|
|
|
|
%package devel
|
|
|
|
Summary: Development files for UHD
|
|
|
|
Group: Applications/Engineering
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
|
|
|
%description devel
|
|
|
|
Development files for the Universal Hardware Driver (UHD).
|
|
|
|
|
|
|
|
%package doc
|
|
|
|
Summary: Documentation files for UHD
|
|
|
|
Group: Applications/Engineering
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description doc
|
|
|
|
Documentation for the Universal Hardware Driver (UHD).
|
|
|
|
|
2011-12-01 16:15:55 +00:00
|
|
|
%prep
|
2013-06-05 19:01:38 +00:00
|
|
|
%setup -q -n uhd-release_%{ver_}
|
2012-05-24 13:53:37 +00:00
|
|
|
%patch0 -p1 -b .no-neon
|
2012-06-06 22:07:49 +00:00
|
|
|
%patch1 -p1 -b .sdcc-3-fix
|
|
|
|
|
|
|
|
# firmware
|
|
|
|
%if %{with binary_firmware}
|
|
|
|
# extract binary firmware
|
|
|
|
mkdir -p images/images
|
|
|
|
tar -xzf %{SOURCE2} -C images/images --strip-components=4
|
|
|
|
rm -f images/images/{LICENSE.txt,*.tag}
|
|
|
|
%endif
|
2011-12-01 16:15:55 +00:00
|
|
|
|
|
|
|
%build
|
2012-06-06 22:07:49 +00:00
|
|
|
# firmware
|
|
|
|
%if ! %{with binary_firmware}
|
|
|
|
# rebuilt from sources
|
|
|
|
export PATH=$PATH:%{_libexecdir}/sdcc
|
|
|
|
pushd images
|
|
|
|
sed -i '/-name "\*\.twr" | xargs grep constraint | grep met/ s/^/#/' Makefile
|
|
|
|
make %{?_smp_mflags} images
|
|
|
|
popd
|
|
|
|
%endif
|
|
|
|
|
|
|
|
mkdir -p host/build
|
|
|
|
pushd host/build
|
2011-12-01 16:15:55 +00:00
|
|
|
%cmake ../
|
|
|
|
make %{?_smp_mflags}
|
2012-06-06 22:07:49 +00:00
|
|
|
popd
|
2011-12-01 16:15:55 +00:00
|
|
|
|
|
|
|
%check
|
|
|
|
cd host/build
|
|
|
|
make test
|
|
|
|
|
|
|
|
%install
|
|
|
|
pushd host/build
|
|
|
|
make install DESTDIR=%{buildroot}
|
|
|
|
|
2012-01-11 22:59:26 +00:00
|
|
|
# Fix udev rules and allow access only to users in usrp group
|
2014-02-11 13:24:28 +00:00
|
|
|
sed -i 's/BUS==/SUBSYSTEM==/;s/SYSFS{/ATTRS{/;s/MODE:="0666"/GROUP:="usrp", MODE:="0660"/' %{buildroot}%{_libdir}/uhd/utils/uhd-usrp.rules
|
2011-12-01 16:15:55 +00:00
|
|
|
mkdir -p %{buildroot}%{_sysconfdir}/udev/rules.d
|
2014-02-11 13:24:28 +00:00
|
|
|
mv %{buildroot}%{_libdir}/uhd/utils/uhd-usrp.rules %{buildroot}%{_sysconfdir}/udev/rules.d/10-usrp-uhd.rules
|
2011-12-01 16:15:55 +00:00
|
|
|
|
2014-02-11 13:24:28 +00:00
|
|
|
# Remove tests, examples binaries
|
|
|
|
rm -rf %{buildroot}%{_libdir}/uhd/{tests,examples}
|
2011-12-01 16:15:55 +00:00
|
|
|
|
|
|
|
# Move the utils stuff to libexec dir
|
|
|
|
mkdir -p %{buildroot}%{_libexecdir}/uhd
|
2014-02-11 13:24:28 +00:00
|
|
|
mv %{buildroot}%{_libdir}/uhd/utils/* %{buildroot}%{_libexecdir}/uhd
|
2011-12-01 16:15:55 +00:00
|
|
|
|
|
|
|
popd
|
|
|
|
# Package base docs to base package
|
|
|
|
mkdir _tmpdoc
|
2014-02-11 13:24:28 +00:00
|
|
|
mv %{buildroot}%{_docdir}/%{name}/{LICENSE,README.md} _tmpdoc
|
2011-12-01 16:15:55 +00:00
|
|
|
|
2012-02-10 10:14:18 +00:00
|
|
|
install -m 644 -D %{SOURCE1} %{buildroot}%{_sysconfdir}/security/limits.d/99-usrp.conf
|
|
|
|
|
2012-06-06 22:07:49 +00:00
|
|
|
# firmware
|
|
|
|
mkdir -p %{buildroot}%{_datadir}/uhd/images
|
|
|
|
cp -r images/images/* %{buildroot}%{_datadir}/uhd/images
|
|
|
|
|
2014-02-11 13:24:28 +00:00
|
|
|
# remove win stuff
|
|
|
|
rm -rf %{buildroot}%{_datadir}/uhd/images/winusb_driver
|
|
|
|
|
2013-06-05 19:01:38 +00:00
|
|
|
# convert hardlinks to symlinks (to not package the file twice)
|
|
|
|
pushd %{buildroot}%{_bindir}
|
|
|
|
unlink ./usrp_n2xx_simple_net_burner
|
|
|
|
ln -s ../..%{_libexecdir}/uhd/usrp_n2xx_simple_net_burner
|
|
|
|
popd
|
|
|
|
|
2011-12-01 16:15:55 +00:00
|
|
|
%post -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%postun -p /sbin/ldconfig
|
|
|
|
|
2012-01-11 22:59:26 +00:00
|
|
|
%pre
|
|
|
|
getent group usrp >/dev/null || groupadd -r usrp >/dev/null
|
2011-12-01 16:15:55 +00:00
|
|
|
|
|
|
|
%files
|
2014-02-11 13:24:28 +00:00
|
|
|
%exclude %{_docdir}/%{name}/manual
|
|
|
|
%exclude %{_docdir}/%{name}/doxygen
|
|
|
|
%exclude %{_datadir}/uhd/images
|
2011-12-01 16:15:55 +00:00
|
|
|
%doc _tmpdoc/*
|
2012-03-27 11:49:46 +00:00
|
|
|
%{_bindir}/*
|
2011-12-01 16:15:55 +00:00
|
|
|
%config(noreplace) %{_sysconfdir}/udev/rules.d/10-usrp-uhd.rules
|
2012-02-10 10:14:18 +00:00
|
|
|
%config(noreplace) %{_sysconfdir}/security/limits.d/*.conf
|
2011-12-01 16:15:55 +00:00
|
|
|
%{_libdir}/lib*.so.*
|
|
|
|
%{_libexecdir}/uhd
|
2013-06-05 19:01:38 +00:00
|
|
|
%{_mandir}/man1/*.1*
|
2014-02-11 13:24:28 +00:00
|
|
|
%{_datadir}/uhd
|
2011-12-01 16:15:55 +00:00
|
|
|
|
2012-06-06 22:07:49 +00:00
|
|
|
%files firmware
|
|
|
|
%dir %{_datadir}/uhd/images
|
|
|
|
%{_datadir}/uhd/images/*
|
|
|
|
|
2011-12-01 16:15:55 +00:00
|
|
|
%files devel
|
|
|
|
%{_includedir}/*
|
|
|
|
%{_libdir}/lib*.so
|
|
|
|
%{_libdir}/pkgconfig/*.pc
|
|
|
|
|
|
|
|
%files doc
|
2014-02-11 13:24:28 +00:00
|
|
|
%doc %{_docdir}/%{name}/manual
|
|
|
|
%doc %{_docdir}/%{name}/doxygen
|
2011-12-01 16:15:55 +00:00
|
|
|
|
|
|
|
%changelog
|
2014-02-11 13:24:28 +00:00
|
|
|
* Tue Feb 11 2014 Jaroslav Škarvada <jskarvad@redhat.com> - 3.6.2-1
|
|
|
|
- New version
|
|
|
|
Resolves: rhbz#1063587
|
|
|
|
|
2013-08-04 05:26:59 +00:00
|
|
|
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.5.3-3
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
|
|
|
|
|
2013-07-27 12:07:48 +00:00
|
|
|
* Sat Jul 27 2013 pmachata@redhat.com - 3.5.3-2
|
|
|
|
- Rebuild for boost 1.54.0
|
|
|
|
|
2013-06-05 19:01:38 +00:00
|
|
|
* Wed Jun 05 2013 Jaroslav Škarvada <jskarvad@redhat.com> - 3.5.3-1
|
|
|
|
- New version
|
|
|
|
- Defuzzified no-neon patch
|
|
|
|
|
2013-02-10 01:38:00 +00:00
|
|
|
* Sun Feb 10 2013 Denis Arnaud <denis.arnaud_fedora@m4x.org> - 3.4.3-3
|
|
|
|
- Rebuild for Boost-1.53.0
|
|
|
|
|
2013-02-09 22:22:11 +00:00
|
|
|
* Sat Feb 09 2013 Denis Arnaud <denis.arnaud_fedora@m4x.org> - 3.4.3-2
|
|
|
|
- Rebuild for Boost-1.53.0
|
|
|
|
|
2012-08-22 08:55:44 +00:00
|
|
|
* Wed Aug 22 2012 Jaroslav Škarvada <jskarvad@redhat.com> - 3.4.3-1
|
|
|
|
- New version
|
|
|
|
|
2012-08-10 07:10:23 +00:00
|
|
|
* Fri Aug 10 2012 Jaroslav Škarvada <jskarvad@redhat.com> - 3.4.2-4
|
|
|
|
- Rebuilt for new boost
|
|
|
|
|
2012-07-22 01:28:56 +00:00
|
|
|
* Sun Jul 22 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.4.2-3
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
|
|
|
|
2012-06-06 22:07:49 +00:00
|
|
|
* Wed Jun 6 2012 Jaroslav Škarvada <jskarvad@redhat.com> - 3.4.2-2
|
|
|
|
- Added firmware subpackage
|
|
|
|
Resolves: rhbz#769684
|
|
|
|
|
2012-05-24 13:53:37 +00:00
|
|
|
* Wed May 23 2012 Jaroslav Škarvada <jskarvad@redhat.com> - 3.4.2-1
|
|
|
|
- New version
|
|
|
|
- Removed usrp1-r45-dbsrx-i2c-fix patch (upstreamed)
|
|
|
|
- Fixed convert_test failure on ARM by no-neon patch
|
|
|
|
Resolves: rhbz#813393
|
|
|
|
|
2012-03-27 11:49:46 +00:00
|
|
|
* Tue Mar 27 2012 Jaroslav Škarvada <jskarvad@redhat.com> - 3.4.0-1
|
|
|
|
- New version
|
|
|
|
- Fixed lockup on USRP1 r4.5 + DBSRX + another i2c board combo
|
|
|
|
(usrp1-r45-dbsrx-i2c-fix patch)
|
|
|
|
Resolves: rhbz#804440
|
|
|
|
|
2012-03-19 09:45:30 +00:00
|
|
|
* Mon Mar 19 2012 Jaroslav Škarvada <jskarvad@redhat.com> - 3.3.2-1
|
|
|
|
- New version
|
|
|
|
|
2012-02-28 20:28:14 +00:00
|
|
|
* Tue Feb 28 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.3.1-4
|
|
|
|
- Rebuilt for c++ ABI breakage
|
|
|
|
|
2012-02-10 10:14:18 +00:00
|
|
|
* Fri Feb 10 2012 Jaroslav Škarvada <jskarvad@redhat.com> - 3.3.1-3
|
|
|
|
- Allowed UHD to boost the thread's scheduling priority
|
|
|
|
Resolves: rhbz#781540
|
|
|
|
|
2012-01-11 22:59:26 +00:00
|
|
|
* Wed Jan 11 2012 Jaroslav Škarvada <jskarvad@redhat.com> - 3.3.1-2
|
|
|
|
- Minor tweaks to %%pre scriptlet
|
|
|
|
- Fixed udev rules
|
|
|
|
- Added tkinter requires
|
|
|
|
Resolves: rhbz#769678
|
|
|
|
|
2011-12-02 16:19:18 +00:00
|
|
|
* Fri Dec 2 2011 Jaroslav Škarvada <jskarvad@redhat.com> - 3.3.1-1
|
|
|
|
- New version
|
|
|
|
|
2011-12-01 16:28:30 +00:00
|
|
|
* Thu Dec 1 2011 Jaroslav Škarvada <jskarvad@redhat.com> - 3.3.0-3
|
|
|
|
- Updated summary to be more descriptive
|
|
|
|
|
2011-12-01 16:15:55 +00:00
|
|
|
* Wed Nov 30 2011 Jaroslav Škarvada <jskarvad@redhat.com> - 3.3.0-2
|
|
|
|
- Fixed according to reviewer comments
|
|
|
|
|
|
|
|
* Tue Nov 01 2011 Jaroslav Škarvada <jskarvad@redhat.com> - 3.3.0-1
|
|
|
|
- Initial version
|