]> git.pld-linux.org Git - packages/zsh.git/blob - zsh.spec
c02b716ca93476148ebe5a3d5bf19fb114fbff68
[packages/zsh.git] / zsh.spec
1 #
2 # Conditional build:
3 %bcond_without  static  # without static version
4 #
5 Summary:        Enhanced Bourne shell
6 Summary(de):    Enhanced Bourne Shell
7 Summary(es):    Shell bourne mejorada
8 Summary(fr):    Bourne shell amélioré
9 Summary(pl):    Ulepszona pow³oka Bourne'a
10 Summary(pt_BR): Shell bourne melhorada
11 Summary(ru):    ëÏÍÁÎÄÎÙÊ ÐÒÏÃÅÓÓÏÒ (shell) ÐÏÈÏÖÙÊ ÎÁ ksh, ÎÏ Ó ÕÌÕÞÛÅÎÉÑÍÉ
12 Summary(tr):    Geliþmiþ bir BASH sürümü
13 Summary(uk):    ëÏÍÁÎÄÎÉÊ ÐÒÏÃÅÓÏÒ (shell) ÓÈÏÖÉÊ ÎÁ ksh, ÁÌÅ Ú ÐÏËÒÁÝÅÎÎÑÍÉ
14 Name:           zsh
15 Version:        4.2.0
16 Release:        5
17 License:        BSD-like
18 Group:          Applications/Shells
19 URL:            http://www.zsh.org/
20 Source0:        ftp://ftp.zsh.org/pub/zsh/%{name}-%{version}.tar.bz2
21 # Source0-md5:  866bcdad8c0c4974650f5eff395a9a35
22 Source1:        %{name}.1.pl
23 Source2:        http://zsh.sunsite.dk/Guide/zshguide.pdf
24 # Source2-md5:  0d80ba1ef39052c512cfabf368f3bf20
25 Source3:        zprofile
26 Source4:        zshrc
27 Patch0:         %{name}-info.patch
28 Patch1:         %{name}-addons.patch
29 Patch2:         %{name}-paths.patch
30 Patch3:         %{name}-completions.patch
31 Patch4:         %{name}-nolibs.patch
32 BuildRequires:  autoconf
33 %{?with_static:BuildRequires:   glibc-static}
34 BuildRequires:  libcap-devel
35 BuildRequires:  ncurses-devel >= 5.1
36 %{?with_static:BuildRequires:   ncurses-static}
37 BuildRequires:  pcre-devel
38 BuildRequires:  texinfo
39 Requires(post,preun):   grep
40 Requires(preun):        fileutils
41 Obsoletes:      zsh-doc-html, zsh-doc-ps, zsh-doc-dvi
42 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43
44 %define         _bindir         /bin
45 %define         specflags_ia32   -fomit-frame-pointer 
46
47 %description
48 zsh is an enhanced version of the Bourne shell with csh additions and
49 most features of ksh, bash, and tcsh.
50
51 %description -l es
52 zsh es una versión mejorada del bourne shell con estas
53 características:
54 - muy próximo de la gramática del ksh/sh, con adiciones csh,
55 - varias características del ksh, bash y tcsh,
56 - 75 funciones empotradas, 89 opciones, 154 combinaciones de teclas,
57 - selección,
58 - funciones shell ...y mucho más.
59
60 %description -l ja
61 zsh ¥·¥§¥ë¤ÏÂÐÏÃŪ¤Ê¥í¥°¥¤¥ó¥·¥§¥ë¤È¤·¤ÆÍøÍѲÄǽ¤Ê¥³¥Þ¥ó¥É¥¤¥ó¥¿¥ê¥¿
62 ¤Ç¤¢¤ê¡¢¥·¥§¥ë¥¹¥¯¥ê¥×¥È¥³¥Þ¥ó¥É¤â½èÍý¤Ç¤­¤Þ¤¹. zsh ¤Ï ksh(the Korn
63 shell) ¤Ë»÷¤Æ¤¤¤Þ¤¹¤¬,¤«¤Ê¤ê³ÈÄ¥¤µ¤ì¤Æ¤¤¤Þ¤¹. zsh
64 ¤Ï¥³¥Þ¥ó¥É¥é¥¤¥ó¤Ç¤ÎÊÔ½¸µ¡Ç½, ÁȤ߹þ¤Þ¤ì¤¿¥¹¥Ú¥ë½¤Àµµ¡Ç½, ¥×¥í¥°¥é¥ß¥ó
65 ¥°²Äǽ¤Ê¥³¥Þ¥ó¥ÉÊä´°µ¡Ç½, (ưŪ¥í¡¼¥É¤µ¤ì¤ë)¥·¥§¥ëµ¡Ç½, ¥Ò¥¹¥È¥êµ¡¹½
66 ¤Ê¤É¤ò»ý¤Á¤Þ¤¹.
67
68 %description -l pl
69 zsh jest ulepszon± pow³ok± Bourne'a z elementami pow³oki csh. Posiada
70 wiêkszo¶æ cech ksh, bash i tcsh.
71
72 %description -l pt_BR
73 zsh é uma versão melhorada do bourne shell com essas características:
74 - muito próximo da gramática do ksh/sh, com adições csh,
75 - várias características do ksh, bash e tcsh,
76 - 75 funções embutidas, 89 opções, 154 combinações de teclas,
77 - seleção,
78 - funções shell ...e muito mais.
79
80 %description -l ru
81 zsh - ÜÔÏ ËÏÍÁÎÄÎÙÊ ÐÒÏÃÅÓÓÏÒ ÎÁÐÏÍÉÎÁÀÝÉÊ ksh (Korn shell), ÎÏ
82 ×ËÌÀÞÁÀÝÉÊ ÍÎÏÇÏ ÕÌÕÞÛÅÎÉÊ. zsh ÐÏÄÄÅÒÖÉ×ÁÅÔ ÒÅÄÁËÔÉÒÏ×ÁÎÉÅ ËÏÍÁÎÄÎÏÊ
83 ÓÔÒÏËÉ, ×ÓÔÒÏÅÎÎÕÀ ËÏÒÒÅËÃÉÀ ÎÁÐÉÓÁÎÉÑ, ÐÒÏÇÒÁÍÍÉÒÕÅÍÏÅ ÚÁ×ÅÒÛÅÎÉÅ
84 ËÏÍÁÎÄ, shell-ÆÕÎËÃÉÉ (Ó Á×ÔÏÚÁÇÒÕÚËÏÊ), ÉÓÔÏÒÉÀ ËÏÍÁÎÄ É ÍÎÏÇÏÅ
85 ÄÒÕÇÏÅ.
86
87 %description -l uk
88 zsh - ÃÅ ËÏÍÁÎÄÎÉÊ ÐÒÏÃÅÓÏÒ, ÝÏ ÎÁÇÁÄÕ¤ ksh (Korn shell), ÁÌÅ ×ËÌÀÞÁ¤
89 ÂÁÇÁÔÏ ÐÏËÒÁÝÅÎØ. zsh Ð¦ÄÔÒÉÍÕ¤ ÒÅÄÁÇÕ×ÁÎÎÑ ËÏÍÁÎÄÎÏÇÏ ÒÑÄËÁ,
90 ×ÂÕÄÏ×ÁÎÕ ËÏÒÅËæÀ ÎÁÐÉÓÁÎÎÑ, ÐÒÏÇÒÁÍÏ×ÁÎÅ ÚÁ×ÅÒÛÅÎÎÑ ËÏÍÁÎÄ,
91 shell-ÆÕÎË槠(Ú Á×ÔÏÚÁ×ÁÎÔÁÖÅÎÎÑÍ), ¦ÓÔÏÒ¦À ËÏÍÁÎÄ ÔÁ ÂÁÇÁÔÏ ¦ÎÛÏÇÏ.
92
93 %package completions
94 Summary:        Files needed for advanced TAB-completion
95 Summary(pl):    Pliki potrzebne dla zaawansowanej TAB-completion
96 Group:          Applications/Shells
97 Conflicts:      kdesdk-completions-zsh <= 3:3.2.3-2
98 Requires:       %{name} = %{version}-%{release}
99
100 %description completions
101 This package contains files needed for advanced tab completion in zsh.
102
103 %description completions -l pl
104 Ten pakiet zawiera pliki wymagane przez zsh dla zaawansowanej
105 TAB-completion.
106
107 %package static
108 Summary:        Statically linked Enhanced Bourne shell
109 Summary(pl):    Zaawansowana pow³oka Bourne'a - skonsolidowana statycznie
110 Group:          Applications/Shells
111 Requires(post,preun):   grep
112 Requires(preun):        fileutils
113 Requires:       %{name} = %{version}-%{release}
114
115 %description static
116 zsh is an enhanced version of the Bourne shell with csh additions and
117 most features of ksh, bash, and tcsh.
118
119 %description static -l pl
120 zsh jest ulepszon± pow³ok± Bourne'a z elementami pow³oki csh. Posiada
121 wiêkszo¶æ cech ksh, bash i tcsh. W tym pakiecie jest wersja
122 skonsolidowana statycznie.
123
124 %package guide
125 Summary:        A User's Guide to the Z-Shell
126 Summary(pl):    Podrêcznik U¿ytkownika Z-Shella
127 Group:          Documentation
128 URL:            http://zsh.sunsite.dk/Guide/
129
130 %description guide
131 A User's Guide to the Z-Shell.
132
133 %description guide -l pl
134 Podrêcznik U¿ytkownika Z-Shella.
135
136 %prep
137 %setup -q
138 %patch0 -p1
139 %patch1 -p1
140 %patch2 -p1
141 %patch3 -p1
142 %patch4 -p1
143
144 install %{SOURCE2} .
145
146 %build
147 cp -f /usr/share/automake/config.sub .
148 %{__autoconf}
149 CPPFLAGS="-I/usr/include/ncurses"
150
151 %if %{with static}
152 LDFLAGS="%{rpmldflags} -static"
153 %configure \
154         --disable-dynamic
155 %{__make} \
156         DLLDFLAGS=""
157 mv -f Src/zsh Src/zsh.static
158 %{__make} clean || :
159 LDFLAGS="%{rpmldflags}"
160 %endif
161
162 %configure \
163         ac_cv_have_dev_ptmx=yes \
164         --enable-maildir-support \
165         --enable-pcre \
166         --enable-cap
167 %{__make}
168
169 cd Doc
170 makeinfo zsh.texi
171
172 %install
173 rm -rf $RPM_BUILD_ROOT
174 install -d $RPM_BUILD_ROOT{%{_infodir},%{_sysconfdir},%{_bindir},%{_mandir}/pl/man1}
175
176 %{__make} install \
177         DESTDIR=$RPM_BUILD_ROOT
178
179 %{?with_static:install Src/zsh.static $RPM_BUILD_ROOT%{_bindir}}
180 install Doc/zsh.info* $RPM_BUILD_ROOT%{_infodir}
181
182 touch $RPM_BUILD_ROOT%{_sysconfdir}/{zlogin,zlogout,zshenv}
183 touch $RPM_BUILD_ROOT%{_sysconfdir}/{zlogin,zlogout,zprofile,zshenv,zshrc}.zwc
184 install %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}
185 install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}
186
187 rm -f Etc/Makefile*
188 find Functions Util StartupFiles -name .distfiles -o -name .cvsignore | xargs rm -f
189 install %{SOURCE1} $RPM_BUILD_ROOT%{_mandir}/pl/man1/zsh.1
190
191 # for kdesdk's completion
192 ln -sf %{version} $RPM_BUILD_ROOT%{_datadir}/zsh/latest
193
194 %clean
195 rm -rf $RPM_BUILD_ROOT
196
197 %post
198 umask 022
199 if [ ! -f /etc/shells ]; then
200         echo "%{_bindir}/zsh" >> /etc/shells
201 else
202         grep -q '^%{_bindir}/zsh$' /etc/shells || echo "%{_bindir}/zsh" >> /etc/shells
203 fi
204 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} > /dev/null 2>&1
205 for i in zlogin zlogout zprofile zshenv zshrc; do
206         [ -f /etc/$i ] && zsh -c "zcompile /etc/$i"
207 done
208
209 %preun
210 if [ "$1" = "0" ]; then
211         umask 022
212         grep -v '^%{_bindir}/zsh$' /etc/shells > /etc/shells.new
213         mv -f /etc/shells.new /etc/shells
214 fi
215
216 %postun
217 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} > /dev/null 2>&1
218
219 %post static
220 umask 022
221 if [ ! -f /etc/shells ]; then
222         echo "%{_bindir}/zsh.static" >> /etc/shells
223 else
224         grep -q '^%{_bindir}/zsh\.static$' /etc/shells || echo "%{_bindir}/zsh.static" >> /etc/shells
225 fi
226
227 %preun static
228 if [ "$1" = "0" ]; then
229         umask 022
230         grep -v '^%{_bindir}/zsh\.static$' /etc/shells > /etc/shells.new
231         mv -f /etc/shells.new /etc/shells
232 fi
233
234 %files
235 %defattr(644,root,root,755)
236 %doc Etc/* README LICENCE ChangeLog META-FAQ Util StartupFiles
237 %attr(755,root,root) %{_bindir}/zsh
238 %config(noreplace,missingok) %verify(not md5 size mtime) %{_sysconfdir}/*[!w]?
239 %ghost %{_sysconfdir}/*.zwc
240 %dir %{_libdir}/zsh
241 %dir %{_libdir}/zsh/%{version}
242 %dir %{_datadir}/zsh
243 %dir %{_datadir}/zsh/site-functions
244 %{_datadir}/zsh/latest
245 %dir %{_datadir}/zsh/%{version}
246 %dir %{_datadir}/zsh/%{version}/functions
247 %{_datadir}/zsh/%{version}/functions/[!_c]*
248 %{_datadir}/zsh/%{version}/functions/c[!o]*
249 %{_datadir}/zsh/%{version}/functions/co[!m]*
250 %attr(755,root,root) %{_libdir}/zsh/%{version}/*
251 %{_infodir}/zsh.info*
252 %{_mandir}/man1/zsh*.1*
253 %lang(pl) %{_mandir}/pl/man1/zsh*.1*
254
255 %files completions
256 %defattr(644,root,root,755)
257 %{_datadir}/zsh/%{version}/functions/comp*
258 %{_datadir}/zsh/%{version}/functions/_*
259
260 %files guide
261 %defattr(644,root,root,755)
262 %doc zshguide.pdf
263
264 %if %{with static}
265 %files static
266 %defattr(644,root,root,755)
267 %attr(755,root,root) %{_bindir}/zsh.static
268 %endif
This page took 0.085842 seconds and 2 git commands to generate.