3 # --with dietlibc (link with dietlibc, implies --without static)
6 %{?_with_dietlibc:%define _without_static 1}
8 Summary: Small bourne shell from Berkeley
9 Summary(de): Kleine Bourne-Shell von Berkeley
10 Summary(es): Pequeña shell bourne de Berkeley
11 Summary(fr): Shell Bourne réduit de Berkeley
12 Summary(pl): Ma³y shell bourne'a
13 Summary(pt_BR): Pequena shell bourne de Berkeley
14 Summary(ru): ïÂÌÅÇÞÅÎÎÁÑ ×ÅÒÓÉÑ Bourne shell (sh)
15 Summary(tr): Ufak bir bourne kabuðu
16 Summary(uk): ðÏÌÅÇÛÅÎÁ ×ÅÒÓ¦Ñ Bourne shell (sh)
17 Summary(zh_CN): [ϵͳ]BerkeleyµÄ΢ÐÍBourne Shell
18 Summary(zh_TW): [
\e-A¨t
\e$)B²Î]Berkeleyªº
\e-A·L
\e$)B«¬Bourne Shell
23 Group: Applications/Shells
24 Source0: %{name}-%{version}.tar.gz
25 Patch0: %{name}-builtin.patch
26 Patch1: %{name}-echo.patch
27 Patch2: %{name}-getcwd.patch
28 Patch3: %{name}-getopt.patch
29 Patch4: %{name}-glob.patch
30 Patch5: %{name}-jobs.patch
31 Patch6: %{name}-kill.patch
32 Patch7: %{name}-makefile.patch
33 Patch8: %{name}-manpage.patch
34 Patch9: %{name}-hetio.patch
35 Patch10: %{name}-memout.patch
36 Patch11: %{name}-misc.patch
37 Patch12: %{name}-redir.patch
38 Patch13: %{name}-setmode.patch
39 Patch14: %{name}-syntax.patch
40 Patch15: %{name}-test.patch
41 Patch16: %{name}-times.patch
42 Patch17: %{name}-debian.patch
43 Patch18: %{name}-ppid.patch
44 Patch19: %{name}-freebsd.patch
45 Patch20: %{name}-sighup.patch
46 Patch21: %{name}-dietlibc.patch
47 %{!?_without_static:BuildRequires: glibc-static}
48 %{?_with_dietlibc:BuildRequires: dietlibc-static}
51 Requires(post,preun,verify): grep
52 Requires(preun): fileutils
53 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
54 Conflicts: mkinitrd <= 1.7
59 ash is a bourne shell clone from Berkeley. It supports all of the
60 standard Bourne shell commands and has the advantage of supporting
61 them while remaining considerably smaller than bash.
64 ash ist ein Bourne-Shell-Clone aus Berkeley, der alle
65 Standard-Bourne-Shell- Befehle unterstützt und dennoch erheblich
66 weniger Platz beansprucht als bash.
69 ash es un clone del shell bourne de Berkeley. Soporta todos los
70 comandos padrón de la Bourne shell y tiene la ventaja de soportarlos
71 con un tamaño considerablemente menor del que bash.
74 ash est un clone Berkeley du shell Bourne. Il gère toutes les
75 commandes standard du shell Bourne et a l'avantage de les gérer tout
76 en restant considérablement plus petit que bash.
79 Ash jest klonem shella Bourne'a z Berkeley. Obs³uguje standardowe
80 komendy shella Bourne'a i jest mniejszy ni¿ bash.
83 ash é um clone do shell bourne de Berkeley. Ele suporta todos os
84 comandos-padrão da Bourne shell e tem a vantagem de suportá-los com um
85 tamanho consideravelmente menor do que bash.
88 ûÅÌÌ - ÜÔÏ ÂÁÚÏ×ÁÑ ÓÉÓÔÅÍÎÁÑ ÐÒÏÇÒÁÍÍÁ, ËÏÔÏÒÁÑ ÉÎÔÅÒÐÒÅÔÉÒÕÅÔ ËÏÍÁÎÄÙ
89 ÐÏÌØÚÏ×ÁÔÅÌÑ, ××ÏÄÉÍÙÅ Ó ËÌÁ×ÉÁÔÕÒÙ ÉÌÉ ÐÒÉ ÐÏÍÏÝÉ ÍÙÛÉ. Ash - ÜÔÏ
90 ËÌÏÎ Bourne shell (sh) ÉÚ âÅÒËÌÉ. Ash ÐÏÄÄÅÒÖÉ×ÁÅÔ ×ÓÅ ÓÔÁÎÄÁÒÔÎÙÅ
91 ËÏÍÁÎÄÙ ÛÅÌÌÁ sh, ÂÕÄÕÞÉ ÚÎÁÞÉÔÅÌØÎÏ ÍÅÎØÛÅ ÞÅÍ sh. ÷ ash ÏÔÓÕÔÓÔ×ÕÀÔ
92 ÎÅËÏÔÏÒÙÅ ×ÏÚÍÏÖÎÏÓÔÉ Bourne shell (ÎÁÐÒÉÍÅÒ, ÉÓÔÏÒÉÑ ËÏÍÁÎÄ), ÎÏ ÏÎ
93 ÔÒÅÂÕÅÔ ÚÎÁÞÉÔÅÌØÎÏ ÍÅÎØÛÅ ÐÁÍÑÔÉ.
96 ash, Berkeley'in bir bourne kabuðu kopyasýdýr. Standart bourne kabuðu
97 komutlarýnýn tümünü destekler ve bash kabuðundan daha küçük olma
101 ûÅÌ - ÃÅ ÂÁÚÏ×Á ÓÉÓÔÅÍÎÁ ÐÒÏÇÒÁÍÁ, ËÏÔÒÁ ¦ÎÔÅÒÐÒÅÔÕ¤ ËÏÍÁÎÄÉ
102 ËÏÒÉÓÔÕ×ÁÞÁ, Ñ˦ ××ÏÄÑÔØÓÑ Ú ËÌÁצÁÔÕÒÉ ÁÂÏ ÚÁ ÄÏÐÏÍÏÇÏÀ ÍÉÛ¦. Ash -
103 ÃÅ ËÌÏÎ Bourne shell (sh) Ú âÅÒË̦. Ash ЦÄÔÒÉÍÕ¤ ÕÓ¦ ÓÔÁÎÄÁÒÔΦ
104 ËÏÍÁÎÄÉ ÛÅÌÁ sh, ÂÕÄÕÞÉ ÚÎÁÞÎÏ ÍÅÎÛÉÍ Î¦Ö sh. ÷ ash צÄÓÕÔΦ ÄÅÑ˦
105 ÍÏÖÌÉ×ÏÓÔ¦ Bourne shell (ÎÁÐÒÉËÌÁÄ, ¦ÓÔÏÒ¦Ñ ËÏÍÁÎÄ), ÚÁÔŠצΠ×ÉÍÁÇÁ¤
106 ÚÎÁÞÎÏ ÍÅÎÛÅ ÐÁÍ'ÑÔ¦.
109 Summary: Small bourne shell from Berkeley
110 Summary(de): Kleine Bourne-Shell von Berkeley
111 Summary(fr): Shell Bourne réduit de Berkeley
112 Summary(pl): Ma³y shell bourne'a
113 Summary(tr): Ufak bir bourne kabuðu
114 Group: Applications/Shells
115 Requires(post,preun,verify): grep
116 Requires(preun): fileutils
117 Conflicts: mkinitrd <= 1.7
120 ash is a bourne shell clone from Berkeley. It supports all of the
121 standard Bourne shell commands and has the advantage of supporting
122 them while remaining considerably smaller than bash.
124 %description static -l de
125 ash ist ein Bourne-Shell-Clone aus Berkeley, der alle
126 Standard-Bourne-Shell- Befehle unterstützt und dennoch erheblich
127 weniger Platz beansprucht als bash.
129 %description static -l fr
130 ash est un clone Berkeley du shell Bourne. Il gère toutes les
131 commandes standard du shell Bourne et a l'avantage de les gérer tout
132 en restant considérablement plus petit que bash.
134 %description static -l pl
135 Ash jest klonem shella Bourne'a z Berkeley. Obs³uguje standardowe
136 komendy shella Bourne'a i jest mniejszy ni¿ bash.
138 %description static -l tr
139 ash, Berkeley'in bir bourne kabuðu kopyasýdýr. Standart bourne kabuðu
140 komutlarýnýn tümünü destekler ve bash kabuðundan daha küçük olma
162 # this is mainly for information, maybe add changelog to %doc?
167 %{?_with_dietlibc:%patch21 -p1}
171 %{?_with_dietlibc:%define __cc %{_arch}-dietlibc-gcc}
173 %{!?_without_static:%{__make} OPT_FLAGS="%{rpmcflags}" LDFLAGS="-static %{rpmldflags}"}
174 %{!?_without_static:mv -f sh ash.static}
175 %{__make} OPT_FLAGS="%{rpmcflags}" LDFLAGS="%{rpmldflags}" CC="%{__cc}"
178 rm -rf $RPM_BUILD_ROOT
180 install -d $RPM_BUILD_ROOT/{%{_bindir},%{_mandir}/man1}
181 install sh $RPM_BUILD_ROOT%{_bindir}/ash
182 %{!?_without_static:install ash.static $RPM_BUILD_ROOT%{_bindir}/ash.static}
183 install sh.1 $RPM_BUILD_ROOT%{_mandir}/man1/ash.1
184 echo ".so ash.1" > $RPM_BUILD_ROOT%{_mandir}/man1/bsh.1
185 ln -sf ash $RPM_BUILD_ROOT/%{_bindir}/bsh
188 rm -rf $RPM_BUILD_ROOT
192 if [ ! -f /etc/shells ]; then
193 echo "%{_bindir}/ash" > /etc/shells
194 echo "%{_bindir}/bsh" >> /etc/shells
196 if ! grep -q '^%{_bindir}/ash$' /etc/shells ; then
197 echo "%{_bindir}/ash" >> /etc/shells
199 if ! grep -q '^%{_bindir}/bsh$' /etc/shells ; then
200 echo "%{_bindir}/bsh" >> /etc/shells
205 if [ "$1" = 0 ]; then
207 grep -v '^%{_bindir}/ash$' /etc/shells | grep -v '^%{_bindir}/bsh$' > /etc/shells.new
208 mv -f /etc/shells.new /etc/shells
213 if [ ! -f /etc/shells ]; then
214 echo "%{_bindir}/ash.static" >> /etc/shells
216 if ! grep -q '^%{_bindir}/ash.static$' /etc/shells ; then
217 echo "%{_bindir}/ash.static" >> /etc/shells
222 if [ "$1" = 0 ]; then
224 grep -v '^%{_bindir}/ash\.static$' /etc/shells > /etc/shells.new
225 mv -f /etc/shells.new /etc/shells
229 for n in ash bsh ; do
230 echo -n "Looking for $n in /etc/shells... "
231 if ! grep -q "^%{_bindir}/${n}\$" /etc/shells ; then
233 echo "${n} missing from /etc/shells" >&2
240 echo -n "Looking for ash.static in /etc/shells... "
241 if ! grep -q '^%{_bindir}/ash\.static$' /etc/shells ; then
243 echo "ash.static missing from /etc/shells" >&2
249 %defattr(644,root,root,755)
250 %attr(755,root,root) %{_bindir}/ash
251 %attr(755,root,root) %{_bindir}/bsh
254 %{!?_without_static:%files static}
255 %{!?_without_static:%defattr(644,root,root,755)}
256 %{!?_without_static:%attr(755,root,root) %{_bindir}/ash.static}