File gammy.spec of Package gammy
#
# spec file for package gammy
#
# 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: gammy
Version: 0.9.64
Release: 0
Summary: Automatic screen brightness tool
License: GPL-3.0-only
URL: https://getgammy.com
Source0: https://github.com/Fushko/gammy/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires: ImageMagick
BuildRequires: icoutils
BuildRequires: hicolor-icon-theme
BuildRequires: update-desktop-files
BuildRequires: pkgconfig(Qt5Core) >= 5.12
BuildRequires: pkgconfig(Qt5DBus)
BuildRequires: pkgconfig(Qt5Widgets) >= 5.12
BuildRequires: pkgconfig(xext)
BuildRequires: pkgconfig(xxf86vm)
%description
Adjusts pixel brightness based on screen contents. It dims the screen if it's
too bright (according to user settings) and vice versa.
%prep
%setup -q
%build
%qmake5
make %{?_smp_mflags}
%install
install -Dm0755 %{name} %{buildroot}%{_bindir}/%{name}
icotool -x data/icons/gammy.ico
for s in 16 32 64 128 256; do
mkdir -pv %{buildroot}%{_datadir}/icons/hicolor/${s}x${s}/apps
convert -resize ${s}x${s} gammy_1_256x256x32.png %{buildroot}%{_datadir}/icons/hicolor/${s}x${s}/apps/%{name}.png
done
%suse_update_desktop_file -c %{name} %{name} "Desktop gamma utility" %{name} %{name} "Settings;DesktopSettings"
%files
%license LICENSE
%doc README.md
%{_bindir}/%{name}
%{_datadir}/applications/%{name}.desktop
%{_datadir}/icons/hicolor/*/apps/%{name}.png
%changelog