File srsgui.spec of Package srsgui
#
# spec file for package srsgui
#
# Copyright (c) 2016, Martin Hauke <mardnh@gmx.de>
#
# 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: srsgui
Version: 2.0+git.20200430
Release: 0
Summary: A free and open-source graphics library for SDR using Qt and Qwt
License: LGPL-3.0-only
Group: Productivity/Hamradio/Other
URL: https://github.com/srsLTE/srsGUI
Source: %{name}-%{version}.tar.xz
Patch0: https://github.com/srsran/srsGUI/pull/13.patch
Patch2: srsgui-qwt-6.2.patch
Patch3: srsgui-allow-deprecated-headers.patch
BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: libqt5-qtbase-devel
BuildRequires: pkgconfig
BuildRequires: pkgconfig(Qt5Widgets)
BuildRequires: qwt6-qt5-devel
%if 0%{?suse_version} > 1325
BuildRequires: libboost_system-devel
BuildRequires: libboost_test-devel
BuildRequires: libboost_thread-devel
%else
BuildRequires: boost-devel
%endif
%description
srsGUI is a free and open-source graphics library for SDR using Qt and Qwt.
The library provides a number of useful plots for graphing real and complex
numbers.Each plot is designed to be frequently updated with new data.
%package devel
Summary: Development files for the srsgui library
Group: Development/Libraries/C and C++
%description devel
This subpackage contains libraries and header files for developing
applications that want to make use of libsrsgui.
%prep
%setup -q
%patch -P 0 -p1
%patch -P 2 -p1
%if 0%{?suse_version} > 1600
%patch -P 3 -p1
%endif
%build
%cmake \
-DQWT_INCLUDE_DIR=%{_includedir}/qt5/qwt6 \
-DQWT_LIBRARY=%{_libdir}/libqwt-qt5.so \
-DCMAKE_SHARED_LINKER_FLAGS="" \
-DCMAKE_INSTALL_LIBDIR:PATH=%{_lib} \
-DCMAKE_C_FLAGS:STRING="%{optflags} -Wno-return-type" \
-DCMAKE_CXX_FLAGS:STRING="%{optflags} -Wno-return-type -Wno-reorder"
%cmake_build
%install
%cmake_install
%check
%files devel
%license COPYRIGHT LICENSE LICENSE.GPL
%doc CHANGELOG README.md
%{_includedir}/srsgui
%{_libdir}/cmake/srsgui
%{_libdir}/libsrsgui.so
%changelog