]> git.pld-linux.org Git - packages/bash.git/blobdiff - bash.spec
- BuildRequires: autoconf
[packages/bash.git] / bash.spec
index 621be2d92fa90c43a88204056540e472ece9dedb..9826462cd355c588eddae59147638baad41941c3 100644 (file)
--- a/bash.spec
+++ b/bash.spec
@@ -4,37 +4,48 @@ Summary(fr):  Le shell Bourne Again de GNU
 Summary(pl):   GNU Bourne Again Shell (bash)
 Summary(tr):   GNU Bourne Again Shell (bash)
 Name:          bash
-Version:       2.04
-Release:       13
+Version:       2.05
+Release:       6
+License:       GPL
 Group:         Applications/Shells
 Group(de):     Applikationen/Shells
 Group(pl):     Aplikacje/Pow³oki
-License:       GPL
 Source0:       ftp://prep.ai.mit.edu/pub/gnu/bash/%{name}-%{version}.tar.gz
 Source1:       %{name}rc
 Source2:       %{name}-skel-.bash_logout
 Source3:       %{name}-skel-.bash_profile
 Source4:       %{name}-skel-.bashrc
-Source5:       %{name}-skel_pl-.bashrc
 Patch0:                %{name}-paths.patch
-Patch1:                %{name}-fixes.patch
-Patch2:                %{name}-security.patch
-Patch3:                %{name}-autoconf.patch
-Patch4:                %{name}-info.patch
-Patch5:                %{name}-profile.patch
-Patch6:                %{name}-requires.patch
-Patch7:                %{name}-compat.patch
-Patch8:                %{name}-shellfunc.patch
-Patch9:                %{name}-export.patch
-BuildRequires: ncurses-static >= 5.0
-BuildRequires: readline-static >= 4.1
+Patch1:                %{name}-security.patch
+Patch2:                %{name}-autoconf.patch
+Patch3:                %{name}-info.patch
+Patch4:                %{name}-profile.patch
+Patch5:                %{name}-requires.patch
+Patch6:                %{name}-compat.patch
+Patch7:                %{name}-shellfunc.patch
+Patch8:                http://www.t17.ds.pwr.wroc.pl/~misiek/ipv6/bash-2.05-ipv6-20010418.patch.gz
+Patch9:                %{name}-DESTDIR.patch
+Patch10:       %{name}-rlimit_locks.patch
+Patch11:       %{name}-sighup.patch
+Patch12:       %{name}-tmpfile.patch
+BuildRequires: ncurses-devel >= 5.2
+BuildRequires: readline-devel >= 4.2
+BuildRequires: glibc-devel >= 2.2
+%if %{!?_without_static:1}%{?_without_static:0}
+# Require static library only for static build
+BuildRequires: ncurses-static >= 5.2
+BuildRequires: readline-static >= 4.2
 BuildRequires: glibc-static >= 2.2
-PreReq:                grep
-PreReq:                fileutils
+%endif
+BuildRequires: bison
+BuildRequires: autoconf
+Prereq:                grep
+Prereq:                fileutils
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+Obsoletes:     bash-doc
 Obsoletes:     bash2
-Obsoletes:     etcskel
 Obsoletes:     bash2-doc
+Obsoletes:     etcskel
 
 %description
 Bash is a GNU project sh-compatible shell or command language
@@ -77,10 +88,15 @@ l'installer du fait de sa puissance et de sa popularit
 probablement par l'utiliser.
 
 %description -l pl
-Bash jest zaawansowanym shellem, który wykonuje komendy czytane ze
-standardowego wej¶cia (stdin) lub z pliku. Posiada w³a¶ciwo¶ci shelli
-Korn i C (ksh i csh). Bash ma równie¿ zaimplementowany IEEE Posix
-Shell oraz jest zgodny ze specyfikacj± - IEEE Working Group 1003.2.
+Bash (Bourne Again SHell) jest projektem GNU pow³oki kompatybilnej z
+sh oraz interpretera jêzyka poleceñ. Posiada u¿yteczne w³a¶ciwo¶ci
+pow³ok Korn (ksh) i C (csh). Wiêkszo¶æ skryptów sh mo¿e byæ
+uruchamiana w bashu bez modyfikacji. Oferuje on kilka ulepszeñ w
+stusunku do sh, w³±czaj±c edycjê linii poleceñ, nieograniczony rozmiar
+historii poleceñ, funkcje i aliasy, indeksowane tablice
+nieograniczonych rozmiarów oraz arytmetykê ca³kowitoliczbow± o
+dowolnej podstawie od 2 do 64. W zamierzeniu ostatecznie ma byæ zgodny
+ze standardem IEEE POSIX P1003.2/ISO 9945.2 Shell and Tools.
 
 %description -l tr
 Bash standart giriþten ya da bir dosyadan komut okuyup çalýþtýran sh
@@ -96,8 +112,8 @@ Group:               Applications/Shells
 Group(de):     Applikationen/Shells
 Group(pl):     Aplikacje/Pow³oki
 Requires:      %{name}
-PreReq:                grep
-PreReq:                fileutils
+Prereq:                grep
+Prereq:                fileutils
 
 %description static
 Bash is a GNU project sh-compatible shell or command language
@@ -115,7 +131,7 @@ version of bash.
 
 %description static -l pl
 Bash jest zaawansowanym shellem, który wykonuje komendy czytane ze
-standardowego wej¶cia (stdin) lub z pliku. Posiada w³a¶ciwo¶ci shelli
+standardowego wej¶cia (stdin) lub z pliku. Posiada w³a¶ciwo¶ci pow³ok
 Korn i C (ksh i csh). Bash ma równie¿ zaimplementowany IEEE Posix
 Shell oraz jest zgodny ze specyfikacj± - IEEE Working Group 1003.2. W
 tym pakiecie jest statycznie zlinkowany bash.
