diff --git a/.gitignore b/.gitignore index 0b994e2..8f787ff 100644 --- a/.gitignore +++ b/.gitignore @@ -26,6 +26,3 @@ /variety-0.8.11.tar.gz /variety-0.8.12.tar.gz /variety-0.8.13.tar.gz -/variety-0.9.0-b1.tar.gz -/variety-0.9.0.tar.gz -/variety-0.9.1.tar.gz diff --git a/796.patch b/796.patch deleted file mode 100644 index 5d44065..0000000 --- a/796.patch +++ /dev/null @@ -1,60 +0,0 @@ -From 325552174e51c56d98297c2a08ddb4d2c7092c58 Mon Sep 17 00:00:00 2001 -From: Martin Gansser -Date: Thu, 9 Oct 2025 10:00:56 +0200 -Subject: [PATCH] Fix wheel-based installations to include - variety_build_settings -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -Fixes https://github.com/varietywalls/variety/issues/795 - -This could also move the cleanup to a custom cmdclass, -but it is not necessary. - -Co-Authored-By: Miro Hrončok ---- - setup.py | 12 +++++++----- - 1 file changed, 7 insertions(+), 5 deletions(-) - -diff --git a/setup.py b/setup.py -index 3f486d9b..00fa31da 100644 ---- a/setup.py -+++ b/setup.py -@@ -20,6 +20,7 @@ - - import os - import sys -+from setuptools.command.build_py import build_py as _build_py - - from variety_lib.varietyconfig import get_version - -@@ -41,14 +42,15 @@ - BUILD_SETTINGS_PATH = "variety_lib/variety_build_settings.py" - - --class InstallWithDataDirectory(DistUtilsExtra.auto.install_auto): -+ -+class BuildWithDataDirectory(_build_py): - def run(self): -- data_path = os.path.join(self.prefix, "share/variety/") -+ data_path = os.path.join(sys.prefix, "share/variety/") - with open(BUILD_SETTINGS_PATH, "w") as f: - f.write("### Autogenerated by setup.py - do not edit!\n") - f.write("__variety_data_directory__ = %r\n" % data_path) -- print("This build will look for Variety's data in %r." % data_path) -- DistUtilsExtra.auto.install_auto.run(self) -+ print(f"[build_py] This build will look for Variety's data in {data_path!r}.") -+ super().run() - - - DistUtilsExtra.auto.setup( -@@ -69,7 +71,7 @@ def run(self): - Variety also includes a range of image effects, such as oil painting and blur, - as well as options to layer quotes and a clock onto the background.""", - url="https://github.com/varietywalls/variety", -- cmdclass={"install": InstallWithDataDirectory}, -+ cmdclass={"build_py": BuildWithDataDirectory}, - data_files=[("share/metainfo", ["variety.appdata.xml"])], - ) - diff --git a/Add_Dark_Wallpaper_Support_for_Gnome42.patch b/Add_Dark_Wallpaper_Support_for_Gnome42.patch new file mode 100644 index 0000000..696324c --- /dev/null +++ b/Add_Dark_Wallpaper_Support_for_Gnome42.patch @@ -0,0 +1,10 @@ +--- variety-0.8.5/data/scripts/set_wallpaper.orig 2022-03-26 16:35:24.387777235 +0100 ++++ variety-0.8.5/data/scripts/set_wallpaper 2022-03-26 16:36:32.911009155 +0100 +@@ -173,6 +173,7 @@ + + # GNOME Screensaver / Lock screen - thanks to George C. de Araujo for the patch + gsettings set org.gnome.desktop.screensaver picture-uri "file://$WP" 2> /dev/null ++gsettings set org.gnome.desktop.background picture-uri-dark "file://$WP" 2> /dev/null + if [ "$(gsettings get org.gnome.desktop.screensaver picture-options)" == "'none'" ]; then + gsettings set org.gnome.desktop.screensaver picture-options 'zoom' + fi diff --git a/sources b/sources index 5070a1a..2d806cc 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (variety-0.9.1.tar.gz) = ea07bb82d2398f3602459439dcdb0f27b26c18d5771f21c3d2e24547aa2f0a4abbde7098d1b204bd013084a47877eaad2e6a668acfb48c34a6703b3efe467b26 +SHA512 (variety-0.8.13.tar.gz) = 5f67186060a7226e8bed60217cb58adbf194d3473e654c1d30164d0a0800a043f9e8ee5f721c7d8d3b3f3377698df3c7a7a9d1e9ec4d0178edc87d1a2d6dfa8a diff --git a/variety.spec b/variety.spec index 88a1977..da56279 100644 --- a/variety.spec +++ b/variety.spec @@ -4,35 +4,31 @@ %global commit0 8b8bb63a10fa22760eb976b1fd57338f3dba3233 %global shortcommit0 %(c=%{commit0}; echo ${c:0:7}) %global snapshottag .git%{shortcommit0} -%global upstream_tag 0.9.0-b1 %endif Name: variety %if 0%{?usesnapshot} -#Release: 0.17%%{?snapshottag}%%{?dist} -Version: 0.9.0 -Release: 0.3.beta1%{?dist} +Version: 0.8.6 +Release: 0.11%{?snapshottag}%{?dist} %else -Version: 0.9.1 -Release: 1%{?dist} +Version: 0.8.13 +Release: 2%{?dist} %endif Summary: Wallpaper changer that automatically downloads wallpapers +# Automatically converted from old format: GPLv3 - review is highly recommended. License: GPL-3.0-only URL: https://github.com/varietywalls/variety %if 0%{?usesnapshot} -#Source0: %%{url}/archive/%%{commit0}/%%{name}-%%{shortcommit0}.tar.gz -Source0: %{url}/archive/refs/tags/%{upstream_tag}.tar.gz#/%{name}-%{upstream_tag}.tar.gz +Source0: %{url}/archive/%{commit0}/%{name}-%{shortcommit0}.tar.gz %else Source0: %{url}/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz %endif -# Fix wheel-based installations to include variety_build_settings -# Patch0: https://github.com/varietywalls/variety/pull/796.patch - BuildArch: noarch BuildRequires: python3-devel +BuildRequires: python3-setuptools BuildRequires: python3-distutils-extra BuildRequires: python3-configobj BuildRequires: python3-lxml @@ -53,8 +49,10 @@ BuildRequires: python3-cairo Requires: python3-dbus Requires: hicolor-icon-theme Requires: ImageMagick +Requires: libappindicator-gtk3 Requires: python3-lxml Requires: python3-pillow +#Requires: python3-appindicator -- not available yet Requires: python3-beautifulsoup4 Requires: python3-configobj Requires: python3-gexiv2 @@ -62,7 +60,9 @@ Requires: python3-pycurl Requires: python3-requests Requires: python3-httplib2 Requires: xorg-x11-fonts-Type1 +%if 0%{?fedora} >= 39 Requires: python3-zombie-imp +%endif %description @@ -86,122 +86,51 @@ desktop is always fresh and unique. %prep %if 0%{?usesnapshot} -#%%autosetup -p1 -n %%{name}-%%{commit0} -%autosetup -p1 -n %{name}-%{upstream_tag} +%setup -q -n %{name}-%{commit0} %else -%autosetup -p1 -n %{name}-%{version} +%autosetup -p1 %endif + +%if 0%{?fedora} >= 33 # Replace deprecated getiterator() with iter() sed -i -e 's|getiterator|iter|' variety_lib/Builder.py - -# Fix setuptools package discovery warnings (Python 3.14) -sed -i 's/include = \["variety", "variety_lib"\]/include = ["variety*","variety_lib*"]/' pyproject.toml || : - -# use a simple SPDX license string -sed -i 's/license = { text = "GPL-3.0-only" }/license = "GPL-3.0-only"/' pyproject.toml - -# include variety.data in package -sed -i '/\[tool.setuptools-gettext\]/i [tool.setuptools]\npackages = { find = {} }\n' pyproject.toml +%endif # remove debian part -# rm -rf debian - -%generate_buildrequires -%pyproject_buildrequires +rm -rf debian %build -%pyproject_wheel +# Bytecompile Python modules +%py_byte_compile %{__python3} setup.py build %install -%pyproject_install - -# Install desktop file, as this is not handled by setuptools automatically -install -D -m 644 %{name}.desktop \ - %{buildroot}%{_datadir}/applications/%{name}.desktop - -# Install application icon -install -D -m 644 variety/data/media/variety.svg \ - %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/variety.svg - -# optional png as well -install -D -m 644 variety/data/media/variety128.png \ - %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/variety.png - -# Install man page (if exists) -if [ -f debian/%{name}.1 ]; then - install -D -m 644 debian/%{name}.1 %{buildroot}%{_mandir}/man1/%{name}.1 -fi - -rm -rf %{buildroot}%{python3_sitelib}/tests -rm -rf %{buildroot}%{python3_sitelib}/po +%{__python3} setup.py install --root=%{buildroot} %find_lang %{name} %check desktop-file-validate %{buildroot}%{_datadir}/applications/*.desktop appstream-util validate-relax --nonet %{buildroot}/%{_metainfodir}/%{name}.appdata.xml -#%%py3_check_import variety_lib.variety_build_settings %files -f %{name}.lang %doc README.md %license LICENSE %{_bindir}/%{name} %{_datadir}/applications/%{name}.desktop -%{_datadir}/icons/hicolor/scalable/apps/variety.svg -%{_datadir}/icons/hicolor/128x128/apps/variety.png %{_metainfodir}/%{name}.appdata.xml +%{_datadir}/%{name}/ %{python3_sitelib}/jumble/ -#%%{python3_sitelib}/tests/ -%{python3_sitelib}/%{name}-*.dist-info +%{python3_sitelib}/%{name}-*-py*.egg-info %{python3_sitelib}/%{name}/ %{python3_sitelib}/%{name}_lib/ -%{_mandir}/man1/%{name}.1* +%{_datadir}/icons/hicolor/22x22/apps/%{name}-indicator-dark.png +%{_datadir}/icons/hicolor/22x22/apps/%{name}-indicator.png +%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg %changelog -* Tue Sep 01 2026 Martin Gansser - 0.9.1-1 -- Update to 0.9.1-1 - -* Fri Jul 17 2026 Fedora Release Engineering - 0.9.0-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild - -* Thu Jun 04 2026 Python Maint - 0.9.0-2 -- Rebuilt for Python 3.15 - -* Wed May 06 2026 Martin Gansser - 0.9.0-1 -- Update to 0.9.0-1 - -* Wed Apr 29 2026 Martin Gansser - 0.9.0-0.2.beta1 -- add variety-GExiv2.patch fix (BZ#2463715) - -* Mon Mar 02 2026 Martin Gansser - 0.9.0-0.1.beta1 -- Update to 0.9.0-0.1.beta1 -- Add python3dist(setuptools-gettext) -- Fixed icon installation -- Fixed desktop validation -- Fixed setuptools discovery warnings - -* Sat Jan 17 2026 Fedora Release Engineering - 0.8.13-8 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild - -* Thu Oct 09 2025 Miro Hrončok - 0.8.13-7 -- Fix a crash on startup for not being bale to find the data directory -- Fixes: rhbz#2401190 - -* Fri Sep 19 2025 Python Maint - 0.8.13-6 -- Rebuilt for Python 3.14.0rc3 bytecode - -* Fri Aug 15 2025 Python Maint - 0.8.13-5 -- Rebuilt for Python 3.14.0rc2 bytecode - -* Fri Jul 25 2025 Fedora Release Engineering - 0.8.13-4 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild - -* Wed Jul 09 2025 Martin Gansser - 0.8.13-3 -- Updated to use %%pyproject_* macros - -* Tue Jun 03 2025 Python Maint - 0.8.13-2 -- Rebuilt for Python 3.14 +* Mon May 05 2025 Martin Gansser - 0.8.13-2 +- Rebuild * Wed Feb 26 2025 Martin Gansser - 0.8.13-1 - Update to 0.8.13