]> git.pld-linux.org Git - packages/poldek.git/blob - poldek.spec
01321280da7efeb5dfab81714593019522cfb477
[packages/poldek.git] / poldek.spec
1 #
2 # Conditional build:
3 %bcond_without  imode           # don't build interactive mode
4 %bcond_without  curl            # don't link curl
5 %bcond_with     static          # don't use shared libraries
6 #
7 Summary:        RPM packages management helper tool
8 Summary(pl):    Pomocnicze narzêdzie do zarz±dzania pakietami RPM
9 Name:           poldek
10 Version:        0.18.6
11 Release:        1
12 License:        GPL v2
13 Group:          Applications/System
14 Source0:        http://team.pld.org.pl/~mis/poldek/download/%{name}-%{version}.tar.gz
15 # Source0-md5:  99d118c986e8102e11b81768499ec0bd
16 Source1:        %{name}.conf
17 Patch0:         %{name}-retr_term.patch
18 Patch1:         %{name}-simplestatic.patch
19 Patch2:         %{name}-pkgorder.patch
20 Patch3:         %{name}-sigsegv.patch
21 Patch4:         %{name}-caplookup.patch
22 Patch5:         %{name}-progress2.patch
23 URL:            http://team.pld.org.pl/~mis/poldek/
24 BuildRequires:  /usr/bin/pod2man
25 BuildRequires:  autoconf
26 BuildRequires:  automake
27 BuildRequires:  bzip2-devel
28 %{?with_static:BuildRequires:   bzip2-static}
29 %{?with_curl:BuildRequires:     curl-devel >= 7.8}
30 %{?with_curl:%{?with_static:BuildRequires:      curl-static}}
31 %{?with_static:BuildRequires:  db1-static}
32 %{?with_static:BuildRequires:  db3-static}
33 BuildRequires:  openssl-devel >= 0.9.6m
34 %{?with_static:BuildRequires:   openssl-static}
35 BuildRequires:  pcre-devel
36 %{?with_static:BuildRequires:   pcre-static}
37 BuildRequires:  popt-devel
38 %{?with_static:BuildRequires:   popt-static}
39 BuildRequires:  readline-devel
40 BuildRequires:  rpm-devel >= 4.0.2-62
41 %{?with_static:BuildRequires:   rpm-static}
42 BuildRequires:  zlib-devel
43 %{?with_static:BuildRequires:   zlib-static}
44 Requires:       rpm >= 4.0.2-62
45 Requires:       sed
46 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
47
48 %description
49 poldek is an RPM package management tool which allows you to easily
50 perform package verification, installation (including system
51 installation from scratch), upgrading, and removal.
52
53 Program can be used in batch (like apt-get from Debian's APT) or
54 interactive mode. The interactive mode puts you into a readline
55 interface with command line autocompletion and history, similar to the
56 shell mode of Perl's CPAN.
57
58 %{?with_static:This version is statically linked.}
59
60 %{!?with_imode:This version hasn't got interactive mode.}
61
62 %description -l pl
63 poldek jest narzêdziem linii poleceñ s³u¿±cym do weryfikacji,
64 instalacji (w³±czaj±c instalacjê systemu od zera), aktualizacji
65 i usuwania pakietów.
66
67 Program mo¿e byæ u¿ywany w trybie wsadowym (jak debianowy apt-get)
68 lub interaktywnym. Tryb interaktywny posiada interfejs readline
69 z dope³nianiem komend i histori±, podobny do trybu shell perlowego
70 modu³u CPAN.
71
72 %{?with_static:Ta wersja jest konsolidowana statycznie.}
73
74 %{!?with_imode:Ta wersja nie posiada trybu interaktywnego.}
75
76 %prep
77 %setup -q
78 %patch0 -p1
79 %patch1 -p0
80 %patch2 -p0
81 %patch3 -p0
82 %patch4 -p0
83 %patch5 -p1
84
85 %build
86 if ! grep -q AM_GNU_GETTEXT_VERSION configure.in ; then
87         cp configure.in configure.in.orig
88         sed -e 's/AM_GNU_GETTEXT\(.*\)/AM_GNU_GETTEXT\1\
89 AM_GNU_GETTEXT_VERSION(0.10.40)/' \
90                 -e 's=po/Makefile.in=po/Makefile.in intl/Makefile=' \
91                 configure.in.orig >configure.in
92         autopoint --force
93 fi
94 %{__aclocal} -I m4
95 %{__autoconf}
96 %{__automake}
97 %configure \
98         %{?with_static:--enable-static} \
99         %{!?with_imode:--disable-imode} \
100         %{?with_curl:--with-curl}
101 %{__make}
102
103 %install
104 rm -rf $RPM_BUILD_ROOT
105 install -d $RPM_BUILD_ROOT%{_sysconfdir}
106
107 # no strip cause program's beta stage and core may be useful
108 %{__make} install \
109         DESTDIR=$RPM_BUILD_ROOT
110
111 %{?with_static:rm -f $RPM_BUILD_ROOT/%{_bindir}/rpmvercmp}
112 sed "s|/i686/|/%{_target_cpu}/|g" < %{SOURCE1} > $RPM_BUILD_ROOT/etc/%{name}.conf
113
114 %find_lang %{name}
115
116 %clean
117 rm -rf $RPM_BUILD_ROOT
118
119 %triggerpostun -- poldek <= 0.18.3-1
120 if ! grep -q promoteepoch /etc/poldek.conf ; then
121         echo promoteepoch = yes >>/etc/poldek.conf
122 fi
123
124 %files -f %{name}.lang
125 %defattr(644,root,root,755)
126 %doc README* NEWS TODO *sample* conf/poldekrc*
127 %attr(644,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/%{name}.conf
128 %attr(755,root,root) %{_bindir}/*
129 %{_mandir}/man1/%{name}*
130 %lang(pl) %{_mandir}/pl/man1/%{name}*
This page took 0.042533 seconds and 2 git commands to generate.