1 |
%define url_ver %(echo %{version}|cut -d. -f1,2) |
2 |
|
3 |
Summary: GNOME default icons |
4 |
Name: gnome-icon-theme |
5 |
Version: 3.10.0 |
6 |
%define subrel 2 |
7 |
Release: %mkrel 2 |
8 |
License: GPLv2+ |
9 |
Group: Graphical desktop/GNOME |
10 |
URL: http://www.gnome.org/ |
11 |
Source0: https://download.gnome.org/sources/%{name}/%{url_ver}/%{name}-%{version}.tar.xz |
12 |
BuildRequires: intltool |
13 |
BuildRequires: hicolor-icon-theme |
14 |
BuildRequires: icon-naming-utils >= 0.8.7 |
15 |
BuildRequires: gtk+2.0 |
16 |
BuildArch: noarch |
17 |
Requires: hicolor-icon-theme |
18 |
Requires(post): gtk+2.0 >= 2.6.0 |
19 |
Requires(postun): gtk+2.0 >= 2.6.0 |
20 |
|
21 |
%description |
22 |
GNOME default icons |
23 |
|
24 |
%prep |
25 |
%setup -q |
26 |
|
27 |
%build |
28 |
%configure2_5x --enable-icon-mapping |
29 |
%make |
30 |
|
31 |
%install |
32 |
rm -rf $RPM_BUILD_ROOT |
33 |
|
34 |
%makeinstall_std |
35 |
touch %buildroot%{_datadir}/icons/gnome/icon-theme.cache |
36 |
|
37 |
# automatic gtk icon cache update on rpm installs/removals |
38 |
# (see http://wiki.mandriva.com/en/Rpm_filetriggers) |
39 |
install -d %buildroot%{_var}/lib/rpm/filetriggers |
40 |
cat > %buildroot%{_var}/lib/rpm/filetriggers/gtk-icon-cache-gnome.filter << EOF |
41 |
^./usr/share/icons/gnome/ |
42 |
EOF |
43 |
cat > %buildroot%{_var}/lib/rpm/filetriggers/gtk-icon-cache-gnome.script << EOF |
44 |
#!/bin/sh |
45 |
if [ -x /usr/bin/gtk-update-icon-cache ]; then |
46 |
/usr/bin/gtk-update-icon-cache --force --quiet /usr/share/icons/gnome |
47 |
fi |
48 |
EOF |
49 |
chmod 755 %buildroot%{_var}/lib/rpm/filetriggers/gtk-icon-cache-gnome.script |
50 |
|
51 |
%post |
52 |
if [ -x %{_bindir}/gtk-update-icon-cache -a -r %{_iconsdir}/gnome/index.theme ]; then |
53 |
%{_bindir}/gtk-update-icon-cache --force --quiet %{_iconsdir}/gnome |
54 |
fi |
55 |
|
56 |
%postun |
57 |
if [ -x %{_bindir}/gtk-update-icon-cache -a -r %{_iconsdir}/gnome/index.theme ]; then |
58 |
%{_bindir}/gtk-update-icon-cache --force --quiet %{_iconsdir}/gnome |
59 |
fi |
60 |
|
61 |
%files |
62 |
%doc README TODO |
63 |
%dir %{_datadir}/icons/gnome |
64 |
%{_datadir}/icons/gnome/*x* |
65 |
%_datadir/pkgconfig/%name.pc |
66 |
%ghost %{_datadir}/icons/gnome/icon-theme.cache |
67 |
%{_var}/lib/rpm/filetriggers/gtk-icon-cache-gnome.* |