Skip to content

Commit 2fd70bf

Browse files
committed
feat(staging): Add yad
Signed-off-by: Zeglius <[email protected]>
1 parent bf17200 commit 2fd70bf

File tree

1 file changed

+90
-0
lines changed

1 file changed

+90
-0
lines changed

staging/yad/yad.spec

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
%global debug_package %{nil}
2+
# See: https://src.fedoraproject.org/rpms/yad/blob/rawhide/f/yad.spec
3+
4+
Name: yad
5+
# renovate: datasource=github-releases depName=v1cont/yad
6+
Version: 14.1
7+
Release: 1%{?dist}
8+
Summary: Display graphical dialogs from shell scripts or command line
9+
10+
License: GPL-3.0-or-later
11+
URL: https://github.com/v1cont/%{name}
12+
Source0: https://github.com/v1cont/%{name}/archive/refs/tags/v%{version}.tar.gz
13+
14+
BuildRequires: make
15+
BuildRequires: gtk3-devel >= 3.22.0
16+
BuildRequires: webkit2gtk4.1-devel
17+
BuildRequires: desktop-file-utils
18+
BuildRequires: perl(XML::Parser)
19+
BuildRequires: intltool >= 0.40.0
20+
BuildRequires: pkgconfig
21+
BuildRequires: gettext
22+
BuildRequires: gtksourceview3-devel
23+
BuildRequires: gspell-devel
24+
25+
BuildRequires: gcc
26+
27+
28+
%description
29+
Yad (yet another dialog) is a fork of zenity with many improvements, such as
30+
custom buttons, additional dialogs, pop-up menu in notification icon and more.
31+
32+
33+
%prep
34+
%setup -q
35+
36+
37+
%build
38+
%configure
39+
40+
make %{?_smp_mflags}
41+
42+
43+
%install
44+
make install DESTDIR=%{buildroot}
45+
46+
rm -f %{buildroot}%{_bindir}/pfd
47+
48+
%find_lang %{name}
49+
50+
# Encoding key in group "Desktop Entry" is deprecated.
51+
# Place the menu entry for yad-icon-browser under "Utilities".
52+
desktop-file-install --remove-key Encoding \
53+
--remove-category Development \
54+
--add-category Utility \
55+
--dir=%{buildroot}%{_datadir}/applications \
56+
%{buildroot}%{_datadir}/applications/%{name}-icon-browser.desktop
57+
58+
59+
%post
60+
update-desktop-database %{_datadir}/applications &>/dev/null || :
61+
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
62+
63+
64+
%postun
65+
update-desktop-database %{_datadir}/applications &>/dev/null || :
66+
if [ $1 -eq 0 ] ; then
67+
/usr/bin/glib-compile-schemas %{_datadir}/glib-2.0/schemas &>/dev/null || :
68+
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
69+
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
70+
fi
71+
72+
73+
%posttrans
74+
/usr/bin/glib-compile-schemas %{_datadir}/glib-2.0/schemas &>/dev/null || :
75+
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
76+
77+
78+
%files -f %{name}.lang
79+
%doc README.md AUTHORS NEWS THANKS TODO
80+
%license COPYING
81+
%{_bindir}/*
82+
%{_datadir}/icons/hicolor/*/apps/*
83+
%{_datadir}/applications/*.desktop
84+
%{_datadir}/glib-2.0/schemas/*
85+
%{_datadir}/aclocal/%{name}.m4
86+
%{_mandir}/*/*
87+
88+
89+
%changelog
90+
%autochangelog

0 commit comments

Comments
 (0)