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