]> git.pld-linux.org Git - packages/uhd.git/blobdiff - uhd.spec
new sonames
[packages/uhd.git] / uhd.spec
index 7b58f4703ae7594b76b8c5f15d974c8499e46cb3..3a154a7091d3646a2cabef4bfa536536841892aa 100644 (file)
--- a/uhd.spec
+++ b/uhd.spec
@@ -1,6 +1,7 @@
 #
 # Conditional build
 %bcond_without mpm     # Module Peripheral Manager (run on embedded devices)
+%bcond_with    tests   # build tests
 
 Summary:       Universal Hardware Driver for Ettus Research products
 Summary(pl.UTF-8):     Uniwersalny sterownik sprzętowy do produktów Ettus Research
@@ -31,6 +32,7 @@ BuildRequires:        python3-devel >= 1:3.5
 BuildRequires: python3-numpy >= 1.7
 BuildRequires: python3-requests >= 2.0
 BuildRequires: rpm-pythonprov
+BuildRequires: rpmbuild(macros) >= 1.742
 %if %{with mpm}
 BuildRequires: udev-devel
 %endif
@@ -168,14 +170,14 @@ Biblioteka USRP Module Peripheral Manager dla Pythona.
 %{__sed} -i -e '1s,/usr/bin/env python$,%{__python},' host/examples/python/*.py
 %{__sed} -i -e '1s,/usr/bin/env python$,%{__python},' host/utils/{converter_benchmark.py,usrp2_{card_burner,card_burner_gui,recovery}.py}
 %{__sed} -i -e '1s,/usr/bin/env python$,%{__python},' host/utils/latency/graph.py
-%{__sed} -i -e '1s,/usr/bin/env python3,%{__python3},' mpm/python/{n3xx_bist,usrp_hwd.py,usrp_update_fs}
-%{__sed} -i -e '1s,/usr/bin/env python3,%{__python3},' mpm/tools/mpm_{debug,shell}.py
+grep -rl '/usr/bin/env python3' . | xargs %{__sed} -i -e '1s,/usr/bin/env python3,%{__python3},'
 
 %build
 install -d build-{host,mpm}
 cd build-host
 %cmake ../host \
        -DUHD_VERSION="%{version}" \
+       %{cmake_on_off tests ENABLE_TESTS} \
        -DENABLE_USB=ON
 
 %{__make}
@@ -197,9 +199,11 @@ rm -rf $RPM_BUILD_ROOT
 
 # outdated (binaries removed)
 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/{octoclock_firmware_burner,usrp_n2xx_simple_net_burner,usrp_x3xx_fpga_burner}.1*
+%if %{with tests}
 # not packaging tests
 %{__rm} -r $RPM_BUILD_ROOT%{_libdir}/%{name}/tests \
        $RPM_BUILD_ROOT%{_libdir}/%{name}/utils/latency/run_tests.py
+%endif
 # packaged as %doc
 %{__rm} $RPM_BUILD_ROOT%{_docdir}/uhd/{LICENSE,README.md}
 
@@ -263,7 +267,7 @@ rm -rf $RPM_BUILD_ROOT
 
 %files libs
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/libuhd.so.3.15.0
+%attr(755,root,root) %{_libdir}/libuhd.so.4.1.0
 %dir %{_libdir}/%{name}
 
 %files devel
@@ -312,7 +316,7 @@ rm -rf $RPM_BUILD_ROOT
 %files mpm-libs
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/libusrp-periphs.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libusrp-periphs.so.3
+%attr(755,root,root) %ghost %{_libdir}/libusrp-periphs.so.4
 
 %files mpm-devel
 %defattr(644,root,root,755)
This page took 0.089237 seconds and 4 git commands to generate.