]>
Commit | Line | Data |
---|---|---|
7bbfdb65 | 1 | # |
7088e905 | 2 | # Conditional build: |
7bbfdb65 | 3 | %bcond_with static # build static version |
e5e40e2e | 4 | %bcond_without tests # don't perform "make test" |
7088e905 | 5 | # |
a4d50a64 | 6 | Summary: Enhanced Bourne shell |
bf98a40a ER |
7 | Summary(de.UTF-8): Enhanced Bourne Shell |
8 | Summary(es.UTF-8): Shell bourne mejorada | |
9 | Summary(fr.UTF-8): Bourne shell amélioré | |
b7786c06 | 10 | Summary(hu.UTF-8): Kiterjesztett Bourne Shell |
bf98a40a ER |
11 | Summary(pl.UTF-8): Ulepszona powłoka Bourne'a |
12 | Summary(pt_BR.UTF-8): Shell bourne melhorada | |
13 | Summary(ru.UTF-8): Командный процессор (shell) похожый на ksh, но с улучшениями | |
14 | Summary(tr.UTF-8): Gelişmiş bir BASH sürümü | |
15 | Summary(uk.UTF-8): Командний процесор (shell) схожий на ksh, але з покращеннями | |
83278afd | 16 | Name: zsh |
69754942 | 17 | Version: 5.4.2 |
51633cb1 | 18 | Release: 1 |
2d083759 | 19 | License: BSD-like |
651a9c1a | 20 | Group: Applications/Shells |
51633cb1 | 21 | Source0: ftp://sunsite.icm.edu.pl/pub/unix/shells/zsh/%{name}-%{version}.tar.xz |
69754942 | 22 | # Source0-md5: dfe156fd69b0d8d1745ecf6d6e02e047 |
6afe72d1 | 23 | #Source0: ftp://ftp.zsh.org/pub/%{name}-%{version}.tar.bz2 |
1a356495 | 24 | Source1: %{name}.1.pl |
5866c474 | 25 | Source2: http://zsh.sunsite.dk/Guide/%{name}guide.pdf |
6afe72d1 | 26 | # Source2-md5: 70cc3760dd8140f9aed693d484cd87dc |
e8d1aafb | 27 | Source3: zprofile |
5866c474 | 28 | Source4: %{name}rc |
eace1f82 | 29 | Patch1: %{name}-addons.patch |
30 | Patch2: %{name}-paths.patch | |
31 | Patch3: %{name}-completions.patch | |
7ca723e2 | 32 | Patch4: %{name}-nolibs.patch |
c9a36266 | 33 | URL: http://www.zsh.org/ |
7bbfdb65 | 34 | BuildRequires: autoconf >= 2.60 |
48b96dd9 | 35 | BuildRequires: automake |
7bbfdb65 | 36 | BuildRequires: gdbm-devel |
cfd57568 | 37 | %{?with_static:BuildRequires: glibc-static} |
6c76e97a | 38 | BuildRequires: libcap-devel |
b076b3fc | 39 | BuildRequires: ncurses-devel >= 5.1 |
cfd57568 | 40 | %{?with_static:BuildRequires: ncurses-static} |
6c76e97a | 41 | BuildRequires: pcre-devel |
2a00a59c | 42 | BuildRequires: rpmbuild(macros) >= 1.470 |
b076b3fc | 43 | BuildRequires: texinfo |
48b96dd9 | 44 | BuildRequires: yodl |
3fa5f78f | 45 | Requires(post,preun): grep |
b076b3fc | 46 | Requires(preun): fileutils |
9046f083 | 47 | Requires: findutils |
de0cb3a3 | 48 | Obsoletes: zsh-doc-dvi |
5866c474 ER |
49 | Obsoletes: zsh-doc-html |
50 | Obsoletes: zsh-doc-ps | |
a6765b50 | 51 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
83278afd | 52 | |
587f5454 | 53 | %define _bindir /bin |
de0cb3a3 | 54 | %define specflags_ia32 -fomit-frame-pointer |
83278afd | 55 | |
56 | %description | |
c1897f93 | 57 | zsh is an enhanced version of the Bourne shell with csh additions and |
58 | most features of ksh, bash, and tcsh. | |
83278afd | 59 | |
b00e8d51 JR |
60 | %description -l es.UTF-8 |
61 | zsh es una versión mejorada del bourne shell con estas | |
62 | características: | |
63 | - muy próximo de la gramática del ksh/sh, con adiciones csh, | |
64 | - varias características del ksh, bash y tcsh, | |
cbb441dc | 65 | - 75 funciones empotradas, 89 opciones, 154 combinaciones de teclas, |
b00e8d51 JR |
66 | - selección, |
67 | - funciones shell ...y mucho más. | |
68 | ||
69 | %description -l ja.UTF-8 | |
70 | zsh シェルは対話的なログインシェルとして利用可能なコマンドインタリタ | |
71 | であり、シェルスクリプトコマンドも処理できます. zsh は ksh(the Korn | |
72 | shell) に似ていますが,かなり拡張されています. zsh | |
73 | はコマンドラインでの編集機能, 組み込まれたスペル修正機能, プログラミン | |
74 | グ可能なコマンド補完機能, (動的ロードされる)シェル機能, ヒストリ機構 | |
75 | などを持ちます. | |
76 | ||
51633cb1 | 77 | %description -l hu.UTF-8 |
b7786c06 ZU |
78 | zsh a Bourne shell egy kiterjesztett verziója csh kiegészítésekkel és |
79 | a ksh, bash és csh legtöbb lehetőségével felvértezve. | |
80 | ||
b00e8d51 JR |
81 | %description -l pl.UTF-8 |
82 | zsh jest ulepszoną powłoką Bourne'a z elementami powłoki csh. Posiada | |
83 | większość cech ksh, bash i tcsh. | |
84 | ||
85 | %description -l pt_BR.UTF-8 | |
86 | zsh é uma versão melhorada do bourne shell com essas características: | |
87 | - muito próximo da gramática do ksh/sh, com adições csh, | |
88 | - várias características do ksh, bash e tcsh, | |
89 | - 75 funções embutidas, 89 opções, 154 combinações de teclas, | |
90 | - seleção, | |
91 | - funções shell ...e muito mais. | |
92 | ||
93 | %description -l ru.UTF-8 | |
94 | zsh - это командный процессор напоминающий ksh (Korn shell), но | |
95 | включающий много улучшений. zsh поддерживает редактирование командной | |
96 | строки, встроенную коррекцию написания, программируемое завершение | |
97 | команд, shell-функции (с автозагрузкой), историю команд и многое | |
98 | другое. | |
99 | ||
100 | %description -l uk.UTF-8 | |
101 | zsh - це командний процесор, що нагадує ksh (Korn shell), але включає | |
102 | багато покращень. zsh підтримує редагування командного рядка, | |
103 | вбудовану корекцію написання, програмоване завершення команд, | |
104 | shell-функції (з автозавантаженням), історію команд та багато іншого. | |
d2f588c7 | 105 | |
b015e9ee | 106 | %package completions |
cbb441dc | 107 | Summary: Files needed for advanced TAB-completion |
b7786c06 | 108 | Summary(hu.UTF-8): A haladó TAB-kiegészítéshez szükséges fájlok |
bf98a40a | 109 | Summary(pl.UTF-8): Pliki potrzebne dla zaawansowanej TAB-completion |
cbb441dc | 110 | Group: Applications/Shells |
7ca723e2 | 111 | Requires: %{name} = %{version}-%{release} |
de0cb3a3 | 112 | Conflicts: kdesdk-completions-zsh <= 3:3.2.3-2 |
b015e9ee | 113 | |
114 | %description completions | |
115 | This package contains files needed for advanced tab completion in zsh. | |
116 | ||
b7786c06 ZU |
117 | %description completions -l hu.UTF-8 |
118 | Ez a csomag tartalmazza a haladó TAB-kiegészítéshez szükséges fájlokat | |
119 | a zsh shell-hez. | |
120 | ||
b00e8d51 | 121 | %description completions -l pl.UTF-8 |
b015e9ee | 122 | Ten pakiet zawiera pliki wymagane przez zsh dla zaawansowanej |
123 | TAB-completion. | |
124 | ||
7088e905 | 125 | %package static |
a4d50a64 | 126 | Summary: Statically linked Enhanced Bourne shell |
b7786c06 | 127 | Summary(hu.UTF-8): A zsh statikus verziója |
bf98a40a | 128 | Summary(pl.UTF-8): Zaawansowana powłoka Bourne'a - skonsolidowana statycznie |
cbb441dc | 129 | Group: Applications/Shells |
3fa5f78f | 130 | Requires(post,preun): grep |
b076b3fc | 131 | Requires(preun): fileutils |
7ca723e2 | 132 | Requires: %{name} = %{version}-%{release} |
7088e905 | 133 | |
134 | %description static | |
135 | zsh is an enhanced version of the Bourne shell with csh additions and | |
136 | most features of ksh, bash, and tcsh. | |
137 | ||
b7786c06 ZU |
138 | %description static -l hu.UTF-8 |
139 | A zsh statikus verziója. | |
140 | ||
b00e8d51 JR |
141 | %description static -l pl.UTF-8 |
142 | zsh jest ulepszoną powłoką Bourne'a z elementami powłoki csh. Posiada | |
143 | większość cech ksh, bash i tcsh. W tym pakiecie jest wersja | |
a4d50a64 | 144 | skonsolidowana statycznie. |
7088e905 | 145 | |
4f664908 | 146 | %package guide |
147 | Summary: A User's Guide to the Z-Shell | |
b7786c06 | 148 | Summary(hu.UTF-8): Felhasználói útmutató a Z-Shell-hez |
bf98a40a | 149 | Summary(pl.UTF-8): Podręcznik Użytkownika Z-Shella |
51052d96 | 150 | Group: Documentation |
4f664908 | 151 | URL: http://zsh.sunsite.dk/Guide/ |
152 | ||
153 | %description guide | |
154 | A User's Guide to the Z-Shell. | |
155 | ||
b7786c06 ZU |
156 | %description guide -l hu.UTF-8 |
157 | Felhasználói útmutató a Z-Shell-hez. | |
158 | ||
b00e8d51 JR |
159 | %description guide -l pl.UTF-8 |
160 | Podręcznik Użytkownika Z-Shella. | |
4f664908 | 161 | |
83278afd | 162 | %prep |
95b4ac0b | 163 | %setup -q |
cc534ac5 | 164 | %patch1 -p1 |
e317d501 | 165 | %patch2 -p1 |
166 | %patch3 -p1 | |
7ca723e2 | 167 | %patch4 -p1 |
83278afd | 168 | |
4f664908 | 169 | install %{SOURCE2} . |
170 | ||
ad7f7390 | 171 | find Functions -type f -exec %{__sed} -i -e 's|#!.*/zsh|#!/bin/zsh|g' "{}" ";" |
42093e13 | 172 | |
83278afd | 173 | %build |
226d6ebd | 174 | cp -f /usr/share/automake/config.sub . |
c83d9cb8 | 175 | %{__autoconf} |
48b96dd9 AM |
176 | %{__autoheader} |
177 | echo > stamp-h.in | |
c9a36266 | 178 | CPPFLAGS="%{rpmcppflags} -I/usr/include/ncurses" |
cc534ac5 | 179 | |
cfd57568 | 180 | %if %{with static} |
7088e905 | 181 | LDFLAGS="%{rpmldflags} -static" |
424f1ac6 | 182 | %configure \ |
48b96dd9 AM |
183 | --enable-maildir-support \ |
184 | --enable-multibyte \ | |
185 | --with-tcsetpgrp \ | |
424f1ac6 AM |
186 | --disable-dynamic |
187 | %{__make} \ | |
188 | DLLDFLAGS="" | |
7088e905 | 189 | mv -f Src/zsh Src/zsh.static |
424f1ac6 | 190 | %{__make} clean || : |
7088e905 | 191 | LDFLAGS="%{rpmldflags}" |
192 | %endif | |
193 | ||
3790abdd | 194 | %configure \ |
17f690bb | 195 | ac_cv_have_dev_ptmx=yes \ |
fec100a6 | 196 | --enable-maildir-support \ |
48b96dd9 | 197 | --enable-cap \ |
fec100a6 | 198 | --enable-pcre \ |
48b96dd9 | 199 | --enable-multibyte \ |
48b96dd9 | 200 | --with-tcsetpgrp |
ecc52887 | 201 | %{__make} |
83278afd | 202 | |
b076b3fc JB |
203 | cd Doc |
204 | makeinfo zsh.texi | |
9c4b843a AM |
205 | cd .. |
206 | ||
eb0ecde0 AM |
207 | %if %{with tests} |
208 | if ! tty; then | |
73497b56 | 209 | rm Test/{C02cond.ztst,Y01completion.ztst,Y02compmatch.ztst,Y03arguments.ztst} |
eb0ecde0 AM |
210 | fi |
211 | %{__make} test | |
212 | %endif | |
3790abdd | 213 | |
83278afd | 214 | %install |
215 | rm -rf $RPM_BUILD_ROOT | |
1a356495 | 216 | install -d $RPM_BUILD_ROOT{%{_infodir},%{_sysconfdir},%{_bindir},%{_mandir}/pl/man1} |
3790abdd | 217 | |
1256c9e6 JB |
218 | %{__make} install \ |
219 | DESTDIR=$RPM_BUILD_ROOT | |
cc534ac5 | 220 | |
cfd57568 | 221 | %{?with_static:install Src/zsh.static $RPM_BUILD_ROOT%{_bindir}} |
e8d1aafb TP |
222 | install Doc/zsh.info* $RPM_BUILD_ROOT%{_infodir} |
223 | ||
51b8d4e0 | 224 | touch $RPM_BUILD_ROOT%{_sysconfdir}/{zlogin,zlogout,zshenv} |
9fc47db4 | 225 | touch $RPM_BUILD_ROOT%{_sysconfdir}/{zlogin,zlogout,zprofile,zshenv,zshrc}.zwc |
e8d1aafb TP |
226 | install %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir} |
227 | install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir} | |
45772ef5 | 228 | |
51633cb1 | 229 | %{__rm} -f Etc/Makefile* |
45772ef5 | 230 | find Functions Util StartupFiles -name .distfiles -o -name .cvsignore | xargs rm -f |
1a356495 | 231 | install %{SOURCE1} $RPM_BUILD_ROOT%{_mandir}/pl/man1/zsh.1 |
232 | ||
c13dab96 JB |
233 | # for kdesdk's completion |
234 | ln -sf %{version} $RPM_BUILD_ROOT%{_datadir}/zsh/latest | |
235 | ||
236 | %clean | |
237 | rm -rf $RPM_BUILD_ROOT | |
238 | ||
83278afd | 239 | %post |
b076b3fc | 240 | umask 022 |
9b9ba60d | 241 | [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} > /dev/null 2>&1 |
83278afd | 242 | if [ ! -f /etc/shells ]; then |
062f7fe9 | 243 | echo "%{_bindir}/zsh" >> /etc/shells |
83278afd | 244 | else |
062f7fe9 | 245 | grep -q '^%{_bindir}/zsh$' /etc/shells || echo "%{_bindir}/zsh" >> /etc/shells |
83278afd | 246 | fi |
51b8d4e0 TP |
247 | for i in zlogin zlogout zprofile zshenv zshrc; do |
248 | [ -f /etc/$i ] && zsh -c "zcompile /etc/$i" | |
249 | done | |
8ef9a897 | 250 | |
6229d098 | 251 | %preun |
cc534ac5 | 252 | if [ "$1" = "0" ]; then |
b076b3fc | 253 | umask 022 |
062f7fe9 | 254 | grep -v '^%{_bindir}/zsh$' /etc/shells > /etc/shells.new |
651a9c1a | 255 | mv -f /etc/shells.new /etc/shells |
83278afd | 256 | fi |
062f7fe9 | 257 | |
9b9ba60d ER |
258 | %postun -p /sbin/postshell |
259 | -/usr/sbin/fix-info-dir -c %{_infodir} | |
e317d501 | 260 | |
7088e905 | 261 | %post static |
b076b3fc | 262 | umask 022 |
7088e905 | 263 | if [ ! -f /etc/shells ]; then |
3fa5f78f | 264 | echo "%{_bindir}/zsh.static" >> /etc/shells |
7088e905 | 265 | else |
3fa5f78f | 266 | grep -q '^%{_bindir}/zsh\.static$' /etc/shells || echo "%{_bindir}/zsh.static" >> /etc/shells |
7088e905 | 267 | fi |
268 | ||
269 | %preun static | |
270 | if [ "$1" = "0" ]; then | |
b076b3fc | 271 | umask 022 |
3fa5f78f TP |
272 | grep -v '^%{_bindir}/zsh\.static$' /etc/shells > /etc/shells.new |
273 | mv -f /etc/shells.new /etc/shells | |
7088e905 | 274 | fi |
275 | ||
83278afd | 276 | %files |
277 | %defattr(644,root,root,755) | |
51633cb1 | 278 | %doc Etc/* ChangeLog FEATURES LICENCE META-FAQ README Misc StartupFiles Util |
0ef667b6 | 279 | %attr(755,root,root) %{_bindir}/zsh |
e23746f9 | 280 | %config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/*[!w]? |
51633cb1 | 281 | %ghost %{_sysconfdir}/z*.zwc |
c13dab96 | 282 | %dir %{_datadir}/zsh |
48b96dd9 | 283 | %dir %{_datadir}/zsh/%{version}* |
48b96dd9 AM |
284 | %dir %{_datadir}/zsh/%{version}*/functions |
285 | %{_datadir}/zsh/%{version}*/functions/[!_c]* | |
286 | %{_datadir}/zsh/%{version}*/functions/c[!o]* | |
287 | %{_datadir}/zsh/%{version}*/functions/co[!m]* | |
51633cb1 TP |
288 | %{_datadir}/zsh/%{version}*/help |
289 | %{_datadir}/zsh/%{version}*/scripts | |
290 | %{_datadir}/zsh/latest | |
291 | %{_datadir}/zsh/site-functions | |
292 | %dir %{_libdir}/zsh | |
293 | %dir %{_libdir}/zsh/%{version}* | |
48b96dd9 | 294 | %attr(755,root,root) %{_libdir}/zsh/%{version}*/* |
4a8cc3b6 | 295 | %{_infodir}/zsh.info* |
296 | %{_mandir}/man1/zsh*.1* | |
1a356495 | 297 | %lang(pl) %{_mandir}/pl/man1/zsh*.1* |
b015e9ee | 298 | |
299 | %files completions | |
300 | %defattr(644,root,root,755) | |
48b96dd9 AM |
301 | %{_datadir}/zsh/%{version}*/functions/comp* |
302 | %{_datadir}/zsh/%{version}*/functions/_* | |
7088e905 | 303 | |
4f664908 | 304 | %files guide |
305 | %defattr(644,root,root,755) | |
306 | %doc zshguide.pdf | |
307 | ||
cfd57568 | 308 | %if %{with static} |
7088e905 | 309 | %files static |
cbb441dc | 310 | %defattr(644,root,root,755) |
7088e905 | 311 | %attr(755,root,root) %{_bindir}/zsh.static |
312 | %endif |