]> git.pld-linux.org Git - packages/poldek.git/blame - poldek.spec
initial tool to ease common operations like:
[packages/poldek.git] / poldek.spec
CommitLineData
7638abfc 1#
de1099c4 2# Conditional build:
9fe14a3f 3%bcond_with static # don't use shared libraries
4%bcond_without imode # don't build interactive mode
58c31de0 5%bcond_without python # don't build python bindings
cf6c3a30 6%bcond_with snap # install configs for official Th snapshot
1fde4642 7%bcond_with db61 # DB 6.1 instead of 5.2
dbf5b095 8%bcond_with rpm4 # use rpm4/db4.7 instead of rpm5
7000d724 9
e1015166 10# current snapshot name
42c61fde 11%define SNAP 2014
a584c5c5 12
373c6f03 13# required versions (forced to avoid SEGV with mixed db used by rpm and poldek)
6e185c37 14# NOTE: poldek links with "system db" (-ldb) anyway if it exists
1fde4642
JB
15%if %{with db61}
16%define db_pkg db6.1
17%define ver_db 6.1
6e185c37
JB
18%define ver_db_rel 1
19%else
ff4e68af 20%define db_pkg db5.2
376a705c 21%define ver_db 5.2
19e679c6 22%define ver_db_rel 3
6e185c37 23%endif
5fda028a
ER
24
25%if %{with rpm4}
26%define ver_db 4.7.25
27%define ver_db_rel 1
28%define ver_rpm 4.5-49
29%else
a17726b5 30%define ver_rpm 5.4.10
5fda028a 31%endif
7000d724 32
966a5e45 33%define rel 10
b44549bf 34Summary: RPM packages management helper tool
9c03ea8f 35Summary(hu.UTF-8): RPM csomagkezelést segítő eszköz
9faf625a 36Summary(pl.UTF-8): Pomocnicze narzędzie do zarządzania pakietami RPM
b44549bf 37Name: poldek
e8dadd74 38Version: 0.30.1
9c1c2b52 39Release: %{rel}%{?with_snap:.%{SNAP}}
9f931ada 40License: GPL v2
8efee472 41Group: Applications/System
85398bac 42#Source0: http://poldek.pld-linux.org/download/snapshots/%{name}-%{version}-cvs%{snap}.tar.bz2
e5009a66 43Source0: http://carme.pld-linux.org/~megabajt/releases/poldek/%{name}-%{version}.tar.xz
e8dadd74 44# Source0-md5: e569c8454df0932df53b09cee9998927
911a8560 45Source1: %{name}.conf
b25cb9a7 46Source2: %{name}-multilib.conf
2ccd5d66 47Source5: %{name}-aliases.conf
48Source6: %{name}.desktop
49Source7: %{name}.png
171e07f6 50Source8: %{name}-debuginfo.conf
652b5bc5 51Source9: %{name}-aidath.conf
52Source10: %{name}-multilib-aidath.conf
8db66c11 53Source11: %{name}-archive.conf
a584c5c5
JR
54Source100: %{name}-snap.conf
55Source101: %{name}-multilib-snap.conf
56Source102: %{name}-debuginfo-snap.conf
e5009a66 57Patch0: %{name}-size-type.patch
e8dadd74 58Patch1: %{name}-config.patch
1cf9975a 59Patch2: %{name}-missing-include.patch
c5d1808a 60Patch3: pm-hooks.patch
15f4d0b4 61Patch4: poldek-setenv-null.patch
966a5e45 62Patch5: %{name}-assert-sigint.patch
39ca2371 63URL: http://poldek.pld-linux.org/
340a1e21 64BuildRequires: %{db_pkg}-devel >= %{ver_db}-%{ver_db_rel}
a4268952 65BuildRequires: autoconf
4d0dcbcf 66BuildRequires: automake >= 1:1.11
373c6f03 67BuildRequires: bzip2-devel
065b86e0 68BuildRequires: check-devel
1d67e563 69BuildRequires: docbook-dtd412-xml
22329ccf 70BuildRequires: gettext-tools
b25cb9a7
JB
71BuildRequires: libtool
72BuildRequires: libxml2-devel
fc37ede0 73BuildRequires: neon-devel
cbc6f56b 74BuildRequires: openssl-devel >= 0.9.7d
13fd950e 75BuildRequires: pcre-devel
b3ea4b51 76BuildRequires: pkgconfig
13fd950e 77BuildRequires: popt-devel
58c31de0 78%{?with_python:BuildRequires: python-devel}
b25cb9a7 79BuildRequires: readline-devel >= 5.0
373c6f03 80BuildRequires: rpm-devel >= %{ver_rpm}
300927eb 81%{?with_python:BuildRequires: rpm-pythonprov}
65a99b8b 82BuildRequires: swig-python
340a1e21 83BuildRequires: tar >= 1:1.22
77cfda6e 84BuildRequires: xmlto
340a1e21 85BuildRequires: xz
96475e5e 86BuildRequires: zlib-devel
373c6f03 87%if %{with static}
ff4e68af 88BuildRequires: %{db_pkg}-static >= %{ver_db}-%{ver_db_rel}
340a1e21 89BuildRequires: bzip2-static
2fac0b02 90BuildRequires: glibc-static
b25cb9a7 91BuildRequires: libxml2-static
373c6f03
JB
92BuildRequires: ncurses-static
93BuildRequires: openssl-static
94BuildRequires: pcre-static
95BuildRequires: popt-static
96BuildRequires: readline-static
97BuildRequires: rpm-static
98BuildRequires: zlib-static
373c6f03 99%endif
b25cb9a7 100Requires(triggerpostun): awk
168acc54 101Requires(triggerpostun): sed >= 4.0
ff4e68af 102Requires: %{db_pkg} >= %{ver_db}-%{ver_db_rel}
340a1e21 103Requires: %{name}-libs = %{version}-%{release}
67e6053c 104Requires: /bin/run-parts
373c6f03 105Requires: rpm >= %{ver_rpm}
530c8c41 106Requires: rpm-db-ver = %{ver_db}
5fda028a 107Requires: rpm-lib >= %{ver_rpm}
e202a52a 108Requires: sed
c5d1808a 109Conflicts: etckeeper < 1.18-2
b44549bf 110BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
111
dcdcebb7
ER
112%define _libexecdir %{_prefix}/lib/%{name}
113
b44549bf 114%description
0fa0dc36 115poldek is an RPM package management tool which allows you to easily
116perform package verification, installation (including system
13fd950e 117installation from scratch), upgrading, and removal.
0fa0dc36 118
13fd950e
JB
119Program can be used in batch (like apt-get from Debian's APT) or
120interactive mode. The interactive mode puts you into a readline
121interface with command line autocompletion and history, similar to the
122shell mode of Perl's CPAN.
8efee472 123
9fe14a3f 124%{?with_static:This version is statically linked.}
d94b28a6 125
9fe14a3f 126%{!?with_imode:This version hasn't got interactive mode.}
7f07e487 127#'vim
1f84648f 128
9c03ea8f
ZU
129%description -l hu.UTF-8
130poldek egy RPM csomagkezelő eszköz, amely megkönnyíti a
131csomagellenőrzést, telepítést (beleértve a rendszertelepítést a
132nulláról), frissítést és eltávolítást.
133
134A program használható parancssorból (mint a Debian apt-get programja)
135vagy interaktív módban. Az interaktív mód egy readline környezetet
136jelent, parancskiegészítéssel és előzményekkel, hasonlóan a Perl CPAN
137shell módjához.
138
139%{?with_static:Ez a verzió statikusan linkelt.}
140
141%{!?with_imode:Ennek a verziónak nincs interaktív módja.}
142
caed9b36
JR
143%description -l pl.UTF-8
144poldek jest narzędziem linii poleceń służącym do weryfikacji,
145instalacji (włączając instalację systemu od zera), aktualizacji i
146usuwania pakietów.
56e1ab51 147
caed9b36 148Program może być używany w trybie wsadowym (jak debianowy apt-get) lub
d82a9cb2 149interaktywnym. Tryb interaktywny posiada interfejs readline z
caed9b36
JR
150dopełnianiem komend i historią, podobny do trybu shell perlowego
151modułu CPAN.
8efee472 152
9fe14a3f 153%{?with_static:Ta wersja jest konsolidowana statycznie.}
a611e0bc 154
9fe14a3f 155%{!?with_imode:Ta wersja nie posiada trybu interaktywnego.}
b44549bf 156
b25cb9a7 157%package libs
168acc54 158Summary: poldek libraries
9c03ea8f 159Summary(hu.UTF-8): A poldek könyvtárai
9faf625a 160Summary(pl.UTF-8): Biblioteki poldka
168acc54 161Group: Libraries
b25cb9a7
JB
162
163%description libs
164poldek libraries.
165
9c03ea8f
ZU
166%description libs -l hu.UTF-8
167A poldek könyvtárai.
168
caed9b36 169%description libs -l pl.UTF-8
b25cb9a7
JB
170Biblioteki poldka.
171
172%package devel
168acc54 173Summary: Header files for poldek libraries
9c03ea8f 174Summary(hu.UTF-8): A poldek könyvtár fejlesztői fájljai
9faf625a 175Summary(pl.UTF-8): Pliki nagłówkowe bibliotek poldka
168acc54 176Group: Development/Libraries
09d4c571 177Requires: %{name}-libs = %{version}-%{release}
b980560b 178Requires: rpm-devel >= %{ver_rpm}
b25cb9a7
JB
179
180%description devel
181Header files for poldek libraries.
182
9c03ea8f
ZU
183%description devel -l hu.UTF-8
184A poldek könyvtár fejlesztői fájljai.
185
caed9b36
JR
186%description devel -l pl.UTF-8
187Pliki nagłówkowe bibliotek poldka.
b25cb9a7
JB
188
189%package static
168acc54 190Summary: poldek static libraries
9c03ea8f 191Summary(hu.UTF-8): poldek statikus könyvtárak
9faf625a 192Summary(pl.UTF-8): Biblioteki statyczne poldka
168acc54 193Group: Development/Libraries
09d4c571 194Requires: %{name}-devel = %{version}-%{release}
b25cb9a7
JB
195
196%description static
197poldek static libraries.
198
9c03ea8f
ZU
199%description static -l hu.UTF-8
200poldek statikus könyvtárak.
201
caed9b36 202%description static -l pl.UTF-8
b25cb9a7
JB
203Biblioteki statyczne poldka.
204
58c31de0
JB
205%package -n python-poldek
206Summary: Python modules for poldek
9c03ea8f 207Summary(hu.UTF-8): Python modulok poldek-hez
9faf625a 208Summary(pl.UTF-8): Moduły języka Python dla poldka
58c31de0
JB
209Group: Libraries/Python
210Requires: %{name}-libs = %{version}-%{release}
340a1e21 211Requires: python-libs
58c31de0
JB
212
213%description -n python-poldek
214Python modules for poldek.
215
9c03ea8f
ZU
216%description -n python-poldek -l hu.UTF-8
217Python modulok poldek-hez.
218
caed9b36
JR
219%description -n python-poldek -l pl.UTF-8
220Moduły języka Python dla poldka.
58c31de0 221
03159b71 222%prep
a9c9446a 223%setup -q
85398bac 224%patch0 -p1
13aa6434 225%patch1 -p1
1cf9975a 226%patch2 -p1
c5d1808a 227%patch3 -p1
15f4d0b4 228%patch4 -p1
966a5e45 229%patch5 -p1
8dcb75fc 230
5e2c5cc3 231%{__rm} m4/libtool.m4 m4/lt*.m4
b44549bf 232
0579f9b7
ER
233# cleanup backups after patching
234find . '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
4fa2b79c 235chmod u+x ./configure ./doc/conf-xml2.sh
0579f9b7 236
b44549bf 237%build
5c81138a 238%{__gettextize}
bef9d2a3 239%{__libtoolize}
21a83253 240%{__aclocal} -I m4
d878a63c 241%{__autoheader}
21a83253
MM
242%{__autoconf}
243%{__automake}
f8e81a61 244cd tndb
313cd172 245%{__libtoolize}
5e2c5cc3
JB
246%{__aclocal}
247%{__autoheader}
248%{__autoconf}
249%{__automake}
f8e81a61 250cd ../trurlib
313cd172 251%{__libtoolize}
5e2c5cc3
JB
252%{__aclocal}
253%{__autoheader}
254%{__autoconf}
255%{__automake}
f8e81a61 256cd ..
b25cb9a7 257
3e975db6 258CPPFLAGS="%{rpmcppflags} -std=gnu99 -fgnu89-inline"
1f84648f 259%configure \
b25cb9a7 260 %{?with_static:--enable-static --disable-shared} \
9fe14a3f 261 %{!?with_imode:--disable-imode} \
dcdcebb7 262 --with-pkglibdir=%{_libexecdir} \
58c31de0
JB
263 --enable-nls \
264 %{?with_python:--with-python}
9fb594dc 265%{__make} -j1
a1f22296 266# --enable-trace
8efee472 267
b44549bf 268%install
269rm -rf $RPM_BUILD_ROOT
c5d1808a 270install -d $RPM_BUILD_ROOT/var/cache/%{name}
8efee472 271
9fb594dc 272%{__make} install -j1 \
c8f7d829 273 DESTDIR=$RPM_BUILD_ROOT
de1099c4 274
58c31de0 275%if %{with python}
9fb594dc 276%{__make} -C python -j1 install \
58c31de0
JB
277 DESTDIR=$RPM_BUILD_ROOT \
278 libdir=%{py_sitedir}
279%endif
280
5e2c5cc3 281%{?with_static:%{__rm} $RPM_BUILD_ROOT%{_bindir}/rpmvercmp}
a49836bb 282
9639596f 283%ifarch i486 i686 ppc sparc alpha athlon
bd621c72 284 %define ftp_arch %{_target_cpu}
36004ea3 285%endif
9639596f 286%ifarch %{x8664}
bd621c72
ER
287 %define ftp_arch x86_64
288 %define ftp_alt_arch i686
289 %define ftp_alt2_arch x32
fabc4b40
JR
290%endif
291%ifarch x32
bd621c72
ER
292 %define ftp_arch x32
293 %define ftp_alt_arch x86_64
294 %define ftp_alt2_arch i686
36004ea3 295%endif
9639596f 296%ifarch i586
bd621c72 297 %define ftp_arch i486
58820d9b 298%endif
a49836bb 299%ifarch pentium2 pentium3 pentium4
bd621c72 300 %define ftp_arch i686
36004ea3 301%endif
a49836bb 302%ifarch sparcv9 sparc64
bd621c72
ER
303 %define ftp_arch sparc
304 %define ftp_arch %{_target_cpu}
b614e8f7 305 %ifarch sparc64
bd621c72 306 %define ftp_alt_arch sparcv9
23ead09a 307 %endif
652b5bc5 308%endif
32697bd0 309
b614e8f7
JR
310%define pld_conf %{SOURCE1}
311%define pld_debuginfo_conf %{SOURCE8}
312%define pld_archive_conf %{SOURCE11}
7c0e4fc5 313
fabc4b40 314%ifarch %{x8664} x32
b614e8f7 315 %define pld_multilib_conf %{SOURCE2}
fabc4b40 316 %define pld_multilib2_conf %{SOURCE2}
b614e8f7 317%endif
7c0e4fc5 318
b614e8f7
JR
319# aidath
320%ifarch sparcv9 sparc64
321 %define pld_conf %{SOURCE9}
322 %undefine pld_archive_conf
323%endif
324%ifarch sparc64
325 %define pld_multilib_conf %{SOURCE10}
7c0e4fc5 326%endif
23ead09a 327
bd621c72 328%{__sed} -e 's|%%ARCH%%|%{ftp_arch}|g' < %{pld_conf} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld.conf
23ead09a 329
7c0e4fc5 330%if 0%{?pld_multilib_conf:1}
bd621c72 331 %{__sed} 's|%%ARCH%%|%{ftp_alt_arch}|g' < %{pld_multilib_conf} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{ftp_alt_arch}.conf
7c0e4fc5
ER
332%endif
333
fabc4b40 334%if 0%{?pld_multilib2_conf:1}
bd621c72 335 %{__sed} 's|%%ARCH%%|%{ftp_alt2_arch}|g' < %{pld_multilib_conf} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{ftp_alt2_arch}.conf
fabc4b40
JR
336%endif
337
7c0e4fc5 338%if 0%{?pld_debuginfo_conf:1}
bd621c72 339%{__sed} -e 's|%%ARCH%%|%{ftp_arch}|g' < %{pld_debuginfo_conf} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-debuginfo.conf
652b5bc5 340%endif
b25cb9a7 341
8db66c11 342%if 0%{?pld_archive_conf:1}
bd621c72 343%{__sed} -e 's|%%ARCH%%|%{ftp_arch}|g' < %{pld_archive_conf} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-archive.conf
8db66c11
ER
344%endif
345
7e5296f4 346# Always install snapshot configs
bd621c72 347%{__sed} -e 's|%%ARCH%%|%{ftp_arch}|g' \
a584c5c5 348 -e 's|%%SNAP%%|%{SNAP}|g' < %{SOURCE100} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}.conf
bd621c72 349%{__sed} -e 's|%%ARCH%%|%{ftp_arch}|g' \
a584c5c5 350 -e 's|%%SNAP%%|%{SNAP}|g' < %{SOURCE102} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}-debuginfo.conf
fabc4b40 351%ifarch %{x8664} x32
bd621c72
ER
352 %{__sed} -e 's|%%ARCH%%|%{ftp_alt_arch}|g' \
353 -e 's|%%SNAP%%|%{SNAP}|g' < %{SOURCE101} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}-%{ftp_alt_arch}.conf
354 %{__sed} -e 's|%%ARCH%%|%{ftp_alt2_arch}|g' \
355 -e 's|%%SNAP%%|%{SNAP}|g' < %{SOURCE101} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}-%{ftp_alt2_arch}.conf
a584c5c5 356%endif
7e5296f4
JR
357
358%if %{with snap}
c88cf671 359%{__sed} -i -e 's|@@SNAP@@||g' $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld.conf
7e5296f4 360%{__sed} -i '/@@SNAP@@.*/d' $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}.conf
a584c5c5 361%else
7e5296f4 362%{__sed} -i -e 's|@@SNAP@@||g' $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}.conf
c88cf671 363%{__sed} -i '/@@SNAP@@.*/d' $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld.conf
a584c5c5
JR
364%endif
365
600f8dbc
ER
366# create "all" meta repo
367%if 0%{?ftp_alt_arch:1}%{?ftp_alt2_arch:1}
368cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-all.conf
369# group source for referring th+th-multiarch sources together, i.e poldek -n th-all
370[source]
371type = group
372name = th-all
373sources = th %{?ftp_alt_arch:th-%{ftp_alt_arch}} %{?ftp_alt2_arch:th-%{ftp_alt2_arch}}
374EOF
375%endif
376
8dbabc51 377# th-2014 snap does not exist for x32 yet
bd621c72 378%if "%{ftp_arch}" == "x32"
255ca68a
ER
379rm $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}.conf
380%endif
bd621c72 381%if "%{ftp_alt2_arch}" == "x32"
255ca68a
ER
382rm $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}-x32.conf
383%endif
8dbabc51 384
27edf30a 385cp -p %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/cli.conf
b25cb9a7 386
9e6ff4ef 387%if %{with imode}
388# add desktop file and icon
389install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}}
27edf30a
ER
390cp -p %{SOURCE6} $RPM_BUILD_ROOT%{_desktopdir}/%{name}.desktop
391cp -p %{SOURCE7} $RPM_BUILD_ROOT%{_pixmapsdir}/%{name}.png
9e6ff4ef 392%endif
393
b43abde7 394# sources we don't package
5e2c5cc3 395%{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/{rh,fedora,centos}-source.conf
b25cb9a7 396# include them in %doc
c88cf671 397%{__rm} -rf configs
b25cb9a7 398cp -a conf configs
c88cf671 399%{__rm} -f configs/Makefile*
b25cb9a7 400
62e80071 401%if %{with python}
58c31de0 402%py_postclean
5e2c5cc3 403%{__rm} $RPM_BUILD_ROOT%{py_sitedir}/_poldekmod.la
62e80071 404%endif
58c31de0 405
b25cb9a7 406%find_lang %{name}
f373d903 407
b44549bf 408%clean
409rm -rf $RPM_BUILD_ROOT
410
daf0e7ce
ER
411%post
412[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
413if [ "$1" = "1" ]; then
414 # remove ignore = vserver-packages inside vserver on first install
415 {
416 while read f ctx; do
417 [ "$f" = "VxID:" -o "$f" = "s_context:" ] && break
418 done </proc/self/status
419 } 2>/dev/null
420 if [ -z "$ctx" -o "$ctx" = "0" ]; then
421 VSERVER=no
422 else
423 VSERVER=yes
424 fi
425 if [ "$VSERVER" = "yes" ]; then
426 %{__sed} -i -e '/^ignore/s/vserver-packages//' %{_sysconfdir}/%{name}/poldek.conf
427 fi
428fi
b25cb9a7 429
3896c8b1
ER
430%postun -p /sbin/postshell
431-/usr/sbin/fix-info-dir -c %{_infodir}
b25cb9a7
JB
432
433%post libs -p /sbin/ldconfig
434%postun libs -p /sbin/ldconfig
435
b43abde7
ER
436%triggerpostun -- poldek < 0.30-0.20080225.00.1
437if ! grep -q '^%%includedir repos.d' %{_sysconfdir}/%{name}/poldek.conf; then
438 %{__sed} -i -e '/^%%include source.conf/{
439 a
440 a# /etc/poldek/repos.d/*.conf
441 a%%includedir repos.d
442 }' %{_sysconfdir}/%{name}/poldek.conf
443fi
444
445%{__sed} -i -e '/%%include %%{_distro}-source.conf/d' %{_sysconfdir}/%{name}/poldek.conf
446%{__sed} -i -e '/%%include %%{_distro}-multilib-source.conf/d' %{_sysconfdir}/%{name}/poldek.conf
447
448if [ -f %{_sysconfdir}/%{name}/pld-source.conf.rpmsave ]; then
505460c5
JR
449 %{__mv} -f %{_sysconfdir}/%{name}/repos.d/pld.conf{,.rpmnew}
450 %{__mv} -v %{_sysconfdir}/%{name}/pld-source.conf.rpmsave %{_sysconfdir}/%{name}/repos.d/pld.conf
b43abde7
ER
451fi
452
453%ifarch %{x8664}
454if [ -f %{_sysconfdir}/%{name}/pld-multilib-source.conf.rpmsave ]; then
505460c5
JR
455 %{__mv} -f %{_sysconfdir}/%{name}/repos.d/pld-multilib.conf{,.rpmnew}
456 %{__mv} -v %{_sysconfdir}/%{name}/pld-multilib-source.conf.rpmsave %{_sysconfdir}/%{name}/repos.d/pld-multilib.conf
b43abde7
ER
457fi
458%endif
459
1bacc3e0
JR
460%triggerpostun -- poldek < 0.30.1-3
461if [ -f %{_sysconfdir}/%{name}/repos.d/pld-multilib.conf.rpmsave ]; then
bd621c72
ER
462 %{__mv} -f %{_sysconfdir}/%{name}/repos.d/pld-%{ftp_alt_arch}.conf{,.rpmnew}
463 %{__mv} -v %{_sysconfdir}/%{name}/repos.d/pld-multilib.conf.rpmsave %{_sysconfdir}/%{name}/repos.d/pld-%{ftp_alt_arch}.conf
1bacc3e0
JR
464fi
465if [ -f %{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}-multilib.conf.rpmsave ]; then
bd621c72
ER
466 %{__mv} -f %{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}-%{ftp_alt_arch}.conf{,.rpmnew}
467 %{__mv} -v %{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}-multilib.conf.rpmsave %{_sysconfdir}/%{name}/repos.d/pld-%{SNAP}-%{ftp_alt_arch}.conf
1bacc3e0
JR
468fi
469
c5d1808a
ER
470%triggerpostun -- %{name} < 0.30.1-8
471if [ $1 -le 1 ]; then
472 # revert change on --downgrade
1e921240 473 %{__sed} -i -re 's,^pm command = %{_libexecdir}/pm-command.sh,#&,' %{_sysconfdir}/%{name}/%{name}.conf
c5d1808a
ER
474else
475 # setup pm command
1e921240 476 %{__sed} -i -re 's,#?(pm command =).*,\1 %{_libexecdir}/pm-command.sh,' %{_sysconfdir}/%{name}/%{name}.conf
c5d1808a
ER
477fi
478
767366b0 479%files -f %{name}.lang
b44549bf 480%defattr(644,root,root,755)
a9c9446a 481%doc ChangeLog README* NEWS TODO configs
b25cb9a7 482%dir %{_sysconfdir}/%{name}
c5d1808a
ER
483%dir %{_sysconfdir}/%{name}/pre-install.d
484%{_sysconfdir}/%{name}/pre-install.d/README
485%dir %{_sysconfdir}/%{name}/post-install.d
486%{_sysconfdir}/%{name}/post-install.d/README
08335479 487%dir %{_sysconfdir}/%{name}/repos.d
168acc54 488%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/*.conf
b43abde7 489%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/repos.d/*.conf
5e2c5cc3
JB
490%attr(755,root,root) %{_bindir}/ipoldek
491%attr(755,root,root) %{_bindir}/poldek
492%attr(755,root,root) %{_bindir}/rpmvercmp
dcdcebb7 493%dir %{_libexecdir}
c5d1808a 494%attr(755,root,root) %{_libexecdir}/pm-command.sh
36b5e8a1
ER
495%attr(755,root,root) %{_libexecdir}/poldekuser-setup.sh
496%attr(755,root,root) %{_libexecdir}/vfcompr
497%attr(755,root,root) %{_libexecdir}/vfjuggle
498%attr(755,root,root) %{_libexecdir}/vfsmb
499%attr(755,root,root) %{_libexecdir}/zlib-in-rpm.sh
5e2c5cc3 500%{_mandir}/man1/%{name}*.1*
d8826405 501%lang(pl) %{_mandir}/pl/man1/%{name}*
b25cb9a7 502%{_infodir}/poldek.info*
9e6ff4ef 503%if %{with imode}
504%{_desktopdir}/%{name}.desktop
505%{_pixmapsdir}/%{name}.png
506%endif
27edf30a 507%dir /var/cache/%{name}
b25cb9a7 508
b43abde7 509%if %{without static}
b25cb9a7
JB
510%files libs
511%defattr(644,root,root,755)
d8aeff9a
MB
512%attr(755,root,root) %{_libdir}/libpoclidek.so.*.*.*
513%attr(755,root,root) %{_libdir}/libpoldek.so.*.*.*
514%attr(755,root,root) %{_libdir}/libtndb.so.*.*.*
515%attr(755,root,root) %{_libdir}/libtrurl.so.*.*.*
516%attr(755,root,root) %{_libdir}/libvfile.so.*.*.*
517%attr(755,root,root) %ghost %{_libdir}/libpoclidek.so.0
518%attr(755,root,root) %ghost %{_libdir}/libpoldek.so.2
519%attr(755,root,root) %ghost %{_libdir}/libtndb.so.0
520%attr(755,root,root) %ghost %{_libdir}/libtrurl.so.0
521%attr(755,root,root) %ghost %{_libdir}/libvfile.so.0
b25cb9a7
JB
522%endif
523
524%files devel
525%defattr(644,root,root,755)
5e2c5cc3
JB
526%if %{without static}
527%attr(755,root,root) %{_libdir}/libpoclidek.so
528%attr(755,root,root) %{_libdir}/libpoldek.so
529%attr(755,root,root) %{_libdir}/libtndb.so
530%attr(755,root,root) %{_libdir}/libtrurl.so
531%attr(755,root,root) %{_libdir}/libvfile.so
532%endif
533%{_libdir}/libpoclidek.la
534%{_libdir}/libpoldek.la
535%{_libdir}/libtndb.la
536%{_libdir}/libtrurl.la
537%{_libdir}/libvfile.la
538%{_includedir}/poldek
539%{_includedir}/tndb
540%{_includedir}/trurl
541%{_includedir}/vfile
542%{_pkgconfigdir}/tndb.pc
c9a1a81d 543%{_pkgconfigdir}/trurlib.pc
b25cb9a7
JB
544
545%files static
546%defattr(644,root,root,755)
5e2c5cc3
JB
547%{_libdir}/libtndb.a
548%{_libdir}/libtrurl.a
58c31de0
JB
549
550%if %{with python}
551%files -n python-poldek
552%defattr(644,root,root,755)
553%attr(755,root,root) %{py_sitedir}/_poldekmod.so
554%{py_sitescriptdir}/poldek.py[co]
555%{py_sitescriptdir}/poldekmod.py[co]
556%endif
This page took 0.239379 seconds and 4 git commands to generate.