File mrwriter.spec of Package mrwriter

#
# spec file for package mrwriter
#
# Copyright (c) 2021 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#


Name:           mrwriter
Version:        0.0.7
Release:        0
Summary:        Notetaking and blackboard replacement application
License:        GPL-3.0
Group:          Productivity/Office/Other
URL:            https://github.com/unruhschuh/MrWriter
Source0:        https://github.com/unruhschuh/MrWriter/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
Patch0:         cmake-executable-output-directory-fix.patch
BuildRequires:  cmake
BuildRequires:  fdupes
%if 0%{?suse_version} < 1550
BuildRequires:  gcc9-c++
%else
BuildRequires:  gcc-c++
%endif
BuildRequires:  hicolor-icon-theme
BuildRequires:  pkgconfig
BuildRequires:  pkgconfig(Qt5Widgets)
BuildRequires:  pkgconfig(Qt5Xml)
BuildRequires:  pkgconfig(Qt5Test)
BuildRequires:  pkgconfig(Qt5PrintSupport)
BuildRequires:  pkgconfig(Qt5Concurrent)
BuildRequires:  pkgconfig(zlib)


%description
Notetaking and blackboard replacement application. Inspired by Xournal. Written in C++/Qt for Linux / Windows / Mac.

%prep
%setup -qn MrWriter-%{version}
%patch -P0 -p1

%build
%cmake \
%if 0%{?suse_version} < 1550
       -DCMAKE_CXX_COMPILER="%{_bindir}/g++-9" \
%endif
       %{nil}
%cmake_build

%install
%cmake_install

install -p -m644 -D appdir/usr/share/applications/MrWriter.desktop %{buildroot}%{_datadir}/applications/MrWriter.desktop
install -p -m644 -D appdir/usr/share/icons/hicolor/1024x1024/apps/MrWriter.png %{buildroot}%{_datadir}/icons/hicolor/1024x1024/apps/MrWriter.png

%fdupes %{buildroot}%{_datadir}

%files
%license LICENSE
%doc README.adoc
%{_bindir}/MrWriter
%{_datadir}/applications/MrWriter.desktop
%dir %{_datadir}/icons/hicolor/1024x1024
%dir %{_datadir}/icons/hicolor/1024x1024/apps
%{_datadir}/icons/hicolor/1024x1024/apps/MrWriter.png

%changelog

openSUSE Build Service is sponsored by