]>
Commit | Line | Data |
---|---|---|
1 | # | |
2 | # Conditional builds: | |
3 | %bcond_with apidocs # disable gtk-doc (there isn't any) | |
4 | %bcond_without nautilus # build without nautilus extensions | |
5 | # | |
6 | Summary: GKsu is a GTK+ frontend to the su program | |
7 | Summary(pl.UTF-8): GKsu to nakładka graficzna na program su | |
8 | Name: gksu | |
9 | Version: 2.0.0 | |
10 | Release: 4 | |
11 | License: GPL | |
12 | Group: X11/Applications/System | |
13 | Source0: http://people.debian.org/~kov/gksu/%{name}-%{version}.tar.gz | |
14 | # Source0-md5: f517302cff6f09e4f2f312c4b618bd40 | |
15 | URL: http://www.nongnu.org/gksu/ | |
16 | BuildRequires: GConf2-devel | |
17 | BuildRequires: autoconf >= 2.57 | |
18 | BuildRequires: automake | |
19 | BuildRequires: gettext-devel | |
20 | %{?with_nautilus:BuildRequires: gnome-vfs2-devel} | |
21 | BuildRequires: gtk+2-devel >= 2:2.4 | |
22 | %{?with_apidocs:BuildRequires: gtk-doc >= 1.0} | |
23 | BuildRequires: intltool | |
24 | BuildRequires: libgksu-devel >= 1.9.8 | |
25 | %{?with_nautilus:BuildRequires: libgksu-devel >= 2.0.0} | |
26 | BuildRequires: libtool | |
27 | %{?with_nautilus:BuildRequires: nautilus-devel} | |
28 | BuildRequires: pkgconfig | |
29 | Requires: /bin/su | |
30 | Obsoletes: gksu-devel | |
31 | Obsoletes: gksu-static | |
32 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
33 | ||
34 | %if %{with nautilus} | |
35 | %define specflags `pkg-config --cflags gnome-vfs-2.0` | |
36 | %define nautilus_extensiondir %( pkg-config --variable=extensiondir libnautilus-extension ) | |
37 | %endif | |
38 | ||
39 | %description | |
40 | GKsu is a GTK+ frontend to the su program. | |
41 | ||
42 | %description -l pl.UTF-8 | |
43 | GKsu to graficzna nakładka na program su. | |
44 | ||
45 | %package nautilus | |
46 | Summary: Gksu plugin for nautilus | |
47 | Summary(pl.UTF-8): Wtyczka gksu dla nautilusa | |
48 | Group: X11/Applications | |
49 | Requires: %{name} = %{version}-%{release} | |
50 | Requires: nautilus | |
51 | Obsoletes: gksu-nautilus-devel | |
52 | Obsoletes: gksu-nautilus-static | |
53 | ||
54 | %description nautilus | |
55 | Gksu plugin for nautilus. | |
56 | ||
57 | %description nautilus -l pl.UTF-8 | |
58 | Wtyczka gksu dla nautilusa. | |
59 | ||
60 | %prep | |
61 | %setup -q | |
62 | ||
63 | %build | |
64 | %{__intltoolize} | |
65 | %{__libtoolize} | |
66 | %{__aclocal} | |
67 | %{__autoconf} | |
68 | %{__automake} | |
69 | %configure \ | |
70 | --disable-static \ | |
71 | %{!?with_apidocs:--disable-gtk-doc} \ | |
72 | %{!?with_nautilus:--disable-nautilus-extension} \ | |
73 | --with-html-dir=%{_gtkdocdir} | |
74 | ||
75 | %{__make} | |
76 | ||
77 | %install | |
78 | rm -rf $RPM_BUILD_ROOT | |
79 | ||
80 | %{__make} install \ | |
81 | nautilus_extensiondir=%{nautilus_extensiondir} \ | |
82 | DESTDIR=$RPM_BUILD_ROOT | |
83 | ||
84 | # fix gksudo man link | |
85 | rm -f $RPM_BUILD_ROOT%{_mandir}/man1/gksudo.1 | |
86 | echo .so man1/gksu.1 > $RPM_BUILD_ROOT%{_mandir}/man1/gksudo.1 | |
87 | ||
88 | rm -f $RPM_BUILD_ROOT%{_libdir}/nautilus/extensions-2.0/*.la | |
89 | ||
90 | %find_lang %{name} | |
91 | ||
92 | %clean | |
93 | rm -rf $RPM_BUILD_ROOT | |
94 | ||
95 | %files -f %{name}.lang | |
96 | %defattr(644,root,root,755) | |
97 | %doc AUTHORS ChangeLog README | |
98 | %attr(755,root,root) %{_bindir}/gksu | |
99 | %attr(755,root,root) %{_bindir}/gksudo | |
100 | %{_desktopdir}/gksu.desktop | |
101 | %{_mandir}/man1/*.1* | |
102 | %{_pixmapsdir}/*.png | |
103 | %dir %{_datadir}/gksu | |
104 | %attr(755,root,root) %{_datadir}/gksu/gksu-migrate-conf.sh | |
105 | ||
106 | %if %{with nautilus} | |
107 | %files nautilus | |
108 | %defattr(644,root,root,755) | |
109 | %attr (755,root,root) %{nautilus_extensiondir}/libnautilus-gksu.so | |
110 | %endif |