File aqemu.spec of Package aqemu

#
# spec file for package aqemu
#
# Copyright (c) 2018 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:           aqemu
Version:        0.9.2
Release:        0
Summary:        GUI for virtual machines using QEMU as the backend
License:        GPL-2.0
Group:          System/Emulators/PC
Url:            https://github.com/tobimensch/%{name}
Source0:        %{name}-%{version}.tar.xz
Patch0:         %{name}-cmake.patch
Patch1:         %{name}-src.patch
BuildRequires:  cmake
%if 0%{?suse_version} && 0%{?suse_version} <= 1320
BuildRequires:  gcc5-c++
%else
BuildRequires:  gcc-c++
%endif
BuildRequires:  LibVNCServer-devel
BuildRequires:  gzip
BuildRequires:  libqt5-qtbase-devel
BuildRequires:  update-desktop-files

%description
AQEMU is a graphical frontend for QEMU based virtual machines.

%prep
%setup -q
%patch -P 0
%if 0%{?suse_version} && 0%{?suse_version} > 1500
%patch -P 1
%endif
cd menu_data
%{__rm} -f %{name}.png
%{__ln_s} %{name}_48x48.png %{name}.png

%build
%if 0%{?suse_version} && 0%{?suse_version} <= 1320
export CXX=g++-5
%endif
%cmake -DMAN_PAGE_COMPRESSOR=gzip
%make_build
%{__strip} -s %{name}

%install
%cmake_install
%suse_update_desktop_file %{name}

%check

%files
%defattr(-,root,root,-)
%attr(755,root,root) %{_bindir}/%{name}
%{_datadir}/applications/%{name}.desktop
%{_datadir}/%{name}
%{_datadir}/pixmaps/%{name}*.png
%{_mandir}/man1/%{name}.1%{?ext_man}
%{_defaultdocdir}/%{name}

%changelog
openSUSE Build Service is sponsored by