File novprog.spec of Package novprog
#
# spec file for package novprog
#
# Copyright (c) 2025 Graeme Gott <graeme@gottcode.org>
#
# 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.
Name: novprog
Summary: Wordcount graphing program
Version: 3.2.5
Release: 2
License: GPL-3.0-or-later
URL: https://gottcode.org/%{name}/
Source: %{name}-%{version}.tar.bz2
#--------------------------------------------------------------------
# Fedora
#--------------------------------------------------------------------
%if 0%{?fedora}
Group: Applications/Productivity
BuildRequires: desktop-file-utils
BuildRequires: gettext
BuildRequires: libappstream-glib
BuildRequires: ninja-build
%endif
#--------------------------------------------------------------------
# SUSE
#--------------------------------------------------------------------
%if 0%{?suse_version}
Patch1: desktop.patch
Group: Productivity/Office/Other
%endif
#--------------------------------------------------------------------
# All
#--------------------------------------------------------------------
BuildRequires: gcc-c++
BuildRequires: hicolor-icon-theme
BuildRequires: cmake
BuildRequires: cmake(Qt6Core)
BuildRequires: cmake(Qt6Gui)
BuildRequires: cmake(Qt6LinguistTools)
BuildRequires: cmake(Qt6Widgets)
#--------------------------------------------------------------------
%description
NovProg allows you to create a graph of your progress in writing a NaNoWriMo
style novel. You enter your wordcount and it updates a graph showing you how
much progress you have made. It also shows you how far you are through your
daily goal, and your total goal. Mousing over a bar in the graph will show a
tooltip with that day's wordcount.
%prep
%autosetup -p1
#--------------------------------------------------------------------
# Fedora
#--------------------------------------------------------------------
%if 0%{?fedora}
%build
%cmake_qt6
%cmake_build
%install
%cmake_install
%check
desktop-file-validate %{buildroot}/%{_datadir}/applications/%{name}.desktop || :
appstream-util validate-relax --nonet %{buildroot}%{_datadir}/metainfo/%{name}.appdata.xml || :
%endif
#--------------------------------------------------------------------
# SUSE
#--------------------------------------------------------------------
%if 0%{?suse_version}
%build
%cmake_qt6
%{qt6_build}
%install
%{qt6_install}
%endif
#--------------------------------------------------------------------
%files
%defattr(-,root,root,-)
%if 0%{?suse_version}
%{_datadir}/icons/hicolor/
%endif
%doc ChangeLog COPYING CREDITS README
%{_bindir}/%{name}
%{_datadir}/%{name}
%{_datadir}/applications/%{name}.desktop
%{_datadir}/icons/hicolor/*/apps/%{name}.*
%{_datadir}/metainfo/%{name}.appdata.xml
%{_mandir}/man?/%{name}.*
%changelog
* Fri Feb 14 2025 Graeme Gott <graeme@gottcode.org> - 3.2.5-2
- Fix patch
* Fri Feb 14 2025 Graeme Gott <graeme@gottcode.org> - 3.2.5-1
- Update to 3.2.5
* Mon Jan 06 2025 Graeme Gott <graeme@gottcode.org> - 3.2.4-1
- Update to 3.2.4
* Fri Oct 11 2024 Graeme Gott <graeme@gottcode.org> - 3.2.3-3
- Support older RPM as well
* Fri Oct 11 2024 Graeme Gott <graeme@gottcode.org> - 3.2.3-2
- Fix patch for RPM >= 4.20
* Tue Jan 16 2024 Graeme Gott <graeme@gottcode.org> - 3.2.3-1
- Update to 3.2.3
* Tue Jan 10 2023 Graeme Gott <graeme@gottcode.org> - 3.2.2-1
- Update to 3.2.2
* Fri Jun 10 2022 Graeme Gott <graeme@gottcode.org> - 3.2.1-2
- Use newer g++ on openSUSE.
* Tue May 03 2022 Graeme Gott <graeme@gottcode.org> - 3.2.1-1
- Update to 3.2.1
* Tue Sep 21 2021 Graeme Gott <graeme@gottcode.org> - 3.2.0-1
- Update to 3.2.0
* Tue Apr 21 2020 Graeme Gott <graeme@gottcode.org> - 3.1.7-1
- Update to 3.1.7
* Wed Aug 07 2019 Graeme Gott <graeme@gottcode.org> - 3.1.6-1
- Update to 3.1.6
* Fri Jul 20 2018 Graeme Gott <graeme@gottcode.org> - 3.1.5-1
- Update to 3.1.5
* Tue May 29 2018 Graeme Gott <graeme@gottcode.org> - 3.1.4-1
- Update to 3.1.4
* Wed Dec 27 2017 Graeme Gott <graeme@gottcode.org> - 3.1.3-1
- Update to 3.1.3
* Sat Aug 05 2017 Graeme Gott <graeme@gottcode.org> - 3.1.2-1
- Update to 3.1.2
* Mon Oct 10 2016 Graeme Gott <graeme@gottcode.org> - 3.1.1-3
- Fix patch build failure.
* Mon Oct 10 2016 Graeme Gott <graeme@gottcode.org> - 3.1.1-2
- Fix desktop category for openSUSE.
* Mon Oct 10 2016 Graeme Gott <graeme@gottcode.org> - 3.1.1-1
- Update to 3.1.1
* Sat Aug 27 2016 Graeme Gott <graeme@gottcode.org> - 3.1.0-6
- Fix build failure.
* Sat Jan 30 2016 Graeme Gott <graeme@gottcode.org> - 3.1.0-5
- Only change desktop categories in Fedora.
* Sat Jan 30 2016 Graeme Gott <graeme@gottcode.org> - 3.1.0-4
- Fix patch location.
* Sat Jan 30 2016 Graeme Gott <graeme@gottcode.org> - 3.1.0-3
- Add patch file.
* Sat Jan 30 2016 Graeme Gott <graeme@gottcode.org> - 3.1.0-2
- Fix desktop categories.
* Sat Jan 30 2016 Graeme Gott <graeme@gottcode.org> - 3.1.0-1
- Update to 3.1.0
* Tue May 05 2015 Graeme Gott <graeme@gottcode.org> - 3.0.0-3
- Package for Debian 8.
* Sun Nov 02 2014 Graeme Gott <graeme@gottcode.org> - 3.0.0-2
- Added category for OpenSUSE.
* Sun Nov 02 2014 Graeme Gott <graeme@gottcode.org> - 3.0.0-1
- Update to 3.0.0
* Mon May 12 2014 Graeme Gott <graeme@gottcode.org> - 2.0.5-10
- Switch to Qt 5.
* Thu Jan 24 2013 Graeme Gott <graeme@gottcode.org> - 2.0.5-9
- Improve spec file.
* Tue Jan 22 2013 Graeme Gott <graeme@gottcode.org> - 2.0.5-8
- Add Debian packaging.
* Mon Dec 05 2011 Graeme Gott <graeme@gottcode.org> - 2.0.5-7
- Update GNOME icon cache.
* Fri Nov 11 2011 Graeme Gott <graeme@gottcode.org> - 2.0.5-6
- Improve spec file.
* Sat Apr 02 2011 Graeme Gott <graeme@gottcode.org> - 2.0.5-5
- Add dependency on hicolor-icon-theme.
* Wed Sep 22 2010 Graeme Gott <graeme@gottcode.org> - 2.0.5-4
- Use calendar office category.
* Wed Sep 22 2010 Graeme Gott <graeme@gottcode.org> - 2.0.5-3
- Add a specific office category.
* Wed Sep 22 2010 Graeme Gott <graeme@gottcode.org> - 2.0.5-2
- Add a generic name to the desktop file.
* Tue Sep 21 2010 Graeme Gott <graeme@gottcode.org> - 2.0.5-1
- Initial package.