X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=poldek.spec;h=4a8e72aaa3f7844eb686f0cce6a7b00d7cd51bb1;hb=5c982c28a3a4cd5d5bef1f5f85b4627905ef817d;hp=51e2a125900221dddd5e52d064537245a6987a17;hpb=63bd61a7ae20f4f8f8af33e14893b75198ca7d42;p=packages%2Fpoldek.git diff --git a/poldek.spec b/poldek.spec index 51e2a12..4a8e72a 100644 --- a/poldek.spec +++ b/poldek.spec @@ -5,22 +5,25 @@ %bcond_with curl # link with curl # # required versions (forced to avoid SEGV with mixed db used by rpm and poldek) -%define ver_db 4.2.50-1 -%define ver_rpm 4.3-0.20030610.29 +%define ver_db 4.3.27-1 +%define ver_rpm 4.3-0.20040107.34 Summary: RPM packages management helper tool Summary(pl): Pomocnicze narzêdzie do zarz±dzania pakietami RPM Name: poldek -Version: 0.18.3 -Release: 2 +Version: 0.18.8 +Release: 9 License: GPL v2 Group: Applications/System -Source0: http://team.pld.org.pl/~mis/poldek/download/%{name}-%{version}.tar.gz -# Source0-md5: 339c54b86bfd733851c0f7125057f446 +Source0: http://team.pld.org.pl/~mis/poldek/download/%{name}-%{version}.tar.bz2 +# Source0-md5: f7e2978c7f8b35b0b07d0278dd299881 Source1: %{name}.conf -Patch1: %{name}-etc_dir.patch -Patch2: %{name}-retr_term.patch -Patch3: %{name}-ldb4.patch -Patch4: %{name}-be-nice-for-proxy.patch +Patch0: %{name}-etc_dir.patch +Patch1: %{name}-retr_term.patch +Patch2: %{name}-simplestatic.patch +Patch3: %{name}-gcc4.patch +Patch4: %{name}-cookie.patch +Patch5: %{name}-rpmcmd.patch +Patch6: %{name}-fmtime.patch URL: http://team.pld.org.pl/~mis/poldek/ BuildRequires: automake BuildRequires: autoconf @@ -28,7 +31,7 @@ BuildRequires: bzip2-devel %{?with_curl:BuildRequires: curl-devel >= 7.8} BuildRequires: db-devel >= %{ver_db} BuildRequires: gettext-autopoint -BuildRequires: openssl-devel >= 0.9.7c +BuildRequires: openssl-devel >= 0.9.7d BuildRequires: pcre-devel BuildRequires: popt-devel BuildRequires: readline-devel @@ -39,6 +42,8 @@ BuildRequires: perl-tools-pod BuildRequires: bzip2-static %{?with_curl:BuildRequires: curl-static} BuildRequires: db-static >= %{ver_db} +BuildRequires: glibc-static +BuildRequires: libselinux-static BuildRequires: ncurses-static BuildRequires: openssl-static BuildRequires: pcre-static @@ -46,9 +51,9 @@ BuildRequires: popt-static BuildRequires: readline-static BuildRequires: rpm-static BuildRequires: zlib-static -BuildRequires: glibc-static %endif Requires: db >= %{ver_db} +Requires: ed Requires: rpm >= %{ver_rpm} Requires: sed Requires: openssl >= 0.9.7c @@ -84,13 +89,19 @@ modu %prep %setup -q +%patch0 -p1 %patch1 -p1 -%patch2 -p1 +%patch2 -p0 +%patch3 -p1 +%patch4 -p1 +%patch5 -p1 +%patch6 -p0 %build %{__autopoint} %{__aclocal} -I m4 %{__autoconf} +%{__autoheader} %{__automake} cp -f config.sub trurlib %configure \ @@ -107,17 +118,49 @@ install -d $RPM_BUILD_ROOT%{_sysconfdir} DESTDIR=$RPM_BUILD_ROOT %{?with_static:rm -f $RPM_BUILD_ROOT%{_bindir}/rpmvercmp} -sed "s|/i686/|/%{_target_cpu}/|g" < %{SOURCE1} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}.conf + +# +# CHANGE IT WHEN SWITCHING poldek.conf FROM AC TO TH !!! +# +%ifarch i386 i586 i686 ppc sparc alpha amd64 athlon +%define _ftp_arch %{_target_cpu} +%else +%ifarch i486 +%define _ftp_arch i386 +%else +%ifarch pentium2 pentium3 pentium4 +%define _ftp_arch i686 +%else +%ifarch sparcv9 sparc64 +%define _ftp_arch sparc +%endif +%endif +%endif +%endif + +sed "s|%%ARCH%%|%{_ftp_arch}|g" < %{SOURCE1} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}.conf %find_lang %{name} %clean rm -rf $RPM_BUILD_ROOT +%triggerpostun -- poldek <= 0.18.3-5 +if grep -q '^promoteepoch.*yes' %{_sysconfdir}/poldek.conf ; then + echo -e ',s:^promoteepoch:# promoteepoch:g\n,w' | ed -s %{_sysconfdir}/poldek.conf +fi + +# otherwise don't touch +%ifarch i386 i586 i686 ppc sparc alpha amd64 athlon +%triggerpostun -- poldek <= 0.18.7-1 +echo -e ',s://ftp.pld-linux.org://ftp.%{_target_cpu}.ac.pld-linux.org:g\n,w' |\ + ed -s /etc/poldek.conf ||: +%endif + %files -f %{name}.lang %defattr(644,root,root,755) %doc README* NEWS TODO *sample* conf/poldekrc* -%attr(644,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/%{name}.conf +%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.conf %attr(755,root,root) %{_bindir}/* %{_mandir}/man1/%{name}* %lang(pl) %{_mandir}/pl/man1/%{name}*