## START: Set by rpmautospec ## (rpmautospec version 0.2.5) %define autorelease(e:s:pb:) %{?-p:0.}%{lua: release_number = 2; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{?dist} ## END: Set by rpmautospec %global extension sound-output-device-chooser %global uuid %{extension}@kgshank.net %global commit 4a6f0f2fc72eba991ffc3e75cc6a67620b580054 %global shortcommit %(c=%{commit}; echo ${c:0:7}) Name: gnome-shell-extension-%{extension} Version: 40^2.%{shortcommit} Release: %autorelease Summary: GNOME Shell extension for selecting sound devices License: GPLv3+ BuildArch: noarch URL: https://github.com/kgshank/gse-sound-output-device-chooser Source: %{url}/archive/%{commit}/%{extension}-%{shortcommit}.tar.gz # https://github.com/kgshank/gse-sound-output-device-chooser/issues/229 # https://github.com/kgshank/gse-sound-output-device-chooser/pull/230 Patch: 0001-Properly-fix-for-GNOME-42-gjs-1.72.0-229.patch BuildRequires: gettext Requires: gnome-shell-extension-common Requires: python3 Recommends: gnome-extensions-app %description Shows a list of sound output and input devices (similar to gnome sound settings) in the status menu below the volume slider. Various active ports like HDMI, speakers, etc. of the same device are also displayed for selection. %prep %autosetup -n gse-%{extension}-%{commit} -p 1 # relocate things we don't want copied into the extensions directory mv %{uuid}/locale . mv %{uuid}/schemas . # fix wrong-file-end-of-line-encoding rpmlint warning sed -e 's/\r$//' -i CHANGELOG.md %install install -d -m 0755 %{buildroot}%{_datadir}/gnome-shell/extensions # install main extension files cp -r --preserve=mode,timestamps %{uuid} %{buildroot}%{_datadir}/gnome-shell/extensions # install the schema file install -D -p -m 0644 \ schemas/org.gnome.shell.extensions.%{extension}.gschema.xml \ %{buildroot}%{_datadir}/glib-2.0/schemas/org.gnome.shell.extensions.%{extension}.gschema.xml # install locale files for po in locale/*/LC_MESSAGES/*.po; do install -d -m 0755 %{buildroot}%{_datadir}/$(dirname $po) msgfmt --output-file %{buildroot}%{_datadir}/${po%.po}.mo $po done %find_lang %{extension} %files -f %{extension}.lang %license LICENSE %doc README.md CHANGELOG.md %{_datadir}/gnome-shell/extensions/%{uuid} %{_datadir}/glib-2.0/schemas/org.gnome.shell.extensions.%{extension}.gschema.xml %changelog * Tue Mar 29 2022 Carl George 40^2.4a6f0f2-2 - Add patch to really fix GNOME 42 compatibility * Sun Mar 20 2022 Carl George 40^2.4a6f0f2-1 - Latest upstream snapshot (GNOME 42 compatibility) * Sun Jan 23 2022 Carl George 40^1.0702290-1 - Latest upstream snapshot * Thu Jan 20 2022 Fedora Release Engineering 39^1.8c90ed0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild * Sun Aug 29 2021 Carl George 39^1.8c90ed0-1 - Initial package rhbz#1998703