1 |
%define pkgname GConf |
2 |
%define api_version 2 |
3 |
%define gi_version %{api_version}.0 |
4 |
%define lib_major 4 |
5 |
%define lib_name %mklibname %{pkgname} %{api_version} %{lib_major} |
6 |
%define gi_name %mklibname gconf-gir %{gi_version} |
7 |
%define lib_namedev %mklibname -d %{pkgname} %{api_version} |
8 |
|
9 |
%define url_ver %(echo %{version} | cut -d. -f1,2) |
10 |
|
11 |
Summary: A configuration database system for GNOME |
12 |
Name: %{pkgname}%{api_version} |
13 |
Version: 3.1.6 |
14 |
Release: %mkrel 1 |
15 |
License: LGPLv2+ |
16 |
Group: Graphical desktop/GNOME |
17 |
URL: http://www.gnome.org/projects/gconf/ |
18 |
Source0: ftp://ftp.gnome.org/pub/GNOME/sources/%{pkgname}/%{url_ver}/%{pkgname}-%{version}.tar.xz |
19 |
Source1: gconf.sh |
20 |
Source2: gconf.csh |
21 |
Source3: gconf-schemas.filter |
22 |
Source4: gconf-schemas.script |
23 |
# (fc) reload database when schemas are installed/uninstalled (GNOME bug #328697) |
24 |
Patch1: GConf-2.12.1-reload.patch |
25 |
Conflicts: GConf < 1.0.6 |
26 |
BuildRequires: pkgconfig(dbus-1) >= 1.0.0 |
27 |
BuildRequires: pkgconfig(dbus-glib-1) >= 0.74 |
28 |
BuildRequires: pkgconfig(gio-2.0) >= 2.25.9 |
29 |
BuildRequires: pkgconfig(glib-2.0) > 2.14.0 |
30 |
BuildRequires: pkgconfig(gmodule-2.0) >= 2.7.0 |
31 |
BuildRequires: pkgconfig(gobject-2.0) >= 2.7.0 |
32 |
BuildRequires: pkgconfig(gthread-2.0) |
33 |
BuildRequires: pkgconfig(gtk+-3.0) >= 2.90 |
34 |
BuildRequires: pkgconfig(libxml-2.0) |
35 |
BuildRequires: pkgconfig(ORBit-2.0) >= 2.4.0 |
36 |
BuildRequires: pkgconfig(polkit-gobject-1) |
37 |
BuildRequires: openldap-devel |
38 |
BuildRequires: autoconf |
39 |
BuildRequires: gtk-doc |
40 |
BuildRequires: intltool >= 0.35.0 |
41 |
BuildRequires: gobject-introspection-devel >= 0.9.5 |
42 |
Requires: polkit-agent |
43 |
Requires: gsettings-desktop-schemas |
44 |
Requires: %{lib_name} = %{version} |
45 |
# needed by patch1 |
46 |
Requires: psmisc |
47 |
Requires: sed |
48 |
Requires(post): update-alternatives |
49 |
Suggests: dconf |
50 |
|
51 |
%description |
52 |
GConf is a configuration data storage mechanism scheduled to |
53 |
ship with GNOME. GConf does work without GNOME however; it |
54 |
can be used with plain GTK+, Xlib, KDE, or even text mode |
55 |
applications as well. |
56 |
|
57 |
%package sanity-check |
58 |
Summary: Sanity checker for %{pkgname}%{api_version} |
59 |
Group: %{group} |
60 |
Conflicts: %name < 2.21.90-2mdv |
61 |
|
62 |
%description sanity-check |
63 |
gconf-sanity-check is a tool to check the sanity of a %{pkgname}%{api_version} |
64 |
installation. |
65 |
|
66 |
%package -n %{lib_name} |
67 |
Summary: %{summary} |
68 |
Group: System/Libraries |
69 |
Requires: %{name} >= %{version} |
70 |
Conflicts: gir-repository < 0.6.5-12 |
71 |
|
72 |
%description -n %{lib_name} |
73 |
GConf is a configuration data storage mechanism scheduled to |
74 |
ship with GNOME. GConf does work without GNOME however; it |
75 |
can be used with plain GTK+, Xlib, KDE, or even text mode |
76 |
applications as well. |
77 |
|
78 |
This package contains necessary libraries to run any programs linked |
79 |
with GConf. |
80 |
|
81 |
%package -n %{gi_name} |
82 |
Summary: GObject introspection interface library for %{pkgname} |
83 |
Group: System/Libraries |
84 |
Requires: %{lib_name} = %{version}-%{release} |
85 |
|
86 |
%description -n %{gi_name} |
87 |
GObject introspection interface library for %{pkgname}. |
88 |
|
89 |
%package -n %{lib_namedev} |
90 |
Summary: Development libraries and headers for GConf |
91 |
Group: Development/GNOME and GTK+ |
92 |
Conflicts: libGConf1-devel < 1.0.6 |
93 |
Provides: lib%{name}-devel = %{version}-%{release} |
94 |
Requires: %{lib_name} = %{version} |
95 |
Requires: %name-sanity-check = %version |
96 |
Obsoletes: %mklibname -d %{name}_ 4 |
97 |
Conflicts: gir-repository < 0.6.5-12 |
98 |
|
99 |
%description -n %{lib_namedev} |
100 |
GConf is a configuration data storage mechanism scheduled to |
101 |
ship with GNOME. GConf does work without GNOME however; it |
102 |
can be used with plain GTK+, Xlib, KDE, or even text mode |
103 |
applications as well. |
104 |
|
105 |
This package contains the header files and libraries needed to develop |
106 |
applications using GConf. |
107 |
|
108 |
%prep |
109 |
%setup -q -n %{pkgname}-%{version} |
110 |
%apply_patches |
111 |
|
112 |
%build |
113 |
%configure2_5x --with-gtk=3.0 |
114 |
%make |
115 |
|
116 |
%install |
117 |
%makeinstall_std |
118 |
|
119 |
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/profile.d |
120 |
install -m 755 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d/gconf.sh |
121 |
install -m 755 %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d/gconf.csh |
122 |
|
123 |
mkdir %{buildroot}%{_sysconfdir}/gconf/schemas |
124 |
|
125 |
# Provide /usr/lib/gconfd-2 symlink on lib64 platforms |
126 |
%if "%{_lib}" != "lib" |
127 |
mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib |
128 |
ln -s ../%{_lib}/gconfd-%{api_version} $RPM_BUILD_ROOT%{_prefix}/lib/gconfd-%{api_version} |
129 |
%endif |
130 |
|
131 |
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/gconf/{gconf.xml.local-defaults,gconf.xml.local-mandatory,gconf.xml.system} |
132 |
|
133 |
cat << EOF > $RPM_BUILD_ROOT%{_sysconfdir}/gconf/2/local-defaults.path |
134 |
xml:readonly:/etc/gconf/gconf.xml.local-defaults |
135 |
include "\$(HOME)/.gconf.path.defaults" |
136 |
EOF |
137 |
|
138 |
cat << EOF > $RPM_BUILD_ROOT%{_sysconfdir}/gconf/2/local-mandatory.path |
139 |
xml:readonly:/etc/gconf/gconf.xml.local-mandatory |
140 |
include "\$(HOME)/.gconf.path.mandatory" |
141 |
EOF |
142 |
|
143 |
# automatic install of gconf schemas on rpm installs |
144 |
# (see http://wiki.mandriva.com/en/Rpm_filetriggers) |
145 |
install -d %buildroot%{_var}/lib/rpm/filetriggers |
146 |
install -m 644 %{SOURCE3} %buildroot%{_var}/lib/rpm/filetriggers |
147 |
install -m 755 %{SOURCE4} %buildroot%{_var}/lib/rpm/filetriggers |
148 |
|
149 |
%{find_lang} %{name} |
150 |
|
151 |
# remove unpackaged files |
152 |
rm -f $RPM_BUILD_ROOT%{_libdir}/{gio/modules/,GConf/%{api_version}}/*.a |
153 |
|
154 |
%clean |
155 |
rm -rf %{buildroot} |
156 |
|
157 |
# remove buggy symlink |
158 |
%post |
159 |
update-alternatives --install %{_bindir}/gconftool gconftool /usr/bin/gconftool-%{api_version} 20 |
160 |
if [ "$1" = "2" ]; then |
161 |
update-alternatives --auto gconftool |
162 |
fi |
163 |
|
164 |
%triggerpostun -- GConf2 < 2.22.0-4mdv |
165 |
GCONF_CONFIG_SOURCE=`%{_bindir}/gconftool-2 --get-default-source` %{_bindir}/gconftool-2 --makefile-install-rule %{_sysconfdir}/gconf/schemas/*.schemas > /dev/null |
166 |
|
167 |
%files -f %{name}.lang |
168 |
%defattr(-, root, root) |
169 |
%doc README |
170 |
%config(noreplace) %{_sysconfdir}/profile.d/* |
171 |
%config(noreplace) %_sysconfdir/dbus-1/system.d/org.gnome.GConf.Defaults.conf |
172 |
%_sysconfdir/xdg/autostart/gsettings-data-convert.desktop |
173 |
%_bindir/gsettings-data-convert |
174 |
%_bindir/gsettings-schema-convert |
175 |
%{_bindir}/gconftool* |
176 |
%{_bindir}/gconf-merge-tree |
177 |
%_mandir/man1/gconftool-2.1* |
178 |
%_mandir/man1/gsettings-data-convert.1* |
179 |
%_mandir/man1/gsettings-schema-convert.1* |
180 |
%if "%{_lib}" != "lib" |
181 |
%{_prefix}/lib/gconfd-%{api_version} |
182 |
%endif |
183 |
%{_libexecdir}/gconfd-%{api_version} |
184 |
%{_libexecdir}/gconf-defaults-mechanism |
185 |
%dir %{_libdir}/GConf |
186 |
%dir %{_libdir}/GConf/%{api_version} |
187 |
%{_libdir}/GConf/%{api_version}/*.so |
188 |
%config(noreplace) %{_sysconfdir}/gconf/%{api_version} |
189 |
%dir %{_sysconfdir}/gconf |
190 |
%dir %{_sysconfdir}/gconf/gconf.xml* |
191 |
%dir %{_sysconfdir}/gconf/schemas |
192 |
%{_datadir}/polkit-1/actions/org.gnome.gconf.defaults.policy |
193 |
%{_datadir}/sgml/gconf |
194 |
%{_datadir}/GConf |
195 |
%{_datadir}/dbus-1/services/org.gnome.GConf.service |
196 |
%{_datadir}/dbus-1/system-services/org.gnome.GConf.Defaults.service |
197 |
%{_var}/lib/rpm/filetriggers/gconf-schemas.* |
198 |
|
199 |
# (blino) split gconf-sanity-check not to require gtk in GConf2 |
200 |
%files sanity-check |
201 |
%{_libexecdir}/gconf-sanity-check-%{api_version} |
202 |
|
203 |
%files -n %{lib_name} |
204 |
%defattr(-, root, root) |
205 |
%doc README |
206 |
%{_libdir}/lib*.so.* |
207 |
%{_libdir}/gio/modules/libgsettingsgconfbackend.so |
208 |
%{_libdir}/gio/modules/libgsettingsgconfbackend.la |
209 |
|
210 |
%files -n %{gi_name} |
211 |
%{_libdir}/girepository-1.0/GConf-%{gi_version}.typelib |
212 |
|
213 |
%files -n %{lib_namedev} |
214 |
%defattr (-, root, root) |
215 |
%doc ChangeLog TODO NEWS AUTHORS |
216 |
%doc %{_datadir}/gtk-doc/html/* |
217 |
%{_datadir}/aclocal/* |
218 |
%{_includedir}/* |
219 |
%{_libdir}/*.so |
220 |
%attr(644,root,root) %{_libdir}/*a |
221 |
%{_libdir}/pkgconfig/* |
222 |
%attr(644,root,root) %{_libdir}/GConf/%{api_version}/*.la |
223 |
%{_datadir}/gir-1.0/GConf-%{gi_version}.gir |
224 |
|
225 |
|
226 |
|
227 |
|