%define i18ndate 20010626 %define patchlevel 23 %define rel 1 Name: bash Version: 4.4 %define subrel 1 Release: %mkrel %{patchlevel}.%{rel} Summary: The GNU Bourne Again shell (bash) Group: Shells License: GPLv2+ URL: http://www.gnu.org/software/bash/bash.html Source0: ftp://ftp.gnu.org/pub/gnu/bash/%{name}-%{version}.tar.gz Source1: ftp://ftp.gnu.org/pub/gnu/bash/%{name}-%{version}.tar.gz.sig Source2: ftp://ftp.gnu.org/pub/gnu/bash/bash-doc-3.2.tar.bz2 Source3: dot-bashrc Source4: dot-bash_profile Source5: dot-bash_logout Source6: alias.sh Source7: bashrc Source8: profile.d-bash # Official upstream patches # from ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/ Patch01: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-001 Patch02: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-002 Patch03: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-003 Patch04: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-004 Patch05: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-005 Patch06: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-006 Patch07: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-007 Patch08: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-008 Patch09: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-009 Patch10: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-010 Patch11: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-011 Patch12: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-012 Patch13: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-013 Patch14: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-014 Patch15: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-015 Patch16: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-016 Patch17: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-017 Patch18: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-018 Patch19: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-019 Patch20: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-020 Patch21: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-021 Patch22: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-022 Patch23: ftp://ftp.gnu.org/gnu/bash/bash-4.4-patches/bash44-023 # Mageia/Mandriva patches Patch1001: bash-2.02-security.patch # ensure profile is read (Redhat) Patch1003: bash-4.0-profile.patch Patch1006: bash-2.04-compat.patch #https://bugzilla.novell.com/attachment.cgi?id=67684 Patch1010: bash-3.1-extended_quote.patch Patch1020: bash-strcoll-bug.diff Patch1023: bash-2.05b-checkwinsize.patch Patch1024: bash-3.2-lzma-copmpletion.patch # https://bugs.mageia.org/show_bug.cgi?id=19808 - MGA#1025 # Latest source is already patched with this BuildRequires: autoconf2.5 BuildRequires: bison BuildRequires: groff BuildRequires: pkgconfig(tinfo) BuildRequires: texinfo # explicit file provides Provides: /bin/sh /usr/bin/sh Provides: /bin/bash /usr/bin/bash Recommends: bash-completion %description Bash is a GNU project sh-compatible shell or command language interpreter. Bash (Bourne Again shell) incorporates useful features from the Korn shell (ksh) and the C shell (csh). Most sh scripts can be run by bash without modification. Bash offers several improvements over sh, including command line editing, unlimited size command history, job control, shell functions and aliases, indexed arrays of unlimited size and integer arithmetic in any base from two to 64. Bash is ultimately intended to conform to the IEEE POSIX P1003.2/ISO 9945.2 Shell and Tools standard. %package doc Summary: Documentation for the GNU Bourne Again shell (bash) Group: Documentation Requires: %{name} = %{version}-%{release} %description doc This package provides documentation for GNU Bourne Again shell (bash). %prep %setup -q -a 2 mv doc/README . %patch01 -p0 %patch02 -p0 %patch03 -p0 %patch04 -p0 %patch05 -p0 %patch06 -p0 %patch07 -p0 %patch08 -p0 %patch09 -p0 %patch010 -p0 %patch011 -p0 %patch012 -p0 %patch013 -p0 %patch014 -p0 %patch015 -p0 %patch016 -p0 %patch017 -p0 %patch018 -p0 %patch019 -p0 %patch020 -p0 %patch021 -p0 %patch022 -p0 %patch023 -p0 %patch1001 -p1 -b .security %patch1003 -p1 -b .profile #patch1010 -p0 -b .quote %patch1020 -p1 -b .strcoll_bugx #patch1023 -p1 -b .checkwinsize %patch1024 -p1 -b .lzma %build export CFLAGS="%{optflags} -Os" export CXXFLAGS="$CFLAGS" export DEBUGGER_START_FILE="%{_datadir}/bashdb/bashdb-main.inc" %configure2_5x \ --enable-command-timing \ --disable-rpath \ --enable-history \ --enable-job-control \ --enable-multibyte \ --enable-readline \ --with-installed-readline \ --without-gnu-malloc \ --without-bash-malloc \ --disable-strict-posix-default \ --enable-select \ --enable-prompt-string-decoding \ --enable-process-substitution \ --enable-alias \ --enable-bang-history \ --enable-coprocesses \ --enable-directory-stack \ --enable-brace-expansion %make_build # all tests must pass %check make check %install %make_install # beurk rm -rf %{buildroot}%{_datadir}/locale/en@boldquot/ %{buildroot}%{_datadir}/locale/en@quot/ #Sucks chmod +w doc/texinfo.tex chmod 755 examples/misc/aliasconv.* chmod 755 examples/misc/cshtobash chmod 755 %{buildroot}%{_bindir}/bashbug # Take out irritating ^H's from the documentation mkdir tmp_doc for i in `/bin/ls doc/` ; \ do cat doc/$i > tmp_doc/$i ; \ cat tmp_doc/$i | perl -p -e 's/.//g' > doc/$i ; \ rm tmp_doc/$i ; \ done rmdir tmp_doc mkdir -p %{buildroot}/bin ( cd %{buildroot} && mv usr/bin/bash bin/bash ) ( cd %{buildroot}/bin && ln -s bash sh ) # make builtins.1 and rbash.1 with bash.1 in place (fix mdv#51379) (cd doc mkdir tmp_fix_so cd tmp_fix_so cp ../builtins.1 ../rbash.1 . sed -e '/^.if \\n(zZ=1 .ig zZ/,/^.zZ/d' ../bash.1 > bash.1 soelim builtins.1 > ../builtins.1 sed -e '/^.if \\n(zY=1 .ig zY/,/^.zY/d' ../bash.1 > bash.1 soelim rbash.1 > ../rbash.1 ) rm -rf doc/tmp_fix_so # make manpages for bash builtins as per suggestion in DOC/README (cd doc sed -e ' /^\.SH NAME/, /\\- bash built-in commands, see \\fBbash\\fR(1)$/{ /^\.SH NAME/d s/^bash, // s/\\- bash built-in commands, see \\fBbash\\fR(1)$// s/,//g b } d ' builtins.1 | tr -s ' ' '\n' | grep -v -E '^(printf|export|echo|pwd|test|kill)$' > man.pages # tr is needed because there are few commands in a row separated with a whilespace # echo,export,kill,printf,pwd,test -- these files are provided by other packages install -m 644 builtins.1 %{buildroot}%{_mandir}/man1/builtins.1 install -m 644 rbash.1 %{buildroot}%{_mandir}/man1/rbash.1 for i in `cat man.pages` ; do # install man-page echo .so man1/builtins.1 > %{buildroot}%{_mandir}/man1/$i.1 # now turn man.page into a filelist for the man subpackage echo "%{_mandir}/man1/$i.1%{_extension}" >> ../man.pages.filelist done mkdir -p %{buildroot}%{_sysconfdir}/skel mkdir -p %{buildroot}%{_sysconfdir}/profile.d install -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/skel/.bashrc install -m 644 %{SOURCE4} %{buildroot}%{_sysconfdir}/skel/.bash_profile install -m 644 %{SOURCE5} %{buildroot}%{_sysconfdir}/skel/.bash_logout install -m 644 %{SOURCE6} %{buildroot}%{_sysconfdir}/profile.d/60alias.sh install -m 644 %{SOURCE7} %{buildroot}%{_sysconfdir}/bashrc install -m 644 %{SOURCE8} %{buildroot}%{_sysconfdir}/profile.d/95bash-extras.sh ln -s bash %{buildroot}/bin/rbash install -m 644 bash.info %{buildroot}%{_infodir} ) %find_lang %{name} # merges list cat man.pages.filelist %{name}.lang > files.list %files -f files.list %doc %dir %{_docdir}/%{name} %config(noreplace) %{_sysconfdir}/skel/.b* %{_sysconfdir}/profile.d/60alias.sh %{_sysconfdir}/profile.d/95bash-extras.sh %config(noreplace) %{_sysconfdir}/bashrc /bin/rbash /bin/bash /bin/sh %{_infodir}/bash.info* %{_mandir}/man1/bash.1* %{_mandir}/man1/rbash.1* %{_mandir}/man1/builtins.1* %{_mandir}/man1/bashbug.1* %{_bindir}/bashbug %files doc %doc COMPAT NEWS NOTES POSIX CHANGES %doc examples %doc doc/*.ps doc/*.0 doc/*.html doc/article.txt %{_docdir}/%{name} %changelog * Wed Jun 17 2020 kekepower <kekepower> 4.4-23.1.1.mga7 + Revision: 1594197 - bash now provides /usr/bin/bash * Fri Dec 28 2018 luigiwalser <luigiwalser> 4.4-23.1.mga7 + Revision: 1345825 - 4.4.23 * Fri Sep 21 2018 umeabot <umeabot> 4.4-19.2.mga7 + Revision: 1295346 - Mageia 7 Mass Rebuild * Sat Feb 10 2018 kekepower <kekepower> 4.4-19.1.mga7 + Revision: 1200227 - Update to version 4.4-19 * Sat Feb 10 2018 kekepower <kekepower> 4.4-18.1.mga7 + Revision: 1200220 - Update to version 4.4.18 * Thu Oct 19 2017 mjack <mjack> 4.4-12.1.mga7 + Revision: 1172802 - Updated to version 4.4 - Applied latest patches (12 patches from upstream) * Sat Sep 02 2017 tmb <tmb> 4.3-48.4.mga7 + Revision: 1150896 - rebuild with new binutils/gcc * Tue Jan 03 2017 shlomif <shlomif> 4.3-48.3.mga6 + Revision: 1079953 - Patch from Gentoo for MGA#19808 (popd security vuln). * Fri Oct 07 2016 shlomif <shlomif> 4.3-48.2.mga6 + Revision: 1059431 - Apply the -48 patches for good this time. (MGA#19387). * Fri Oct 07 2016 shlomif <shlomif> 4.3-48.1.mga6 + Revision: 1059394 - New patchlevel 48 - fixes MGA#19387 on Cauldron. * Tue Oct 04 2016 luigiwalser <luigiwalser> 4.3-46.3.mga6 + Revision: 1058546 - add patches from fedora to fix CVE-2016-0634 and CVE-2016-7543 * Fri Sep 16 2016 luigiwalser <luigiwalser> 4.3-46.2.mga6 + Revision: 1053482 - add upstream patches to prevent command execution when expanding hostname in prompt * Fri Sep 16 2016 luigiwalser <luigiwalser> 4.3-46.1.mga6 + Revision: 1053474 - update to patchlevel 46 from 33 * Mon Jun 06 2016 tv <tv> 4.3-42.6.mga6 + Revision: 1020435 - unbloat default install: fix duplicating all of bash-doc in bash... * Mon Feb 22 2016 blino <blino> 4.3-42.5.mga6 + Revision: 975936 - replace perl PROMPT_COMMAND with a bash scriptlet, to avoid spawning perl at each command line prompt (mga#1623) * Sat Feb 20 2016 umeabot <umeabot> 4.3-42.4.mga6 + Revision: 972326 - Mageia 6 Mass Rebuild * Mon Nov 02 2015 ovitters <ovitters> 4.3-42.3.mga6 + Revision: 897382 - add ~/.local/bin to default PATH (python pip installs user binaries here) * Fri Oct 23 2015 joequant <joequant> 4.3-42.2.mga6 + Revision: 894355 - fix %%doc string + luigiwalser <luigiwalser> - docs are in doc subpackage * Thu Oct 22 2015 joequant <joequant> 4.3-42.1.mga6 + Revision: 894194 - patch to 42 and fix doc dir * Wed Oct 21 2015 guillomovitch <guillomovitch> 4.3-33.3.mga6 + Revision: 893962 - fix build * Fri Aug 21 2015 tmb <tmb> 4.3-33.2.mga6 + Revision: 867411 - rebuild for mga6 * Tue Jan 27 2015 luigiwalser <luigiwalser> 4.3-33.1.mga5 + Revision: 812464 - update to patchlevel 33 * Wed Oct 15 2014 umeabot <umeabot> 4.3-30.3.mga5 + Revision: 740961 - Second Mageia 5 Mass Rebuild * Mon Oct 06 2014 luigiwalser <luigiwalser> 4.3-30.2.mga5 + Revision: 737079 - actually apply the patches * Mon Oct 06 2014 luigiwalser <luigiwalser> 4.3-30.1.mga5 + Revision: 737078 - update to patchlevel 30 to fix two remaining parser bugs * Wed Oct 01 2014 luigiwalser <luigiwalser> 4.3-28.1.mga5 + Revision: 733911 - replace patch 1025 with upstream patch 28 for CVE-2014-718[78] * Wed Oct 01 2014 luigiwalser <luigiwalser> 4.3-27.2.mga5 + Revision: 733683 - add patch from fedora to fix CVE-2014-7186 and CVE-2014-7187 - update to patchlevel 27 to provide further hardening against shellshock issues * Fri Sep 26 2014 luigiwalser <luigiwalser> 4.3-26.1.mga5 + Revision: 725617 - update to patchlevel 26 to fix CVE-2014-7169 - remove conflicting RedHat patch for now * Fri Sep 26 2014 oden <oden> 4.3-25.2.mga5 + Revision: 724877 - P1025: security fix for CVE-2014-7169 (rhel6) * Wed Sep 24 2014 luigiwalser <luigiwalser> 4.3-25.1.mga5 + Revision: 724254 - add upstream patch 025 (fixes CVE-2014-6271) * Tue Sep 23 2014 tv <tv> 4.3-24.4.mga5 + Revision: 722237 - kill no more needed /bin/bash provides * Tue Sep 16 2014 umeabot <umeabot> 4.3-24.3.mga5 + Revision: 678118 - Mageia 5 Mass Rebuild + tv <tv> - s/uggests:/Recommends:/ * Sun Sep 14 2014 tmb <tmb> 4.3-24.2.mga5 + Revision: 675225 - add explicit /bin/bash provides * Sun Aug 31 2014 luigiwalser <luigiwalser> 4.3-24.1.mga5 + Revision: 670099 - add upstream patches 023 and 024 * Sun Aug 17 2014 luigiwalser <luigiwalser> 4.3-22.1.mga5 + Revision: 664545 - add upstream patches 001 through 022 * Sat Mar 08 2014 guillomovitch <guillomovitch> 4.3-1.mga5 + Revision: 601282 - new version 4.3 * Sat Nov 30 2013 tv <tv> 4.2-45.6.mga4 + Revision: 554157 - suggests bash-completion (mga#9031) * Mon Oct 21 2013 umeabot <umeabot> 4.2-45.5.mga4 + Revision: 539989 - Mageia 4 Mass Rebuild * Tue Oct 08 2013 colin <colin> 4.2-45.4.mga4 + Revision: 493108 - Rebuild against ncurse's libtinfo rather than libtermcap * Fri Aug 23 2013 kamil <kamil> 4.2-45.3.mga4 + Revision: 470226 - make the specfile simpler and shorter - refactoring of the removal of printf|export|echo|pwd|test|kill from the installation - stop installing /bin/bash3 - it was introduced before Thu Apr 12 12:26:56 2007 UTC (@mandriva svn r947) bash-3.2-1mdv2007.1. Bash 4.0 release1 was introduced into Mandriva sources on Fri May 1 20:30:59 2009 UTC (@mandriva svn r370148). grep -r bash3 /usr/* and grep -r bash4 /etc/* gives nothing relevant in a standard Mageia Cauldron installation * Thu Aug 22 2013 kamil <kamil> 4.2-45.2.mga4 + Revision: 469307 - Make the shell part of the .spec more generic and portable * Sun May 26 2013 kamil <kamil> 4.2-45.1.mga4 + Revision: 428049 - include patches up to 45 - update to patchlevel 45 - provide /usr/bin/sh - clean .spec * Fri Jan 11 2013 umeabot <umeabot> 4.2-37.4.mga3 + Revision: 346872 - Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild * Fri Dec 07 2012 shlomif <shlomif> 4.2-37.3.mga3 + Revision: 327928 - Fix for https://bugs.mageia.org/show_bug.cgi?id=1623 . Tested that everything is working and the bug was fixed. PROMPT_COMMAND had a minor problem. * Wed Oct 10 2012 shlomif <shlomif> 4.2-37.2.mga3 + Revision: 304270 - Convert to a more appropriate group. - Remove trailing space * Mon Jul 23 2012 blino <blino> 4.2-37.1.mga3 + Revision: 273738 - update to patchlevel 37 * Tue May 29 2012 blino <blino> 4.2-28.1.mga3 + Revision: 249522 - patchlevel 28 - use upstream patchlevel in package release - rename patches to match upstream numbers - do not write anywore unused _distribution and _patchlevel files in build dir - fix running install section multiple times * Mon May 09 2011 ahmad <ahmad> 4.2-5.mga1 + Revision: 96666 - Patchlevel 10 * Wed Mar 16 2011 ahmad <ahmad> 4.2-4.mga1 + Revision: 72271 - patchlevel 8 * Fri Mar 04 2011 ahmad <ahmad> 4.2-3.mga1 + Revision: 64454 - patchlevel 6 - %%define patchlevel - remove a redundant sed command line (spotted by Maarten Vanraes) * Tue Feb 22 2011 ahmad <ahmad> 4.2-1.mga1 + Revision: 55906 - sync with Mandriva revision 639152: o update to bash 4.2 o drop upstream patches o compile with -Os flag o enable few options in configure script o reenable ru localization * Tue Jan 11 2011 blino <blino> 4.1-7.mga1 + Revision: 5648 - remove old versions and conflicts/obsoletes - update distro name + dmorgan <dmorgan> - Fix use of %%exclude + pterjan <pterjan> - imported package bash - imported package bash - imported package bash