File sfwbar.spec of Package sfwbar

#
# spec file for package sfwbar
#
# Copyright (c) 2025 mantarimay
# Copyright (c) 2024 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/
#


%bcond_without test
%define vbeta   1.0_beta16.1
Name:           sfwbar
Version:        @SERVICE@
Release:        0
Summary:        GTK-based taskbar for Wayland
License:        GPL-3.0-only
URL:            https://github.com/LBCrion/sfwbar
Source:         %{url}/archive/v%{version}/%{name}-%{version}.tar.xz
BuildRequires:  fdupes
BuildRequires:  meson
BuildRequires:  pkgconfig
BuildRequires:  scdoc
BuildRequires:  python3-docutils
BuildRequires:  pkgconfig(alsa)
BuildRequires:  pkgconfig(gtk+-3.0)
BuildRequires:  pkgconfig(gtk-layer-shell-0)
BuildRequires:  pkgconfig(json)
BuildRequires:  pkgconfig(json-c)
BuildRequires:  pkgconfig(libmpdclient)
BuildRequires:  pkgconfig(libpipewire-0.3)
BuildRequires:  pkgconfig(libpulse)
BuildRequires:  pkgconfig(libpulse-mainloop-glib)
BuildRequires:  pkgconfig(libpulse-simple)
BuildRequires:  pkgconfig(pam)
BuildRequires:  pkgconfig(xkbregistry)
BuildRequires:  pkgconfig(wayland-client)
BuildRequires:  pkgconfig(wayland-protocols)
Requires:       python3

%description
SFWBar (S* Floating Window Bar) is a flexible taskbar application for
wayland compositors, designed with a stacking layout in mind.

%lang_package

%prep
%autosetup -n %{name}-%{version}

sed -i "s/env python3/python3/" config/{battery,startmenu,battery-svg}.widget

%build
%meson
#-D alsa=disabled -D pulse=disabled -D mpd=disabled

%meson_build

%install
%meson_install

%fdupes %{buildroot}%{_datadir}

%check
%if %{with test}
%meson_test
%endif

%files
%license LICENSE
%doc README.md doc/ChangeLog
%{_libdir}/*sfwbar*
%{_bindir}/*
%{_mandir}/man*/*
%{_datadir}/sfwbar
%{_datadir}/icons/hicolor/scalable/apps/sfwbar.svg

%files lang
%{_datadir}/locale/*

%changelog
openSUSE Build Service is sponsored by