Bug 14227 - bash2 range pattern match error and SRPM errors
bash2 range pattern match error and SRPM errors
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: bash (Show other bugs)
6.2
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Bernhard Rosenkraenzer
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2000-07-18 12:43 EDT by Karl Hakimian
Modified: 2008-05-01 11:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2000-07-27 14:39:41 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Fix for reported bug (2.22 KB, patch)
2000-07-18 12:43 EDT, Karl Hakimian
no flags Details | Diff

  None (edit)
Description Karl Hakimian 2000-07-18 12:43:03 EDT
There are a couple of problems with bash2 on redhat 6.2. The included
patch to the bash2.spec file in the SRPM fixes them all for me.

1) bash2 does not correctly do pattern matching with a range. For
   example, in a directory containing the following files

A a B b C c

The command

echo [A-Z]*

should return

A B C

but instead returns

A a B b C c

By setting the variable STRCOLL_BROKEN in the config.h the problem goes
away.

2) The SRPM cannot be rebuild with rpm -ba bash2.spec. There are a
   couple of errors in the SRPM.

 a) README does not exist, so the %doc line containing README needs to
    be edited.

 b) The man pages are not compressed, while the man files listed in the
    %files section are.

 c) The man page file list includes ..1.gz which does not exist.


**** CUT HERE ****
*** bash2.spec.orig     Wed Feb  2 12:00:31 2000
--- bash2.spec  Tue Jul 18 09:17:12 2000
***************
*** 1,7 ****
  Summary: The GNU Bourne Again shell (bash) version 2.03.
  Name: bash2
  Version: 2.03
! Release: 8
  Group: System Environment/Shells
  Copyright: GPL
  Source0: ftp://ftp.gnu.org/pub/gnu/bash-%{version}.tar.gz
--- 1,7 ----
  Summary: The GNU Bourne Again shell (bash) version 2.03.
  Name: bash2
  Version: 2.03
! Release: 9
  Group: System Environment/Shells
  Copyright: GPL
  Source0: ftp://ftp.gnu.org/pub/gnu/bash-%{version}.tar.gz
***************
*** 54,59 ****
--- 54,66 ----
  #    ./configure --prefix=$RPM_BUILD_ROOT/usr $RPM_ARCH-redhat-linux
  
  %configure
+ 
+ # Stop the use of strcoll
+ sed 's/.*STRCOLL_BROKEN.*/#define STRCOLL_BROKEN 1/' config.h
>config.h.new
+ chmod 644 config.h.new
+ mv config.h config.h.old
+ mv config.h.new config.h
+ 
  make
  
  %install
***************
*** 91,96 ****
--- 98,105 ----
  1i\
  %defattr(0644,root,man,0755)
  s:^:%{_prefix}/man/man1/:
+ /\/\.$/ d
+ /\/\.\.$/ d
  s/$/.1.gz/
  ' > ../man.pages
  
***************
*** 103,108 ****
--- 112,118 ----
    mv .%{_prefix}/man/man1/bash.1 .%{_prefix}/man/man1/bash2.1
    strip ./bin/* || :
    gzip -9nf .%{_prefix}/info/bash2.info
+   gzip -9nf .%{_prefix}/man/man1/*
    rm -f .%{_prefix}/info/dir
  }
  
***************
*** 129,135 ****
  
  %files -f man.pages
  %defattr(-,root,root)
! %doc CHANGES COMPAT NEWS NOTES README CWRU/POSIX.NOTES
  %doc doc/FAQ doc/INTRO doc/article.ms
  %doc examples/bashdb/ examples/functions/ examples/misc/
  %doc examples/scripts.noah/ examples/scripts.v2/ examples/scripts/
--- 139,145 ----
  
  %files -f man.pages
  %defattr(-,root,root)
! %doc CHANGES COMPAT NEWS NOTES CWRU/POSIX.NOTES
  %doc doc/FAQ doc/INTRO doc/article.ms
  %doc examples/bashdb/ examples/functions/ examples/misc/
  %doc examples/scripts.noah/ examples/scripts.v2/ examples/scripts/
***************
*** 146,151 ****
--- 156,164 ----
  %doc doc/*.ps doc/*.0 doc/*.html doc/article.txt
  
  %changelog
+ * Tue Jul 18 2000 Karl Hakimian <hakimian@aha.com>
+ - Set STRCOLL_BROKEN flag in config.h so that range pattern match works
again.
+ 
  * Wed Feb 02 2000 Cristian Gafton <gafton@redhat.com>
  - man pages are compressed
  - fix description
**** CUT HERE ****
Comment 1 Karl Hakimian 2000-07-18 12:43:55 EDT
Created attachment 1287 [details]
Fix for reported bug
Comment 2 Bernhard Rosenkraenzer 2000-08-03 05:05:14 EDT
Fixed.

Note You need to log in before you can comment on or make changes to this bug.