@@ -132,11 +148,16 @@ tym pakiecie jest statycznie zlinkowany bash.
 %patch7 -p1
 %patch8 -p1
 %patch9 -p1
+%patch10 -p1
+%patch11 -p1
+%patch12 -p1
 
 echo %{version} > _distribution
 echo %{release} > _patchlevel
 
 %build
+autoconf
+for mode in %{!?_without_static:static} shared; do
 %configure \
        --enable-alias \
        --enable-help-builtin \
@@ -147,47 +168,46 @@ echo %{release} > _patchlevel
        --with-curses \
        --enable-extended-glob \
        --enable-dparen-arithmetic \
-       --enable-static-link \
+       `[ "$mode" = "static" ] && echo "--enable-static-link"` \
        --with-installed-readline
 
-%{__make} TERMCAP_LIB="-ltinfo"
-mv -f bash bash.static
-%{__make} TERMCAP_LIB="-ltinfo" STATIC_LD=""
+%{__make} DEFS="-DHAVE_CONFIG_H -D_GNU_SOURCE"
+
+[ "$mode" = "static" ] && mv -f bash bash.static || :
+done
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_mandir},%{_infodir}} \
-       $RPM_BUILD_ROOT/{bin,etc/skel/{C,pl}}
+install -d $RPM_BUILD_ROOT/{bin,etc/skel}
 
-%{__make} install \
-       bindir=$RPM_BUILD_ROOT%{_bindir} \
-       infodir=$RPM_BUILD_ROOT%{_infodir} \
-       mandir=$RPM_BUILD_ROOT%{_mandir} 
+%{__make} install DESTDIR=$RPM_BUILD_ROOT
 
 mv -f $RPM_BUILD_ROOT%{_bindir}/bash $RPM_BUILD_ROOT/bin
-install        bash.static $RPM_BUILD_ROOT/bin
+%{?_without_static:#}install   bash.static $RPM_BUILD_ROOT/bin
 
 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/bashrc
 echo .so bash.1 > $RPM_BUILD_ROOT%{_mandir}/man1/rbash.1
 
 ln -sf bash $RPM_BUILD_ROOT/bin/rbash
 
-install %{SOURCE2} $RPM_BUILD_ROOT/etc/skel/C/.bash_logout
-install %{SOURCE3} $RPM_BUILD_ROOT/etc/skel/C/.bash_profile
-install %{SOURCE4} $RPM_BUILD_ROOT/etc/skel/C/.bashrc
-install %{SOURCE5} $RPM_BUILD_ROOT/etc/skel/pl/.bashrc
+install %{SOURCE2} $RPM_BUILD_ROOT/etc/skel/.bash_logout
+install %{SOURCE3} $RPM_BUILD_ROOT/etc/skel/.bash_profile
+install %{SOURCE4} $RPM_BUILD_ROOT/etc/skel/.bashrc
 
 gzip -9nf NEWS README doc/{FAQ,INTRO}
 
+%clean
+rm -rf $RPM_BUILD_ROOT
+
 %post
 if [ ! -f /etc/shells ]; then
        echo "/bin/bash" > /etc/shells
        echo "/bin/rbash" >> /etc/shells
 else
-       if ! grep '^/bin/bash$' /etc/shells > /dev/null; then
+       if ! grep -q '^/bin/bash$' /etc/shells; then
                echo "/bin/bash" >> /etc/shells
        fi
-       if ! grep '^/bin/rbash$' /etc/shells > /dev/null; then
+       if ! grep -q '^/bin/rbash$' /etc/shells; then
                echo "/bin/rbash" >> /etc/shells
        fi
 fi
@@ -198,7 +218,7 @@ fi
 if [ ! -f /etc/shells ]; then
        echo "/bin/bash.static" > /etc/shells
 else
-       if ! grep '^/bin/bash.static$' /etc/shells > /dev/null; then
+       if ! grep -q '^/bin/bash.static$' /etc/shells; then
                echo "/bin/bash.static" >> /etc/shells
        fi
 fi
@@ -218,19 +238,14 @@ fi
 %postun
 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
 
-%clean
-rm -rf $RPM_BUILD_ROOT
-
 %files
 %defattr(644,root,root,755)
 %doc {NEWS,README}.gz doc/{FAQ,INTRO}.gz
 
-%config %{_sysconfdir}/bashrc
-
-/etc/skel/C/.bash_logout
-/etc/skel/C/.bash_profile
-/etc/skel/C/.bashrc
-%lang(pl) /etc/skel/pl/.bashrc
+%config %verify(not md5 size mtime) %{_sysconfdir}/bashrc
+%config(noreplace,missingok) %verify(not md5 size mtime) /etc/skel/.bash_logout
+%config(noreplace,missingok) %verify(not md5 size mtime) /etc/skel/.bash_profile
+%config(noreplace,missingok) %verify(not md5 size mtime) /etc/skel/.bashrc
 
 %attr(755,root,root) /bin/bash
 %attr(755,root,root) /bin/rbash
@@ -239,6 +254,6 @@ rm -rf $RPM_BUILD_ROOT
 %{_infodir}/bash.info.gz
 %{_mandir}/man1/*
 
-%files static
-%defattr(644,root,root,755)
-%attr(755,root,root) /bin/bash.static
+%{?_without_static:#}%files static
+%{?_without_static:#}%defattr(644,root,root,755)
+%{?_without_static:#}%attr(755,root,root) /bin/bash.static
This page took 0.046187 seconds and 4 git commands to generate.