winbash-checkins Mailing List for winbash - bash for win32 (Page 5)
Brought to you by:
enricobrunetta,
xks
You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
(119) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
---|
From: kevin s. <xk...@us...> - 2002-03-09 15:03:58
|
Update of /cvsroot/winbash/winbash/tests In directory usw-pr-cvs1:/tmp/cvs-serv2533/tests Modified Files: getopts.sh Log Message: a better getopts test Index: getopts.sh =================================================================== RCS file: /cvsroot/winbash/winbash/tests/getopts.sh,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- getopts.sh 9 Mar 2002 04:43:16 -0000 1.2 +++ getopts.sh 9 Mar 2002 15:03:55 -0000 1.3 @@ -3,21 +3,48 @@ { while getopts :a:b:c:d:e:f:g:h:i:j:k:l: opt; do case $opt in - a) ORACLE_HOME="$OPTARG";; - b) ORASERVICE="$OPTARG";; - c) DBA_USER="$OPTARG";; - d) DBA_PW="$OPTARG";; - e) DB_USER="$OPTARG";; - f) DB_PASSWD="$OPTARG";; - g) DB_REPORT_USER="$OPTARG";; - h) DB_REPORT_PASSWD="$OPTARG";; - i) APPKEY="$OPTARG";; - j) DB_SIZE_PARAM="$OPTARG";; - k) DB_DATAFILE_HOME="$OPTARG";; - l) DB_INDEXFILE_HOME="$OPTARG";; + a) a="$OPTARG";; + b) b="$OPTARG";; + c) c="$OPTARG";; + d) d="$OPTARG";; + e) e="$OPTARG";; + f) f="$OPTARG";; + g) g="$OPTARG";; + h) h="$OPTARG";; + i) i="$OPTARG";; + j) j="$OPTARG";; + k) k="$OPTARG";; + l) l="$OPTARG";; \?) echo "unknown option -$OPTARG" && exit 1;; esac done } -testit -a foo -b bar -c hey -d ra -e top +testit \ + -a avalue \ + -b bvalue \ + -c cvalue \ + -d dvalue \ + -e evalue \ + -f fvalue \ + -g gvalue \ + -h hvalue \ + -i ivalue \ + -j jvalue \ + -k kvalue \ + -l lvalue + +[ "${a}" = "avalue" ] || echo "error a=${a}, should be avalue" +[ "${b}" = "bvalue" ] || echo "error b=${b}, expected bvalue" +[ "${c}" = "cvalue" ] || echo "error c=${c}, expected cvalue" +[ "${d}" = "dvalue" ] || echo "error d=${d}, expected dvalue" +[ "${e}" = "evalue" ] || echo "error e=${e}, expected evalue" +[ "${f}" = "fvalue" ] || echo "error f=${f}, expected fvalue" +[ "${g}" = "gvalue" ] || echo "error g=${g}, expected gvalue" +[ "${h}" = "hvalue" ] || echo "error h=${h}, expected hvalue" +[ "${i}" = "ivalue" ] || echo "error i=${i}, expected ivalue" +[ "${j}" = "jvalue" ] || echo "error j=${j}, expected jvalue" +[ "${k}" = "kvalue" ] || echo "error k=${k}, expected kvalue" +[ "${l}" = "lvalue" ] || echo "error l=${l}, expected lvalue" + +echo 'PASSED -- getopts' |
From: Enrico B. <enr...@us...> - 2002-03-09 04:49:35
|
Update of /cvsroot/winbash/winbash/bison In directory usw-pr-cvs1:/tmp/cvs-serv1989 Modified Files: bison.exe Log Message: mistakenly converted cr lf in exe... Index: bison.exe =================================================================== RCS file: /cvsroot/winbash/winbash/bison/bison.exe,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 Binary files /tmp/cvsyaNPIq and /tmp/cvsEDb6qI differ |
Update of /cvsroot/winbash/winbash/documentation In directory usw-pr-cvs1:/tmp/cvs-serv381/documentation Modified Files: Makefile README article.ms article.ps article.txt bash.1 bash.ps bash.txt builtins.1 builtins.ps builtins.txt features.dvi features.info features.ps features.texi readline.3 readline.ps readline.txt texinfo.tex Log Message: Fixed more cr/lf problems. Index: Makefile =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- Makefile 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ Makefile 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,119 +1,119 @@ -# This Makefile is for the Bash/documentation directory -*- text -*-. -# -CP = cp -RM = rm -f - -INSTALL_DATA = install -c -m 644 - -DOC_SUPPORT = ../lib/doc-support/ -TEXINDEX = $(DOC_SUPPORT)texindex -TEXINDSRC = $(DOC_SUPPORT)texindex.c -TEX = tex -QUIETPS = #set this to -q to shut up dvips -DVIPS = dvips -D 300 $(QUIETPS) -o $@ # tricky -TEXINPUTS = ./../lib/readline/doc -MAKEINFO = makeinfo - -# Change to groff -Tascii if you don't have nroff -NROFF = nroff - -# This should be a program that converts troff to postscript -GROFF = groff - -HSUSER = ./../lib/readline/doc/hsuser.texinfo -RLUSER = ./../lib/readline/doc/rluser.texinfo - -.SUFFIXES: .1 .3 .ms .ps .txt .dvi - -.1.ps: - $(RM) $@ - ${GROFF} -man $< > $@ - -.1.txt: - $(RM) $@ - ${NROFF} -man $< > $@ - -.ms.ps: - $(RM) $@ - ${GROFF} -ms $< > $@ - -.ms.txt: - $(RM) $@ - ${NROFF} -ms $< > $@ - -.3.ps: - $(RM) $@ - ${GROFF} -man $< > $@ - -.3.txt: - $(RM) $@ - ${NROFF} -man $< > $@ - -all: ps info dvi text - -ps: bash.ps builtins.ps readline.ps article.ps -dvi: features.dvi features.ps -info: features.info -text: bash.txt builtins.txt readline.txt article.txt - -features.dvi: features.texi $(HSUSER) $(RLUSER) - TEXINPUTS=.:$(TEXINPUTS):$$TEXINPUTS $(TEX) features.texi - $(TEXINDEX) features.?? - TEXINPUTS=.:$(TEXINPUTS):$$TEXINPUTS $(TEX) features.texi - -features.ps: features.dvi - $(RM) $@ - $(DVIPS) features.dvi - -features.info: features.texi $(HSUSER) $(RLUSER) - $(MAKEINFO) --no-split -I$(TEXINPUTS) features.texi - -bash.dvi: $(TEXINDEX) bash.texinfo $(HSUSER) $(RLUSER) - TEXINPUTS=.:$(TEXINPUTS):$$TEXINPUTS $(TEX) bash.texinfo - $(TEXINDEX) bash.?? - TEXINPUTS=.:$(TEXINPUTS):$$TEXINPUTS $(TEX) bash.texinfo - -bashman.ps: bash.dvi - rm -f $@ - $(DVIPS) bash.dvi - -bash.txt: bash.1 -bash.ps: bash.1 -builtins.ps: builtins.1 bash.1 -builtins.txt: builtins.1 bash.1 -readline.txt: readline.3 -readline.ps: readline.3 -article.ps: article.ms - -$(TEXINDEX): $(TEXINDSRC) - (cd $(DOC_SUPPORT); $(MAKE) $(MFLAGS) texindex) - -hsuser.texinfo: ../lib/readline/doc/hsuser.texinfo - ln -s ../lib/readline/doc/hsuser.texinfo . - -rluser.texinfo: ../lib/readline/doc/rluser.texinfo - ln -s ../lib/readline/doc/rluser.texinfo . - -clean: - rm -f *.aux *.cp *.fn *.ky *.log *.pg *.toc *.tp *.vr *.cps *.pgs \ - *.fns *.kys *.tps *.vrs *.o core texindex rluser.texinfo hsuser.texinfo - -distclean: - rm -f *.aux *.cp *.fn *.ky *.log *.pg *.toc *.tp *.vr *.cps *.pgs \ - *.dvi *.info *.info-* *.fns *.kys *.tps *.vrs *.o core texindex \ - rluser.texinfo hsuser.texinfo - -realclean: clean - -install: all - [ -d $(mandir) ] || mkdir $(mandir) - $(INSTALL_DATA) bash.1 $(mandir) - sed 's:so bash.1:so man1/bash.1:' < builtins.1 > $(mandir)/bash_builtins.1 - [ -d $(man3dir) ] || mkdir $(man3dir) - $(INSTALL_DATA) readline.3 $(man3dir) - [ -d $(infodir) ] || mkdir $(infodir) - $(INSTALL_DATA) features.info $(infodir)/bash.info - -uninstall: - $(RM) $(mandir)/bash.1 $(mandir)/bash_builtins.1 - $(RM) $(man3dir)/readline.3 $(infodir)/bash.info +# This Makefile is for the Bash/documentation directory -*- text -*-. +# +CP = cp +RM = rm -f + +INSTALL_DATA = install -c -m 644 + +DOC_SUPPORT = ../lib/doc-support/ +TEXINDEX = $(DOC_SUPPORT)texindex +TEXINDSRC = $(DOC_SUPPORT)texindex.c +TEX = tex +QUIETPS = #set this to -q to shut up dvips +DVIPS = dvips -D 300 $(QUIETPS) -o $@ # tricky +TEXINPUTS = ./../lib/readline/doc +MAKEINFO = makeinfo + +# Change to groff -Tascii if you don't have nroff +NROFF = nroff + +# This should be a program that converts troff to postscript +GROFF = groff + +HSUSER = ./../lib/readline/doc/hsuser.texinfo +RLUSER = ./../lib/readline/doc/rluser.texinfo + +.SUFFIXES: .1 .3 .ms .ps .txt .dvi + +.1.ps: + $(RM) $@ + ${GROFF} -man $< > $@ + +.1.txt: + $(RM) $@ + ${NROFF} -man $< > $@ + +.ms.ps: + $(RM) $@ + ${GROFF} -ms $< > $@ + +.ms.txt: + $(RM) $@ + ${NROFF} -ms $< > $@ + +.3.ps: + $(RM) $@ + ${GROFF} -man $< > $@ + +.3.txt: + $(RM) $@ + ${NROFF} -man $< > $@ + +all: ps info dvi text + +ps: bash.ps builtins.ps readline.ps article.ps +dvi: features.dvi features.ps +info: features.info +text: bash.txt builtins.txt readline.txt article.txt + +features.dvi: features.texi $(HSUSER) $(RLUSER) + TEXINPUTS=.:$(TEXINPUTS):$$TEXINPUTS $(TEX) features.texi + $(TEXINDEX) features.?? + TEXINPUTS=.:$(TEXINPUTS):$$TEXINPUTS $(TEX) features.texi + +features.ps: features.dvi + $(RM) $@ + $(DVIPS) features.dvi + +features.info: features.texi $(HSUSER) $(RLUSER) + $(MAKEINFO) --no-split -I$(TEXINPUTS) features.texi + +bash.dvi: $(TEXINDEX) bash.texinfo $(HSUSER) $(RLUSER) + TEXINPUTS=.:$(TEXINPUTS):$$TEXINPUTS $(TEX) bash.texinfo + $(TEXINDEX) bash.?? + TEXINPUTS=.:$(TEXINPUTS):$$TEXINPUTS $(TEX) bash.texinfo + +bashman.ps: bash.dvi + rm -f $@ + $(DVIPS) bash.dvi + +bash.txt: bash.1 +bash.ps: bash.1 +builtins.ps: builtins.1 bash.1 +builtins.txt: builtins.1 bash.1 +readline.txt: readline.3 +readline.ps: readline.3 +article.ps: article.ms + +$(TEXINDEX): $(TEXINDSRC) + (cd $(DOC_SUPPORT); $(MAKE) $(MFLAGS) texindex) + +hsuser.texinfo: ../lib/readline/doc/hsuser.texinfo + ln -s ../lib/readline/doc/hsuser.texinfo . + +rluser.texinfo: ../lib/readline/doc/rluser.texinfo + ln -s ../lib/readline/doc/rluser.texinfo . + +clean: + rm -f *.aux *.cp *.fn *.ky *.log *.pg *.toc *.tp *.vr *.cps *.pgs \ + *.fns *.kys *.tps *.vrs *.o core texindex rluser.texinfo hsuser.texinfo + +distclean: + rm -f *.aux *.cp *.fn *.ky *.log *.pg *.toc *.tp *.vr *.cps *.pgs \ + *.dvi *.info *.info-* *.fns *.kys *.tps *.vrs *.o core texindex \ + rluser.texinfo hsuser.texinfo + +realclean: clean + +install: all + [ -d $(mandir) ] || mkdir $(mandir) + $(INSTALL_DATA) bash.1 $(mandir) + sed 's:so bash.1:so man1/bash.1:' < builtins.1 > $(mandir)/bash_builtins.1 + [ -d $(man3dir) ] || mkdir $(man3dir) + $(INSTALL_DATA) readline.3 $(man3dir) + [ -d $(infodir) ] || mkdir $(infodir) + $(INSTALL_DATA) features.info $(infodir)/bash.info + +uninstall: + $(RM) $(mandir)/bash.1 $(mandir)/bash_builtins.1 + $(RM) $(man3dir)/readline.3 $(infodir)/bash.info Index: README =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/README,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- README 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ README 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,31 +1,31 @@ -This directory contains the bash documentation. - -article.ms - an article I wrote about bash for The Linux Journal -bash.1 - the bash man page -builtins.1 - a man page that documents the builtins, extracted from bash.1 -features.texi - the `bash features' document, suitable for an info tree -readline.3 - the readline man page - -The `.ps' files are postscript versions of the above. The `.txt' versions -are ascii -- the output of `nroff'. - -The rest of this file explains how to use the `builtins.1' man page. - -For each command in the list of builtins create a file in man/man1 called: - -${command}.1 - -eg. -for.1 -type.1 -alias.1 -etc. - -All these files are identical as follows: - -jaws@jaws(264)$ cat alias.1 -.so man1/builtins.1 -jaws@jaws(265)$ - -Make sure you adjust the .so line in builtins.1 to reflect where you -put it. +This directory contains the bash documentation. + +article.ms - an article I wrote about bash for The Linux Journal +bash.1 - the bash man page +builtins.1 - a man page that documents the builtins, extracted from bash.1 +features.texi - the `bash features' document, suitable for an info tree +readline.3 - the readline man page + +The `.ps' files are postscript versions of the above. The `.txt' versions +are ascii -- the output of `nroff'. + +The rest of this file explains how to use the `builtins.1' man page. + +For each command in the list of builtins create a file in man/man1 called: + +${command}.1 + +eg. +for.1 +type.1 +alias.1 +etc. + +All these files are identical as follows: + +jaws@jaws(264)$ cat alias.1 +.so man1/builtins.1 +jaws@jaws(265)$ + +Make sure you adjust the .so line in builtins.1 to reflect where you +put it. Index: article.ms =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/article.ms,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- article.ms 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ article.ms 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,1114 +1,1114 @@ -.de SE \" start example -.sp .5 -.RS -.ft CR -.nf -.. -.de EE \" end example -.fi -.sp .5 -.RE -.ft R [...2197 lines suppressed...] +are included, and a \*Qminimal\*U configuration, which omits job +control, aliases, history and command line editing, the directory +stack and +.B pushd/popd/dirs, +process substitution, prompt string special character decoding, and the +.I select +construct. This minimal version is designed to be a drop-in replacement +for the traditional \s-1UNIX\s+1 /bin/sh, and is included as the Linux +/bin/sh in several packagings. +.NH 1 +Conclusion +.PP +Bash is a worthy successor to sh. +It is sufficiently portable +to run on nearly every version of \s-1UNIX\s+1 from +4.3 BSD to SVR4.2, and several \s-1UNIX\s+1 workalikes. +It is robust enough to replace sh on most of those systems, +and provides more functionality. It has several thousand regular users, +and their feedback has helped to make it as good as it is today \- a +testament to the benefits of free software. Index: article.ps =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/article.ps,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- article.ps 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ article.ps 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,1368 +1,1368 @@ -%!PS-Adobe-3.0 -%%Creator: groff version 1.08 -%%DocumentNeededResources: font Times-Bold -%%+ font Times-Italic -%%+ font Times-Roman -%%+ font Courier -%%DocumentSuppliedResources: procset grops 1.08 0 -%%Pages: 11 -%%PageOrder: Ascend -%%Orientation: Portrait -%%EndComments [...2705 lines suppressed...] +223.2 R .8(It is suf)5.8 F .8(\214ciently portable to run on nearly e)-.25 F +-.15(ve)-.25 G .8(ry v).15 F .8(ersion of)-.15 F F1(UNIX)3.3 E F0 .311 +(from 4.3 BSD to SVR4.2, and se)72 235.2 R -.15(ve)-.25 G(ral).15 E F1(UNIX) +2.811 E F0 -.1(wo)2.811 G(rkalik).1 E 2.811(es. It)-.1 F .31(is rob)2.81 F .31 +(ust enough to replace sh on most of those)-.2 F 1.515(systems, and pro)72 +247.2 R 1.515(vides more functionality)-.15 F 6.515(.I)-.65 G 4.015(th)254.315 +247.2 S 1.515(as se)266.11 247.2 R -.15(ve)-.25 G 1.515(ral thousand re).15 F +1.515(gular users, and their feedback has)-.15 F(helped to mak)72 259.2 Q 2.5 +(ei)-.1 G 2.5(ta)138.28 259.2 S 2.5(sg)148 259.2 S +(ood as it is today \255 a testament to the bene\214ts of free softw)159.39 +259.2 Q(are.)-.1 E .32 LW 76 698 72 698 DL 80 698 76 698 DL 84 698 80 698 DL 88 +698 84 698 DL 92 698 88 698 DL 96 698 92 698 DL 100 698 96 698 DL 104 698 100 +698 DL 108 698 104 698 DL 112 698 108 698 DL 116 698 112 698 DL 120 698 116 698 +DL 124 698 120 698 DL 128 698 124 698 DL 132 698 128 698 DL 136 698 132 698 DL +140 698 136 698 DL 144 698 140 698 DL/F4 8/Times-Roman@0 SF +(*BSD/386 is a trademark of Berk)72 708 Q(ele)-.08 E 2(yS)-.12 G(oftw)198.896 +708 Q(are Design, Inc.)-.08 E EP +%%Trailer +end +%%EOF Index: article.txt =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/article.txt,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- article.txt 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ article.txt 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,1111 +1,1111 @@ - - - - - - - - - - Bash - The GNU shell* - [...2191 lines suppressed...] + + + + + + + + + + +_________________________ +*BSD/386 is a trademark of Berkeley Software Design, +Inc. + + + + + July 18, 1994 + + Index: bash.1 =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/bash.1,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bash.1 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ bash.1 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,5366 +1,5366 @@ -.\" -.\" MAN PAGE COMMENTS to -.\" -.\" Chet Ramey -.\" Information Network Services -.\" Case Western Reserve University -.\" ch...@in... -.\" -.\" Last Change: Wed Jul 20 16:13:25 EDT 1994 -.\" -.\" bash_builtins, strip all but Built-Ins section [...10701 lines suppressed...] +.PD +.PP +Comments and bug reports concerning +this manual page should be directed to +.IR ch...@in... . +.SH BUGS +.PP +It's too big and too slow. +.PP +There are some subtle differences between +.B bash +and traditional versions of +.BR sh , +mostly because of the +.SM +.B POSIX +specification. +.PP +Aliases are confusing in some uses. +.zZ Index: bash.ps =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/bash.ps,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bash.ps 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ bash.ps 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,3958 +1,3958 @@ -%!PS-Adobe-3.0 -%%Creator: groff version 1.08 -%%DocumentNeededResources: font Times-Roman -%%+ font Times-Bold -%%+ font Times-Italic -%%+ font Symbol -%%DocumentSuppliedResources: procset grops 1.08 0 -%%Pages: 37 -%%PageOrder: Ascend -%%Orientation: Portrait -%%EndComments [...7885 lines suppressed...] +(ep.ai.MIT)-.37 E(.Edu)-.74 E F0 2.001(or posted to the Usenet)4.501 F(ne)108 +160.8 Q(wsgroup)-.25 E F2(gnu.bash.b)2.5 E(ug)-.2 E F0(.)A(ALL b)108 177.6 Q +(ug reports should include:)-.2 E(The v)108 194.4 Q(ersion number of)-.15 E F2 +(bash)2.5 E F0(The hardw)108 206.4 Q(are and operating system)-.1 E +(The compiler used to compile)108 218.4 Q 2.5(Ad)108 230.4 S +(escription of the b)122.72 230.4 Q(ug beha)-.2 E(viour)-.2 E 2.5(As)108 242.4 +S(hort script or `recipe' which e)121.61 242.4 Q -.15(xe)-.15 G(rcises the b) +.15 E(ug)-.2 E(Comments and b)108 259.2 Q +(ug reports concerning this manual page should be directed to)-.2 E F3 -.15(ch) +2.5 G(et@ins.CWR).15 E -.25(U.)-.4 G(Edu).25 E F0(.).25 E F1 -.09(BU)72 276 S +(GS).09 E F0(It')108 288 Q 2.5(st)-.55 G(oo big and too slo)126.06 288 Q -.65 +(w.)-.25 G 1.869(There are some subtle dif)108 304.8 R 1.869(ferences between) +-.25 F F2(bash)4.369 E F0 1.869(and traditional v)4.369 F 1.869(ersions of)-.15 +F F2(sh)4.368 E F0 4.368(,m)C 1.868(ostly because of the)455.246 304.8 R F1 +(POSIX)108 316.8 Q F0(speci\214cation.)2.25 E +(Aliases are confusing in some uses.)108 333.6 Q 186.51(GNU 1995)72 768 R +(Mar 9)2.5 E(37)530 768 Q EP +%%Trailer +end +%%EOF Index: bash.txt =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/bash.txt,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bash.txt 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ bash.txt 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,3960 +1,3960 @@ - - - -BASH(1) USER COMMANDS BASH(1) - - - -NAME - bash - GNU Bourne-Again SHell - -SYNOPSIS [...7889 lines suppressed...] + + + + + + + + + + + + + + + + +GNU Last change: 1994 July 26 60 + + + Index: builtins.1 =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/builtins.1,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- builtins.1 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ builtins.1 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,15 +1,15 @@ -.\" This is a hack to force bash builtins into the whatis database -.\" and to get the list of builtins to come up with the man command. -.TH BASH_BUILTINS 1 "1993 September 16" GNU -.SH NAME -bash, :, ., alias, bg, bind, break, builtin, bye, case, cd, command, -continue, declare, dirs, echo, enable, eval, exec, exit, export, fc, -fg, for, getopts, hash, help, history, if, jobs, kill, let, local, -logout, popd, pushd, pwd, read, readonly, return, set, shift, source, -suspend, test, times, trap, type, typeset, ulimit, umask, unalias, -unset, until, wait, while \- bash built-in commands, see \fBbash\fR(1) -.SH BASH BUILTIN COMMANDS -.nr zZ 1 -.so bash.1 -.SH SEE ALSO -bash(1), sh(1) +.\" This is a hack to force bash builtins into the whatis database +.\" and to get the list of builtins to come up with the man command. +.TH BASH_BUILTINS 1 "1993 September 16" GNU +.SH NAME +bash, :, ., alias, bg, bind, break, builtin, bye, case, cd, command, +continue, declare, dirs, echo, enable, eval, exec, exit, export, fc, +fg, for, getopts, hash, help, history, if, jobs, kill, let, local, +logout, popd, pushd, pwd, read, readonly, return, set, shift, source, +suspend, test, times, trap, type, typeset, ulimit, umask, unalias, +unset, until, wait, while \- bash built-in commands, see \fBbash\fR(1) +.SH BASH BUILTIN COMMANDS +.nr zZ 1 +.so bash.1 +.SH SEE ALSO +bash(1), sh(1) Index: builtins.ps =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/builtins.ps,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- builtins.ps 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ builtins.ps 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,1367 +1,1367 @@ -%!PS-Adobe-3.0 -%%Creator: groff version 1.08 -%%DocumentNeededResources: font Times-Roman -%%+ font Times-Bold -%%+ font Times-Italic -%%+ font Symbol -%%DocumentSuppliedResources: procset grops 1.08 0 -%%Pages: 11 -%%PageOrder: Ascend -%%Orientation: Portrait -%%EndComments [...2703 lines suppressed...] +.328(The e)5.328 F .329(xit status is true)-.15 F(unless a)144 184.8 Q F2(name) +2.5 E F0(does not e)2.5 E(xist or is non-unsettable.)-.15 E F1(wait)108 201.6 Q +F0([)2.5 E F2(n)A F0(])A -.8(Wa)144 213.6 S 1.061 +(it for the speci\214ed process and return its termination status.).8 F F2(n) +6.061 E F0 1.06(may be a process ID or a job)3.56 F .753 +(speci\214cation; if a job spec is gi)144 225.6 R -.15(ve)-.25 G .754 +(n, all processes in that job').15 F 3.254(sp)-.55 G .754(ipeline are w)404.012 +225.6 R .754(aited for)-.1 F 5.754(.I)-.55 G(f)502.458 225.6 Q F2(n)3.254 E F0 +.754(is not)3.254 F(gi)144 237.6 Q -.15(ve)-.25 G .027(n, all currently acti) +.15 F .327 -.15(ve c)-.25 H .027(hild processes are w).15 F .027(aited for)-.1 +F 2.526(,a)-.4 G .026(nd the return status is zero.)375.932 237.6 R(If)5.026 E +F2(n)2.526 E F0(speci\214es)2.526 E 2.595(an)144 249.6 S(on-e)156.035 249.6 Q +.095(xistant process or job, the return status is 127.)-.15 F .096 +(Otherwise, the return status is the e)5.095 F .096(xit status)-.15 F +(of the last process or job w)144 261.6 Q(aited for)-.1 E(.)-.55 E F3(SEE ALSO) +72 278.4 Q F0(bash\(1\), sh\(1\))108 290.4 Q 170.955(GNU 1993)72 768 R +(September 16)2.5 E(11)530 768 Q EP +%%Trailer +end +%%EOF Index: builtins.txt =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/builtins.txt,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- builtins.txt 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ builtins.txt 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,1188 +1,1188 @@ - - - -BASH_BUILTINS(1) USER COMMANDS BASH_BUILTINS(1) - - - -NAME - bash, :, ., alias, bg, bind, break, builtin, bye, case, cd, - command, continue, declare, dirs, echo, enable, eval, exec, - exit, export, fc, fg, for, getopts, hash, help, history, if, [...2345 lines suppressed...] + + + + + + + + + + + + + + + + +GNU Last change: 1993 September 16 18 + + + Index: features.dvi =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/features.dvi,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 Binary files /tmp/cvsNrDx14 and /tmp/cvsUOL0VZ differ Index: features.info =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/features.info,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- features.info 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ features.info 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,3011 +1,3011 @@ -This is Info file features.info, produced by Makeinfo-1.55 from the -input file features.texi. - -This text is a brief description of the features that are present in -the Bash shell. - -This is Edition 1.14, last updated 4 August 1994, -of `The GNU Bash Features Guide', -for `Bash', Version 1.14. - -Copyright (C) 1991, 1993 Free Software Foundation, Inc. [...5991 lines suppressed...] +Node: Readline Movement Commands72104 +Node: Readline Killing Commands72995 +Node: Readline Arguments74698 +Node: Readline Init File75649 +Node: Readline Init Syntax76647 +Node: Conditional Init Constructs83580 +Node: Bindable Readline Commands85826 +Node: Commands For Moving86496 +Node: Commands For History87344 +Node: Commands For Text89988 +Node: Commands For Killing91727 +Node: Numeric Arguments93176 +Node: Commands For Completion93803 +Node: Keyboard Macros94816 +Node: Miscellaneous Commands95375 +Node: Readline vi Mode97466 +Node: Variable Index98343 +Node: Concept Index101671 + +End Tag Table Index: features.ps =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/features.ps,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- features.ps 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ features.ps 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,4279 +1,4279 @@ -%!PS-Adobe-2.0 -%%Creator: dvipsk 5.490s Copyright 1986, 1992 Radical Eye Software -%%Title: features.dvi -%%Pages: 60 1 -%%BoundingBox: 0 0 612 792 -%%EndComments -%DVIPSCommandLine: dvips -D 300 -o features.ps features.dvi -%%BeginProcSet: tex.pro -%! -/TeXDict 250 dict def TeXDict begin /N{def}def /B{bind def}N /S{exch}N /X{S N} -B /TR{translate}N /isls false N /vsize 11 72 mul N /@rigin{isls{[0 -1 1 0 0 0] [...8527 lines suppressed...] +g(Y)l(ou)5 b Fa(:)i(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g +(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)20 b Fl(48)299 1667 +y(7.4.7)44 b(Keyb)q(oard)15 b(Macros)9 b Fa(:)e(:)g(:)h(:)f(:)g(:)g(:)g(:)h +(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g +(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)h(:)f(:)24 b Fl(48)299 +1729 y(7.4.8)44 b(Some)15 b(Miscellaneous)i(Commands)11 b Fa(:)d(:)f(:)g(:)g +(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g +(:)g(:)27 b Fl(49)149 1791 y(7.5)45 b(Readline)17 b(vi)f(Mo)q(de)d +Fa(:)7 b(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g +(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g +(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)27 b Fl(50)0 1916 +y Fj(App)r(endix)d(A)67 b(V)-6 b(ariable)24 b(Index)15 b Fb(:)c(:)f(:)h(:)f +(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)h(:)f(:)g +(:)g(:)g(:)38 b Fj(51)0 2056 y(App)r(endix)24 b(B)67 b(Concept)22 +b(Index)c Fb(:)10 b(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)h(:)f +(:)g(:)g(:)g(:)h(:)f(:)g(:)g(:)h(:)f(:)g(:)39 b Fj(53)p eop +%%Trailer +end +userdict /end-hook known{end-hook}if +%%EOF Index: features.texi =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/features.texi,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- features.texi 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ features.texi 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,1907 +1,1907 @@ -\input texinfo.tex @c -*- texinfo -*- -@c %**start of header -@setfilename features.info -@settitle Bash Features -@c %**end of header - -@ignore -last change: Thu Aug 4 15:21:56 EDT 1994 -@end ignore - -@set EDITION 1.14 [...3783 lines suppressed...] + +@set readline-appendix +@set history-appendix +@cindex History, how to use +@include hsuser.texinfo +@cindex Readline, how to use +@include rluser.texinfo +@clear readline-appendix +@clear history-appendix + +@node Variable Index +@appendix Variable Index +@printindex vr + +@node Concept Index +@appendix Concept Index +@printindex cp + +@contents +@bye Index: readline.3 =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/readline.3,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- readline.3 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ readline.3 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,1218 +1,1218 @@ -.\" -.\" MAN PAGE COMMENTS to -.\" -.\" Chet Ramey -.\" Information Network Services -.\" Case Western Reserve University -.\" ch...@in... -.\" -.\" Last Change: Wed Jul 20 16:13:11 EDT 1994 -.\" -.TH READLINE 3 "1994 July 26" GNU [...2405 lines suppressed...] +you should report it. But first, you should +make sure that it really is a bug, and that it appears in the latest +version of the +.B readline +library that you have. +.PP +Once you have determined that a bug actually exists, mail a +bug report to \fIbash\-maintainers\fP@\fIprep.ai.MIT.Edu\fP. +If you have a fix, you are welcome to mail that +as well! Suggestions and `philosophical' bug reports may be mailed +to \fPbug-bash\fP@\fIprep.ai.MIT.Edu\fP or posted to the Usenet +newsgroup +.BR gnu.bash.bug . +.PP +Comments and bug reports concerning +this manual page should be directed to +.IR ch...@in... . +.SH BUGS +.PP +It's too big and too slow. Index: readline.ps =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/readline.ps,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- readline.ps 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ readline.ps 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,1052 +1,1052 @@ -%!PS-Adobe-3.0 -%%Creator: groff version 1.08 -%%DocumentNeededResources: font Times-Roman -%%+ font Times-Bold -%%+ font Times-Italic -%%DocumentSuppliedResources: procset grops 1.08 0 -%%Pages: 12 -%%PageOrder: Ascend -%%Orientation: Portrait -%%EndComments -%%BeginProlog [...2073 lines suppressed...] +(But \214rst, you should mak)5.69 F 3.19(es)-.1 G .69 +(ure that it really is a b)436.35 516 R(ug,)-.2 E +(and that it appears in the latest v)108 528 Q(ersion of the)-.15 E F3 -.18(re) +2.5 G(adline).18 E F0(library that you ha)2.5 E -.15(ve)-.2 G(.).15 E 10.782 +(Once you ha)108 544.8 R 11.082 -.15(ve d)-.2 H 10.782(etermined that a b).15 F +10.782(ug actually e)-.2 F 10.783(xists, mail a b)-.15 F 10.783(ug report to) +-.2 F F2(bash\255maintainer)108 556.8 Q(s)-.1 E F0(@)A F2(pr)A(ep.ai.MIT)-.37 E +(.Edu)-.74 E F0 5.169(.I)C 2.669(fy)267.359 556.8 S .169(ou ha)278.358 556.8 R +.469 -.15(ve a \214)-.2 H .168(x, you are welcome to mail that as well!).15 F +(Suggestions)5.168 E 2(and `philosophical' b)108 568.8 R 2.001 +(ug reports may be mailed to)-.2 F F2 -.2(bu)4.501 G(g-bash).2 E F0(@)A F2(pr)A +(ep.ai.MIT)-.37 E(.Edu)-.74 E F0 2.001(or posted to the Usenet)4.501 F(ne)108 +580.8 Q(wsgroup)-.25 E F3(gnu.bash.b)2.5 E(ug)-.2 E F0(.)A(Comments and b)108 +597.6 Q(ug reports concerning this manual page should be directed to)-.2 E F2 +-.15(ch)2.5 G(et@ins.CWR).15 E -.25(U.)-.4 G(Edu).25 E F0(.).25 E F1 -.09(BU)72 +614.4 S(GS).09 E F0(It')108 626.4 Q 2.5(st)-.55 G(oo big and too slo)126.06 +626.4 Q -.65(w.)-.25 G 184.005(GNU 1994)72 768 R(July 26)2.5 E(12)530 768 Q EP +%%Trailer +end +%%EOF Index: readline.txt =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/readline.txt,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- readline.txt 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ readline.txt 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,1122 +1,1122 @@ - - - -READLINE(3) C LIBRARY FUNCTIONS READLINE(3) - - - -NAME - readline - get a line from a user with editing - -SYNOPSIS [...2213 lines suppressed...] + + + + + + + + + + + + + + + + +GNU Last change: 1994 July 26 17 + + + Index: texinfo.tex =================================================================== RCS file: /cvsroot/winbash/winbash/documentation/texinfo.tex,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- texinfo.tex 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ texinfo.tex 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,4003 +1,4003 @@ -%% TeX macros to handle texinfo files - -% Copyright (C) 1985, 86, 88, 90, 91, 92, 1993 Free Software Foundation, Inc. - -%This texinfo.tex file is free software; you can redistribute it and/or -%modify it under the terms of the GNU General Public License as -%published by the Free Software Foundation; either version 2, or (at -%your option) any later version. - -%This texinfo.tex file is distributed in the hope that it will be -%useful, but WITHOUT ANY WARRANTY; without even the implied warranty [...7975 lines suppressed...] +% +@gdef@eatinput input texinfo{@fixbackslash} +@global@let\ = @eatinput + +% On the other hand, perhaps the file did not have a `\input texinfo'. Then +% the first `\{ in the file would cause an error. This macro tries to fix +% that, assuming it is called before the first `\' could plausibly occur. +% +@gdef@fixbackslash{@ifx\@eatinput @let\ = @normalbackslash @fi} + +%% These look ok in all fonts, so just make them not special. The @rm below +%% makes sure that the current font starts out as the newly loaded cmr10 +@catcode`@$=@other @catcode`@%=@other @catcode`@&=@other @catcode`@#=@other + +@textfonts +@rm + +@c Local variables: +@c page-delimiter: "^\\\\message" +@c End: |
Update of /cvsroot/winbash/winbash/tests In directory usw-pr-cvs1:/tmp/cvs-serv381/tests Modified Files: README dollar-at.sh dollar-star.sh dollar.right exp-tests exp.right getopts.sh glob-test glob.right ifs-test-1.sh ifs-test-2.sh ifs-test-3.sh ifs.1.right ifs.2.right ifs.3.right input-line.sh input-line.sub input.right minus-e minus-e.right new-exp.right new-exp.tests prec.right precedence run-all run-dollars run-exp-tests run-glob-test run-ifs-tests run-input-test run-minus-e run-new-exp run-precedence run-set-e-test run-strip run-varenv set-e-test set-e.right strip.right strip.tests tilde-tests tilde.right varenv.right varenv.sh x xx Log Message: Fixed more cr/lf problems. Index: README =================================================================== RCS file: /cvsroot/winbash/winbash/tests/README,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- README 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ README 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -Type `sh run-all'. +Type `sh run-all'. Index: dollar-at.sh =================================================================== RCS file: /cvsroot/winbash/winbash/tests/dollar-at.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- dollar-at.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ dollar-at.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -recho "$@" +recho "$@" Index: dollar-star.sh =================================================================== RCS file: /cvsroot/winbash/winbash/tests/dollar-star.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- dollar-star.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ dollar-star.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -recho "$*" +recho "$*" Index: dollar.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/dollar.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- dollar.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ dollar.right 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,3 +1,3 @@ -argv[1] = <a b> -argv[1] = <a> -argv[2] = <b> +argv[1] = <a b> +argv[1] = <a> +argv[2] = <b> Index: exp-tests =================================================================== RCS file: /cvsroot/winbash/winbash/tests/exp-tests,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- exp-tests 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ exp-tests 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,326 +1,326 @@ -# -# A suite of tests for bash word expansions -# -# This tests parameter and variable expansion, with an empahsis on -# proper quoting behavior. -# -# Chet Ramey - -# -# If you comment out the body of this function, you can do a diff against -# `expansion-tests.right' to see if the shell is behaving correctly -# -expect() -{ - echo expect "$@" -} - -# Test the substitution quoting characters (CTLESC and CTLNUL) in different -# combinations - -expect "<^A>" -recho `echo ''` -expect "<^A>" -recho `echo ""` -expect "<^B>" -recho `echo ''` -expect "<^B>" -recho `echo ""` -expect "<^A>" -recho `echo ` -expect "<^B>" -recho `echo ` - -# Test null strings without variable expansion -expect "<abcdefgh>" -recho abcd""efgh -expect "<abcdefgh>" -recho abcd''efgh -expect "<abcdefgh>" -recho ""abcdefgh -expect "<abcdefgh>" -recho ''abcdefgh -expect "<abcd>" -recho abcd"" -expect "<abcd>" -recho abcd'' - -# Test the quirky behavior of $@ in "" -expect nothing -recho "$@" -expect "< >" -recho " $@" -expect "<-->" -recho "-${@}-" - -# Test null strings with variable expansion that fails -expect '<>' -recho $xxx"" -expect '<>' -recho ""$xxx -expect '<>' -recho $xxx'' -expect '<>' -recho ''$xxx -expect '<>' -recho $xxx""$yyy -expect '<>' -recho $xxx''$yyy - -# Test null strings with variable expansion that succeeds -xxx=abc -yyy=def - -expect '<abc>' -recho $xxx"" -expect '<abc>' -recho ""$xxx -expect '<abc>' -recho $xxx'' -expect '<abc>' -recho ''$xxx -expect '<abcdef>' -recho $xxx""$yyy -expect '<abcdef>' -recho $xxx''$yyy - -unset xxx yyy - -# Test the unquoted special quoting characters -expect "<^A>" -recho -expect "<^B>" -recho -expect "<^A>" -recho "" -expect "<^B>" -recho "" -expect "<^A>" -recho '' -expect "<^B>" -recho '' - -# Test expansion of a variable that is unset -expect nothing -recho $xxx -expect '<>' -recho "$xxx" - -expect nothing -recho "$xxx${@}" - -# Test empty string expansion -expect '<>' -recho "" -expect '<>' -recho '' - -# Test command substitution with (disabled) history substitution -expect '<Hello World!>' -# set +H -recho "`echo \"Hello world!\"`" - -# Test some shell special characters -expect '<`>' -recho "\`" -expect '<">' -recho "\"" -expect '<\^A>' -recho "\" - -expect '<\$>' -recho "\\$" - -expect '<\\>' -recho "\\\\" - -# This should give argv[1] = a argv[2] = b -expect '<a> <b>' -FOO=`echo 'a b' | tr ' ' '\012'` -recho $FOO - -# This should give argv[1] = ^A argv[2] = ^B -expect '<^A> <^B>' -FOO=`echo ' ' | tr ' ' '\012'` -recho $FOO - -# Test quoted and unquoted globbing characters -expect '<**>' -recho "*"* - -expect '<\.\./*/>' -recho "\.\./*/" - -# Test patterns that come up when the shell quotes funny character -# combinations -expect '<^A^B^A^B>' -recho '' -expect '<^A^A>' -recho '' -expect '<^A^B>' -recho '' -expect '<^A^A^B>' -recho '' - -# More tests of "$@" -expect '< abc> <def> <ghi> <jkl >' -set abc def ghi jkl -recho " $@ " - -expect '<--abc> <def> <ghi> <jkl-->' -set abc def ghi jkl -recho "--$@--" - -expect '< >' -recho " " -expect '< - >' -recho " - " - -# Test combinations of different types of quoting in a fully-quoted string -# (so the WHOLLY_QUOTED tests fail and it doesn't get set) -expect '</^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/>' -recho "/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*"'$'"/\1/" - -# Test the various Posix parameter expansions - -expect '<foo bar>' -recho "${x:-$(echo "foo bar")}" -expect '<foo> <bar>' -recho ${x:-$(echo "foo bar")} - -unset X -expect '<abc>' -recho ${X:=abc} -expect '<abc>' -recho $X - -set a b c -expect '<posix>' -recho ${3:+posix} - -POSIX=/usr/posix -expect '<10>' -recho ${#POSIX} - -# remove shortest trailing match -x=file.c -expect '<file.o>' -recho ${x%.c}.o - -# remove longest trailing match -x=posix/src/std -expect '<posix>' -recho ${x%%/*} - -# remove shortest leading pattern -x=$HOME/src/cmd -expect '</src/cmd>' -recho ${x#$HOME} - -# remove longest leading pattern -x=/one/two/three -expect '<three>' -recho ${x##*/} - -# Command substitution and the quirky differences between `` and $() - -expect '<\$x>' -recho '\$x' - -expect '<$x>' -recho `echo '\$x'` - -expect '<\$x>' -recho $(echo '\$x') - -# The difference between $* "$*" and "$@" - -set "abc" "def ghi" "jkl" - -expect '<abc> <def> <ghi> <jkl>' -recho $* - -expect '<abc def ghi jkl>' -recho "$*" - -OIFS="$IFS" -IFS=":$IFS" - -# The special behavior of "$*", using the first character of $IFS as separator -expect '<abc:def ghi:jkl>' -recho "$*" - -IFS="$OIFS" - -expect '<abc> <def ghi> <jkl>' -recho "$@" - -expect '<xxabc> <def ghi> <jklyy>' -recho "xx$@yy" - -expect '<abc> <def ghi> <jklabc> <def ghi> <jkl>' -recho "$@$@" - -foo=abc -bar=def - -expect '<abcdef>' -recho "$foo""$bar" - -unset foo -set $foo bar '' xyz "$foo" abc - -expect '<bar> <> <xyz> <> <abc>' -recho "$@" - -# More tests of quoting and deferred evaluation - -foo=10 x=foo -y='$'$x -expect '<$foo>' -recho $y -eval y='$'$x -expect '<10>' -recho $y - -# case statements - -NL=' -' -x='ab -cd' - -expect '<newline expected>' -case "$x" in -*$NL*) recho "newline expected" ;; -esac - -expect '<got it>' -case \? in -*"?"*) recho "got it" ;; -esac - -expect '<got it>' -case \? in -*\?*) recho "got it" ;; -esac - -set one two three four five -expect '<one> <three> <five>' -recho $1 $3 ${5} $8 ${9} -expect '<5> <5>' -recho $# ${#} - -expect '<42>' -recho $((28 + 14)) -expect '<26>' -recho $[ 13 * 2 ] - -expect '<\>' -recho `echo \\\\` - -expect '<~>' -recho '~' - -expect nothing -recho $! +# +# A suite of tests for bash word expansions +# +# This tests parameter and variable expansion, with an empahsis on +# proper quoting behavior. +# +# Chet Ramey + +# +# If you comment out the body of this function, you can do a diff against +# `expansion-tests.right' to see if the shell is behaving correctly +# +expect() +{ + echo expect "$@" +} + +# Test the substitution quoting characters (CTLESC and CTLNUL) in different +# combinations + +expect "<^A>" +recho `echo ''` +expect "<^A>" +recho `echo ""` +expect "<^B>" +recho `echo ''` +expect "<^B>" +recho `echo ""` +expect "<^A>" +recho `echo ` +expect "<^B>" +recho `echo ` + +# Test null strings without variable expansion +expect "<abcdefgh>" +recho abcd""efgh +expect "<abcdefgh>" +recho abcd''efgh +expect "<abcdefgh>" +recho ""abcdefgh +expect "<abcdefgh>" +recho ''abcdefgh +expect "<abcd>" +recho abcd"" +expect "<abcd>" +recho abcd'' + +# Test the quirky behavior of $@ in "" +expect nothing +recho "$@" +expect "< >" +recho " $@" +expect "<-->" +recho "-${@}-" + +# Test null strings with variable expansion that fails +expect '<>' +recho $xxx"" +expect '<>' +recho ""$xxx +expect '<>' +recho $xxx'' +expect '<>' +recho ''$xxx +expect '<>' +recho $xxx""$yyy +expect '<>' +recho $xxx''$yyy + +# Test null strings with variable expansion that succeeds +xxx=abc +yyy=def + +expect '<abc>' +recho $xxx"" +expect '<abc>' +recho ""$xxx +expect '<abc>' +recho $xxx'' +expect '<abc>' +recho ''$xxx +expect '<abcdef>' +recho $xxx""$yyy +expect '<abcdef>' +recho $xxx''$yyy + +unset xxx yyy + +# Test the unquoted special quoting characters +expect "<^A>" +recho +expect "<^B>" +recho +expect "<^A>" +recho "" +expect "<^B>" +recho "" +expect "<^A>" +recho '' +expect "<^B>" +recho '' + +# Test expansion of a variable that is unset +expect nothing +recho $xxx +expect '<>' +recho "$xxx" + +expect nothing +recho "$xxx${@}" + +# Test empty string expansion +expect '<>' +recho "" +expect '<>' +recho '' + +# Test command substitution with (disabled) history substitution +expect '<Hello World!>' +# set +H +recho "`echo \"Hello world!\"`" + +# Test some shell special characters +expect '<`>' +recho "\`" +expect '<">' +recho "\"" +expect '<\^A>' +recho "\" + +expect '<\$>' +recho "\\$" + +expect '<\\>' +recho "\\\\" + +# This should give argv[1] = a argv[2] = b +expect '<a> <b>' +FOO=`echo 'a b' | tr ' ' '\012'` +recho $FOO + +# This should give argv[1] = ^A argv[2] = ^B +expect '<^A> <^B>' +FOO=`echo ' ' | tr ' ' '\012'` +recho $FOO + +# Test quoted and unquoted globbing characters +expect '<**>' +recho "*"* + +expect '<\.\./*/>' +recho "\.\./*/" + +# Test patterns that come up when the shell quotes funny character +# combinations +expect '<^A^B^A^B>' +recho '' +expect '<^A^A>' +recho '' +expect '<^A^B>' +recho '' +expect '<^A^A^B>' +recho '' + +# More tests of "$@" +expect '< abc> <def> <ghi> <jkl >' +set abc def ghi jkl +recho " $@ " + +expect '<--abc> <def> <ghi> <jkl-->' +set abc def ghi jkl +recho "--$@--" + +expect '< >' +recho " " +expect '< - >' +recho " - " + +# Test combinations of different types of quoting in a fully-quoted string +# (so the WHOLLY_QUOTED tests fail and it doesn't get set) +expect '</^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/>' +recho "/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*"'$'"/\1/" + +# Test the various Posix parameter expansions + +expect '<foo bar>' +recho "${x:-$(echo "foo bar")}" +expect '<foo> <bar>' +recho ${x:-$(echo "foo bar")} + +unset X +expect '<abc>' +recho ${X:=abc} +expect '<abc>' +recho $X + +set a b c +expect '<posix>' +recho ${3:+posix} + +POSIX=/usr/posix +expect '<10>' +recho ${#POSIX} + +# remove shortest trailing match +x=file.c +expect '<file.o>' +recho ${x%.c}.o + +# remove longest trailing match +x=posix/src/std +expect '<posix>' +recho ${x%%/*} + +# remove shortest leading pattern +x=$HOME/src/cmd +expect '</src/cmd>' +recho ${x#$HOME} + +# remove longest leading pattern +x=/one/two/three +expect '<three>' +recho ${x##*/} + +# Command substitution and the quirky differences between `` and $() + +expect '<\$x>' +recho '\$x' + +expect '<$x>' +recho `echo '\$x'` + +expect '<\$x>' +recho $(echo '\$x') + +# The difference between $* "$*" and "$@" + +set "abc" "def ghi" "jkl" + +expect '<abc> <def> <ghi> <jkl>' +recho $* + +expect '<abc def ghi jkl>' +recho "$*" + +OIFS="$IFS" +IFS=":$IFS" + +# The special behavior of "$*", using the first character of $IFS as separator +expect '<abc:def ghi:jkl>' +recho "$*" + +IFS="$OIFS" + +expect '<abc> <def ghi> <jkl>' +recho "$@" + +expect '<xxabc> <def ghi> <jklyy>' +recho "xx$@yy" + +expect '<abc> <def ghi> <jklabc> <def ghi> <jkl>' +recho "$@$@" + +foo=abc +bar=def + +expect '<abcdef>' +recho "$foo""$bar" + +unset foo +set $foo bar '' xyz "$foo" abc + +expect '<bar> <> <xyz> <> <abc>' +recho "$@" + +# More tests of quoting and deferred evaluation + +foo=10 x=foo +y='$'$x +expect '<$foo>' +recho $y +eval y='$'$x +expect '<10>' +recho $y + +# case statements + +NL=' +' +x='ab +cd' + +expect '<newline expected>' +case "$x" in +*$NL*) recho "newline expected" ;; +esac + +expect '<got it>' +case \? in +*"?"*) recho "got it" ;; +esac + +expect '<got it>' +case \? in +*\?*) recho "got it" ;; +esac + +set one two three four five +expect '<one> <three> <five>' +recho $1 $3 ${5} $8 ${9} +expect '<5> <5>' +recho $# ${#} + +expect '<42>' +recho $((28 + 14)) +expect '<26>' +recho $[ 13 * 2 ] + +expect '<\>' +recho `echo \\\\` + +expect '<~>' +recho '~' + +expect nothing +recho $! Index: exp.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/exp.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- exp.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ exp.right 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,113 +1,113 @@ -argv[1] = <^A> -argv[1] = <^A> -argv[1] = <^B> -argv[1] = <^B> -argv[1] = <^A> -argv[1] = <^B> -argv[1] = <abcdefgh> -argv[1] = <abcdefgh> -argv[1] = <abcdefgh> -argv[1] = <abcdefgh> -argv[1] = <abcd> -argv[1] = <abcd> -argv[1] = < > -argv[1] = <--> -argv[1] = <> -argv[1] = <> -argv[1] = <> -argv[1] = <> -argv[1] = <> -argv[1] = <> -argv[1] = <abc> -argv[1] = <abc> -argv[1] = <abc> -argv[1] = <abc> -argv[1] = <abcdef> -argv[1] = <abcdef> -argv[1] = <^A> -argv[1] = <^B> -argv[1] = <^A> -argv[1] = <^B> -argv[1] = <^A> -argv[1] = <^B> -argv[1] = <> -argv[1] = <> -argv[1] = <> -argv[1] = <Hello world!> -argv[1] = <`> -argv[1] = <"> -argv[1] = <\^A> -argv[1] = <\$> -argv[1] = <\\> -argv[1] = <a> -argv[2] = <b> -argv[1] = <^A> -argv[2] = <^B> -argv[1] = <**> -argv[1] = <\.\./*/> -argv[1] = <^A^B^A^B> -argv[1] = <^A^A> -argv[1] = <^A^B> -argv[1] = <^A^A^B> -argv[1] = < abc> -argv[2] = <def> -argv[3] = <ghi> -argv[4] = <jkl > -argv[1] = <--abc> -argv[2] = <def> -argv[3] = <ghi> -argv[4] = <jkl--> -argv[1] = < > -argv[1] = < - > -argv[1] = </^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/> -argv[1] = <foo bar> -argv[1] = <foo> -argv[2] = <bar> -argv[1] = <abc> -argv[1] = <abc> -argv[1] = <posix> -argv[1] = <10> -argv[1] = <file.o> -argv[1] = <posix> -argv[1] = </src/cmd> -argv[1] = <three> -argv[1] = <\$x> -argv[1] = <$x> -argv[1] = <\$x> -argv[1] = <abc> -argv[2] = <def> -argv[3] = <ghi> -argv[4] = <jkl> -argv[1] = <abc def ghi jkl> -argv[1] = <abc:def ghi:jkl> -argv[1] = <abc> -argv[2] = <def ghi> -argv[3] = <jkl> -argv[1] = <xxabc> -argv[2] = <def ghi> -argv[3] = <jklyy> -argv[1] = <abc> -argv[2] = <def ghi> -argv[3] = <jklabc> -argv[4] = <def ghi> -argv[5] = <jkl> -argv[1] = <abcdef> -argv[1] = <bar> -argv[2] = <> -argv[3] = <xyz> -argv[4] = <> -argv[5] = <abc> -argv[1] = <$foo> -argv[1] = <10> -argv[1] = <newline expected> -argv[1] = <got it> -argv[1] = <got it> -argv[1] = <one> -argv[2] = <three> -argv[3] = <five> -argv[1] = <5> -argv[2] = <5> -argv[1] = <42> -argv[1] = <26> -argv[1] = <\> -argv[1] = <~> +argv[1] = <^A> +argv[1] = <^A> +argv[1] = <^B> +argv[1] = <^B> +argv[1] = <^A> +argv[1] = <^B> +argv[1] = <abcdefgh> +argv[1] = <abcdefgh> +argv[1] = <abcdefgh> +argv[1] = <abcdefgh> +argv[1] = <abcd> +argv[1] = <abcd> +argv[1] = < > +argv[1] = <--> +argv[1] = <> +argv[1] = <> +argv[1] = <> +argv[1] = <> +argv[1] = <> +argv[1] = <> +argv[1] = <abc> +argv[1] = <abc> +argv[1] = <abc> +argv[1] = <abc> +argv[1] = <abcdef> +argv[1] = <abcdef> +argv[1] = <^A> +argv[1] = <^B> +argv[1] = <^A> +argv[1] = <^B> +argv[1] = <^A> +argv[1] = <^B> +argv[1] = <> +argv[1] = <> +argv[1] = <> +argv[1] = <Hello world!> +argv[1] = <`> +argv[1] = <"> +argv[1] = <\^A> +argv[1] = <\$> +argv[1] = <\\> +argv[1] = <a> +argv[2] = <b> +argv[1] = <^A> +argv[2] = <^B> +argv[1] = <**> +argv[1] = <\.\./*/> +argv[1] = <^A^B^A^B> +argv[1] = <^A^A> +argv[1] = <^A^B> +argv[1] = <^A^A^B> +argv[1] = < abc> +argv[2] = <def> +argv[3] = <ghi> +argv[4] = <jkl > +argv[1] = <--abc> +argv[2] = <def> +argv[3] = <ghi> +argv[4] = <jkl--> +argv[1] = < > +argv[1] = < - > +argv[1] = </^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/> +argv[1] = <foo bar> +argv[1] = <foo> +argv[2] = <bar> +argv[1] = <abc> +argv[1] = <abc> +argv[1] = <posix> +argv[1] = <10> +argv[1] = <file.o> +argv[1] = <posix> +argv[1] = </src/cmd> +argv[1] = <three> +argv[1] = <\$x> +argv[1] = <$x> +argv[1] = <\$x> +argv[1] = <abc> +argv[2] = <def> +argv[3] = <ghi> +argv[4] = <jkl> +argv[1] = <abc def ghi jkl> +argv[1] = <abc:def ghi:jkl> +argv[1] = <abc> +argv[2] = <def ghi> +argv[3] = <jkl> +argv[1] = <xxabc> +argv[2] = <def ghi> +argv[3] = <jklyy> +argv[1] = <abc> +argv[2] = <def ghi> +argv[3] = <jklabc> +argv[4] = <def ghi> +argv[5] = <jkl> +argv[1] = <abcdef> +argv[1] = <bar> +argv[2] = <> +argv[3] = <xyz> +argv[4] = <> +argv[5] = <abc> +argv[1] = <$foo> +argv[1] = <10> +argv[1] = <newline expected> +argv[1] = <got it> +argv[1] = <got it> +argv[1] = <one> +argv[2] = <three> +argv[3] = <five> +argv[1] = <5> +argv[2] = <5> +argv[1] = <42> +argv[1] = <26> +argv[1] = <\> +argv[1] = <~> Index: getopts.sh =================================================================== RCS file: /cvsroot/winbash/winbash/tests/getopts.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- getopts.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ getopts.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,23 +1,23 @@ -# test getopts parsing -testit() -{ - while getopts :a:b:c:d:e:f:g:h:i:j:k:l: opt; do - case $opt in - a) ORACLE_HOME="$OPTARG";; - b) ORASERVICE="$OPTARG";; - c) DBA_USER="$OPTARG";; - d) DBA_PW="$OPTARG";; - e) DB_USER="$OPTARG";; - f) DB_PASSWD="$OPTARG";; - g) DB_REPORT_USER="$OPTARG";; - h) DB_REPORT_PASSWD="$OPTARG";; - i) APPKEY="$OPTARG";; - j) DB_SIZE_PARAM="$OPTARG";; - k) DB_DATAFILE_HOME="$OPTARG";; - l) DB_INDEXFILE_HOME="$OPTARG";; - \?) echo "unknown option -$OPTARG" && exit 1;; - esac - done -} - -testit -a foo -b bar -c hey -d ra -e top +# test getopts parsing +testit() +{ + while getopts :a:b:c:d:e:f:g:h:i:j:k:l: opt; do + case $opt in + a) ORACLE_HOME="$OPTARG";; + b) ORASERVICE="$OPTARG";; + c) DBA_USER="$OPTARG";; + d) DBA_PW="$OPTARG";; + e) DB_USER="$OPTARG";; + f) DB_PASSWD="$OPTARG";; + g) DB_REPORT_USER="$OPTARG";; + h) DB_REPORT_PASSWD="$OPTARG";; + i) APPKEY="$OPTARG";; + j) DB_SIZE_PARAM="$OPTARG";; + k) DB_DATAFILE_HOME="$OPTARG";; + l) DB_INDEXFILE_HOME="$OPTARG";; + \?) echo "unknown option -$OPTARG" && exit 1;; + esac + done +} + +testit -a foo -b bar -c hey -d ra -e top Index: glob-test =================================================================== RCS file: /cvsroot/winbash/winbash/tests/glob-test,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- glob-test 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ glob-test 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,178 +1,178 @@ -# -# test the shell globbing -# -expect() -{ - echo expect "$@" -} - -TESTDIR=/tmp/glob-test -mkdir $TESTDIR -cd $TESTDIR - -touch a b c d abc abd abe bb bcd ca cb dd de -mkdir bdir - -# see if `regular' globbing works right -expect '<a> <abc> <abd> <abe> <X*>' -recho a* X* - -expect '<a> <abc> <abd> <abe>' -recho \a* - -# see if null glob expansion works -allow_null_glob_expansion= - -expect '<a> <abc> <abd> <abe>' -recho a* X* - -unset allow_null_glob_expansion - -# see if the code that expands directories only works -expect '<bdir/>' -recho b*/ - -# Test quoted and unquoted globbing characters -expect '<*>' -recho \* - -expect '<a*>' -recho 'a*' - -expect '<a*>' -recho a\* - -expect '<c> <ca> <cb> <a*> <*q*>' -recho c* a\* *q* - -expect '<**>' -recho "*"* - -expect '<**>' -recho \** - -expect '<\.\./*/>' -recho "\.\./*/" - -expect '<s/\..*//>' -recho 's/\..*//' - -# Pattern from Larry Wall's Configure that caused bash to blow up -expect '</^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/>' -recho "/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*"'$'"/\1/" - -# Make sure character classes work properly - -expect '<abc> <abd> <abe> <bb> <cb>' -recho [a-c]b* - -expect '<abd> <abe> <bb> <bcd> <bdir> <ca> <cb> <dd> <de>' -recho [a-y]*[^c] - -expect '<abd> <abe>' -recho a*[^c] - -touch a-b aXb -expect '<a-b> <aXb>' -recho a[X-]b - -touch .x .y -expect '<d> <dd> <de>' -recho [^a-c]* - -# Make sure that filenames with embedded globbing characters are handled -# properly -mkdir a\*b -> a\*b/ooo - -expect '<a*b/ooo>' -recho a\*b/* - -expect '<a*b/ooo>' -recho a\*?/* - -expect '<no match>' -cmd='echo !7' -case "$cmd" in -*\\!*) echo match ;; -*) echo no match ;; -esac - -expect '<not there>' -file='r.*' -case $file in -*.\*) echo not there ;; -*) echo there ;; -esac - -# examples from the Posix.2 spec (d11.2, p. 243) -expect '<abc>' -recho a[b]c - -expect '<abc>' -recho a["b"]c - -expect '<abc>' -recho a[\b]c - -expect '<abc>' -recho a?c - -expect '<match>' -case abc in -a"b"c) echo match - ;; -*) echo BAD - ;; -esac - -expect '<match>' -case abc in -a*c) echo match - ;; -*) echo BAD - ;; -esac - -expect '<ok>' -case abc in -"a?c") echo bad - ;; -*) echo ok - ;; -esac - -expect '<ok>' -case abc in -a\*c) echo bad - ;; -*) echo ok - ;; -esac - -expect '<ok>' -case abc in -a\[b]c) echo bad - ;; -*) echo ok - ;; -esac - -expect '<ok>' -case "$nosuchvar" in -"") echo ok ;; -*) echo bad ;; -esac - -# This is very odd, but sh and ksh seem to agree -expect '<ok>' -case abc in -a["\b"]c) echo ok - ;; -*) echo bad - ;; -esac - -cd / -/bin/rm -rf $TESTDIR -exit 0 +# +# test the shell globbing +# +expect() +{ + echo expect "$@" +} + +TESTDIR=/tmp/glob-test +mkdir $TESTDIR +cd $TESTDIR + +touch a b c d abc abd abe bb bcd ca cb dd de +mkdir bdir + +# see if `regular' globbing works right +expect '<a> <abc> <abd> <abe> <X*>' +recho a* X* + +expect '<a> <abc> <abd> <abe>' +recho \a* + +# see if null glob expansion works +allow_null_glob_expansion= + +expect '<a> <abc> <abd> <abe>' +recho a* X* + +unset allow_null_glob_expansion + +# see if the code that expands directories only works +expect '<bdir/>' +recho b*/ + +# Test quoted and unquoted globbing characters +expect '<*>' +recho \* + +expect '<a*>' +recho 'a*' + +expect '<a*>' +recho a\* + +expect '<c> <ca> <cb> <a*> <*q*>' +recho c* a\* *q* + +expect '<**>' +recho "*"* + +expect '<**>' +recho \** + +expect '<\.\./*/>' +recho "\.\./*/" + +expect '<s/\..*//>' +recho 's/\..*//' + +# Pattern from Larry Wall's Configure that caused bash to blow up +expect '</^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/>' +recho "/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*"'$'"/\1/" + +# Make sure character classes work properly + +expect '<abc> <abd> <abe> <bb> <cb>' +recho [a-c]b* + +expect '<abd> <abe> <bb> <bcd> <bdir> <ca> <cb> <dd> <de>' +recho [a-y]*[^c] + +expect '<abd> <abe>' +recho a*[^c] + +touch a-b aXb +expect '<a-b> <aXb>' +recho a[X-]b + +touch .x .y +expect '<d> <dd> <de>' +recho [^a-c]* + +# Make sure that filenames with embedded globbing characters are handled +# properly +mkdir a\*b +> a\*b/ooo + +expect '<a*b/ooo>' +recho a\*b/* + +expect '<a*b/ooo>' +recho a\*?/* + +expect '<no match>' +cmd='echo !7' +case "$cmd" in +*\\!*) echo match ;; +*) echo no match ;; +esac + +expect '<not there>' +file='r.*' +case $file in +*.\*) echo not there ;; +*) echo there ;; +esac + +# examples from the Posix.2 spec (d11.2, p. 243) +expect '<abc>' +recho a[b]c + +expect '<abc>' +recho a["b"]c + +expect '<abc>' +recho a[\b]c + +expect '<abc>' +recho a?c + +expect '<match>' +case abc in +a"b"c) echo match + ;; +*) echo BAD + ;; +esac + +expect '<match>' +case abc in +a*c) echo match + ;; +*) echo BAD + ;; +esac + +expect '<ok>' +case abc in +"a?c") echo bad + ;; +*) echo ok + ;; +esac + +expect '<ok>' +case abc in +a\*c) echo bad + ;; +*) echo ok + ;; +esac + +expect '<ok>' +case abc in +a\[b]c) echo bad + ;; +*) echo ok + ;; +esac + +expect '<ok>' +case "$nosuchvar" in +"") echo ok ;; +*) echo bad ;; +esac + +# This is very odd, but sh and ksh seem to agree +expect '<ok>' +case abc in +a["\b"]c) echo ok + ;; +*) echo bad + ;; +esac + +cd / +/bin/rm -rf $TESTDIR +exit 0 Index: glob.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/glob.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- glob.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ glob.right 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,63 +1,63 @@ -argv[1] = <a> -argv[2] = <abc> -argv[3] = <abd> -argv[4] = <abe> -argv[5] = <X*> -argv[1] = <a> -argv[2] = <abc> -argv[3] = <abd> -argv[4] = <abe> -argv[1] = <a> -argv[2] = <abc> -argv[3] = <abd> -argv[4] = <abe> -argv[1] = <bdir/> -argv[1] = <*> -argv[1] = <a*> -argv[1] = <a*> -argv[1] = <c> -argv[2] = <ca> -argv[3] = <cb> -argv[4] = <a*> -argv[5] = <*q*> -argv[1] = <**> -argv[1] = <**> -argv[1] = <\.\./*/> -argv[1] = <s/\..*//> -argv[1] = </^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/> -argv[1] = <abc> -argv[2] = <abd> -argv[3] = <abe> -argv[4] = <bb> -argv[5] = <cb> -argv[1] = <abd> -argv[2] = <abe> -argv[3] = <bb> -argv[4] = <bcd> -argv[5] = <bdir> -argv[6] = <ca> -argv[7] = <cb> -argv[8] = <dd> -argv[9] = <de> -argv[1] = <abd> -argv[2] = <abe> -argv[1] = <a-b> -argv[2] = <aXb> -argv[1] = <d> -argv[2] = <dd> -argv[3] = <de> -argv[1] = <a*b/ooo> -argv[1] = <a*b/ooo> -no match -not there -argv[1] = <abc> -argv[1] = <abc> -argv[1] = <abc> -argv[1] = <abc> -match -match -ok -ok -ok -ok -ok +argv[1] = <a> +argv[2] = <abc> +argv[3] = <abd> +argv[4] = <abe> +argv[5] = <X*> +argv[1] = <a> +argv[2] = <abc> +argv[3] = <abd> +argv[4] = <abe> +argv[1] = <a> +argv[2] = <abc> +argv[3] = <abd> +argv[4] = <abe> +argv[1] = <bdir/> +argv[1] = <*> +argv[1] = <a*> +argv[1] = <a*> +argv[1] = <c> +argv[2] = <ca> +argv[3] = <cb> +argv[4] = <a*> +argv[5] = <*q*> +argv[1] = <**> +argv[1] = <**> +argv[1] = <\.\./*/> +argv[1] = <s/\..*//> +argv[1] = </^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/> +argv[1] = <abc> +argv[2] = <abd> +argv[3] = <abe> +argv[4] = <bb> +argv[5] = <cb> +argv[1] = <abd> +argv[2] = <abe> +argv[3] = <bb> +argv[4] = <bcd> +argv[5] = <bdir> +argv[6] = <ca> +argv[7] = <cb> +argv[8] = <dd> +argv[9] = <de> +argv[1] = <abd> +argv[2] = <abe> +argv[1] = <a-b> +argv[2] = <aXb> +argv[1] = <d> +argv[2] = <dd> +argv[3] = <de> +argv[1] = <a*b/ooo> +argv[1] = <a*b/ooo> +no match +not there +argv[1] = <abc> +argv[1] = <abc> +argv[1] = <abc> +argv[1] = <abc> +match +match +ok +ok +ok +ok +ok Index: ifs-test-1.sh =================================================================== RCS file: /cvsroot/winbash/winbash/tests/ifs-test-1.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ifs-test-1.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ifs-test-1.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,5 +1,5 @@ -OIFS="$IFS" -IFS=":$IFS" -eval foo="a:b:c" -IFS="$OIFS" -echo $foo +OIFS="$IFS" +IFS=":$IFS" +eval foo="a:b:c" +IFS="$OIFS" +echo $foo Index: ifs-test-2.sh =================================================================== RCS file: /cvsroot/winbash/winbash/tests/ifs-test-2.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ifs-test-2.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ifs-test-2.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,9 +1,9 @@ -OIFS=$IFS -IFS=":$IFS" -foo=$(echo a:b:c) -IFS=$OIFS - -for i in $foo -do - echo $i -done +OIFS=$IFS +IFS=":$IFS" +foo=$(echo a:b:c) +IFS=$OIFS + +for i in $foo +do + echo $i +done Index: ifs-test-3.sh =================================================================== RCS file: /cvsroot/winbash/winbash/tests/ifs-test-3.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ifs-test-3.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ifs-test-3.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,9 +1,9 @@ -OIFS=$IFS -IFS=":$IFS" -foo=`echo a:b:c` -IFS=$OIFS - -for i in $foo -do - echo $i -done +OIFS=$IFS +IFS=":$IFS" +foo=`echo a:b:c` +IFS=$OIFS + +for i in $foo +do + echo $i +done Index: ifs.1.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/ifs.1.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ifs.1.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ifs.1.right 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -a:b:c +a:b:c Index: ifs.2.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/ifs.2.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ifs.2.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ifs.2.right 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -a:b:c +a:b:c Index: ifs.3.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/ifs.3.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ifs.3.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ifs.3.right 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -a:b:c +a:b:c Index: input-line.sh =================================================================== RCS file: /cvsroot/winbash/winbash/tests/input-line.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- input-line.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ input-line.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,4 +1,4 @@ -echo before calling input-line.sub -../bash ./input-line.sub -this line for input-line.sub -echo finished with input-line.sub +echo before calling input-line.sub +../bash ./input-line.sub +this line for input-line.sub +echo finished with input-line.sub Index: input-line.sub =================================================================== RCS file: /cvsroot/winbash/winbash/tests/input-line.sub,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- input-line.sub 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ input-line.sub 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,2 +1,2 @@ -read line -echo line read by $0 was \`$line\' +read line +echo line read by $0 was \`$line\' Index: input.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/input.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- input.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ input.right 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,3 +1,3 @@ -before calling input-line.sub -line read by ./input-line.sub was `this line for input-line.sub' -finished with input-line.sub +before calling input-line.sub +line read by ./input-line.sub was `this line for input-line.sub' +finished with input-line.sub Index: minus-e =================================================================== RCS file: /cvsroot/winbash/winbash/tests/minus-e,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- minus-e 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ minus-e 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,6 +1,6 @@ -set -e -if set +e -then - false -fi -echo hi +set -e +if set +e +then + false +fi +echo hi Index: minus-e.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/minus-e.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- minus-e.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ minus-e.right 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -hi +hi Index: new-exp.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/new-exp.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- new-exp.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ new-exp.right 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,33 +1,33 @@ -argv[1] = <foo bar> -argv[1] = <foo> -argv[1] = </usr/homes/chet> -argv[1] = </usr/homes/chet> -argv[1] = </usr/homes/chet> -./new-exp.tests: ${HOME:`echo }`}: bad substitution -./new-exp.tests: ${_ENV[(_$-=0)+(_=1)-_${-%%*i*}]}: bad substitution -argv[1] = </usr/homes/chet> -argv[1] = </usr/homes/chet> -argv[1] = </usr/homes/chet> -argv[1] = </usr/homes/chet> -argv[1] = </usr/homes/chet> -argv[1] = </usr/homes/chet> -argv[1] = </usr/homes/chet> -argv[1] = <*@> -argv[1] = <@*> -argv[1] = <)> -argv[1] = <")"> -argv[1] = <-abcd> -argv[2] = <-> -argv[1] = <-abcd> -argv[2] = <-> -argv[1] = <-abcd-> -argv[1] = <a b c d e> -bar foo -bar foo -bar foo -bar foo -bar foo -./new-exp.tests: ABX: unbound variable -./new-exp.tests: $6: cannot assign in this way - -./new-exp.tests: ABXD: parameter unset +argv[1] = <foo bar> +argv[1] = <foo> +argv[1] = </usr/homes/chet> +argv[1] = </usr/homes/chet> +argv[1] = </usr/homes/chet> +./new-exp.tests: ${HOME:`echo }`}: bad substitution +./new-exp.tests: ${_ENV[(_$-=0)+(_=1)-_${-%%*i*}]}: bad substitution +argv[1] = </usr/homes/chet> +argv[1] = </usr/homes/chet> +argv[1] = </usr/homes/chet> +argv[1] = </usr/homes/chet> +argv[1] = </usr/homes/chet> +argv[1] = </usr/homes/chet> +argv[1] = </usr/homes/chet> +argv[1] = <*@> +argv[1] = <@*> +argv[1] = <)> +argv[1] = <")"> +argv[1] = <-abcd> +argv[2] = <-> +argv[1] = <-abcd> +argv[2] = <-> +argv[1] = <-abcd-> +argv[1] = <a b c d e> +bar foo +bar foo +bar foo +bar foo +bar foo +./new-exp.tests: ABX: unbound variable +./new-exp.tests: $6: cannot assign in this way + +./new-exp.tests: ABXD: parameter unset Index: new-exp.tests =================================================================== RCS file: /cvsroot/winbash/winbash/tests/new-exp.tests,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- new-exp.tests 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ new-exp.tests 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,95 +1,95 @@ -expect() -{ - echo expect "$@" -} - -HOME=/usr/homes/chet # to make the check against new-exp.right work -expect '<foo bar>' -recho "${undef-"foo bar"}" # should be foo bar -expect '<foo>' -recho "${und="foo"}" # should be foo - -expect "<$HOME>" -recho ${HOME-"}"} -expect "<$HOME>" -recho "${HOME-'}'}" -expect "<$HOME>" -recho "${HOME-"}"}" - -expect $0: '${HOME:`echo }`}: bad substitution' -recho "${HOME:`echo }`}" # should be an error -- bad substitution - -expect $0: '${_ENV[(_$-=0)+(_=1)-_${-%%*i*}]}: bad substitution' -x=${_ENV[(_$-=0)+(_=1)-_${-%%*i*}]} # memory leak - -expect "<$HOME>" -recho ${HOME} -expect "<$HOME>" -recho ${HOME:-`echo }`} -expect "<$HOME>" -recho ${HOME:-`echo "}"`} -expect "<$HOME>" -recho "${HOME:-`echo "}"`}" -expect "<$HOME>" -recho "$(echo "${HOME}")" -expect "<$HOME>" -recho "$(echo "$(echo ${HOME})")" -expect "<$HOME>" -recho "$(echo "$(echo "${HOME}")")" - -P=*@* -expect '<*@>' -recho "${P%"*"}" # should be *@ -expect '<@*>' -recho "${P#\*}" # should be @* - -expect '<)>' -recho "$(echo ")")" # should be ) -expect '<")">' -recho "$(echo "\")\"")" # should be ")" - -foo='abcd ' -expect '<-abcd> <->' -recho -${foo}- # should be -abcd - -expect '<-abcd> <->' -recho -${foo% *}- # should be -abcd - -expect '<-abcd->' -recho -${foo%% *}- # should be -abcd- - -set a b c d e -expect '<a b c d e>' -IFS="" -recho "$@" -IFS=' -' - -foo=bar -expect '<bar foo>' -echo -n $foo' ' ; echo foo - -expect '<bar foo>' -echo -n $foo" " ; echo foo - -expect '<bar foo>' -echo -n "$foo " ; echo foo - -expect '<bar foo>' -echo -e "$foo\c " ; echo foo - -expect '<bar foo>' -echo -e $foo"\c " ; echo foo - -set -u -expect $0: ABX: unbound variable -recho ${ABX} -set +u - -expect $0: '$6: cannot assign in this way' -recho ${6="arg6"} - -expect a newline -echo $abmcde - -# this must be last! -expect $0: 'ABXD: parameter unset' -recho ${ABXD:?"parameter unset"} +expect() +{ + echo expect "$@" +} + +HOME=/usr/homes/chet # to make the check against new-exp.right work +expect '<foo bar>' +recho "${undef-"foo bar"}" # should be foo bar +expect '<foo>' +recho "${und="foo"}" # should be foo + +expect "<$HOME>" +recho ${HOME-"}"} +expect "<$HOME>" +recho "${HOME-'}'}" +expect "<$HOME>" +recho "${HOME-"}"}" + +expect $0: '${HOME:`echo }`}: bad substitution' +recho "${HOME:`echo }`}" # should be an error -- bad substitution + +expect $0: '${_ENV[(_$-=0)+(_=1)-_${-%%*i*}]}: bad substitution' +x=${_ENV[(_$-=0)+(_=1)-_${-%%*i*}]} # memory leak + +expect "<$HOME>" +recho ${HOME} +expect "<$HOME>" +recho ${HOME:-`echo }`} +expect "<$HOME>" +recho ${HOME:-`echo "}"`} +expect "<$HOME>" +recho "${HOME:-`echo "}"`}" +expect "<$HOME>" +recho "$(echo "${HOME}")" +expect "<$HOME>" +recho "$(echo "$(echo ${HOME})")" +expect "<$HOME>" +recho "$(echo "$(echo "${HOME}")")" + +P=*@* +expect '<*@>' +recho "${P%"*"}" # should be *@ +expect '<@*>' +recho "${P#\*}" # should be @* + +expect '<)>' +recho "$(echo ")")" # should be ) +expect '<")">' +recho "$(echo "\")\"")" # should be ")" + +foo='abcd ' +expect '<-abcd> <->' +recho -${foo}- # should be -abcd - +expect '<-abcd> <->' +recho -${foo% *}- # should be -abcd - +expect '<-abcd->' +recho -${foo%% *}- # should be -abcd- + +set a b c d e +expect '<a b c d e>' +IFS="" +recho "$@" +IFS=' +' + +foo=bar +expect '<bar foo>' +echo -n $foo' ' ; echo foo + +expect '<bar foo>' +echo -n $foo" " ; echo foo + +expect '<bar foo>' +echo -n "$foo " ; echo foo + +expect '<bar foo>' +echo -e "$foo\c " ; echo foo + +expect '<bar foo>' +echo -e $foo"\c " ; echo foo + +set -u +expect $0: ABX: unbound variable +recho ${ABX} +set +u + +expect $0: '$6: cannot assign in this way' +recho ${6="arg6"} + +expect a newline +echo $abmcde + +# this must be last! +expect $0: 'ABXD: parameter unset' +recho ${ABXD:?"parameter unset"} Index: prec.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/prec.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- prec.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ prec.right 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,28 +1,28 @@ -`Say' echos its argument. Its return value is of no interest. -`Truth' echos its argument and returns a TRUE result. -`False' echos its argument and returns a FALSE result. - - Truth 1 && Truth 2 || Say 3 output=12 -( Truth 1 && Truth 2 ) || Say 3 output=12 - - Truth 1 && False 2 || Say 3 output=123 -( Truth 1 && False 2 ) || Say 3 output=123 - - False 1 && Truth 2 || Say 3 output=13 -( False 1 && Truth 2 ) || Say 3 output=13 - - False 1 && False 2 || Say 3 output=13 -( False 1 && False 2 ) || Say 3 output=13 - -Truth 1 || Truth 2 && Say 3 output=13 -Truth 1 || ( Truth 2 && Say 3 ) output=1 - -Truth 1 || False 2 && Say 3 output=13 -Truth 1 || ( False 2 && Say 3 ) output=1 - -False 1 || Truth 2 && Say 3 output=123 -False 1 || ( Truth 2 && Say 3 ) output=123 - -False 1 || False 2 && Say 3 output=12 -False 1 || ( False 2 && Say 3 ) output=12 - +`Say' echos its argument. Its return value is of no interest. +`Truth' echos its argument and returns a TRUE result. +`False' echos its argument and returns a FALSE result. + + Truth 1 && Truth 2 || Say 3 output=12 +( Truth 1 && Truth 2 ) || Say 3 output=12 + + Truth 1 && False 2 || Say 3 output=123 +( Truth 1 && False 2 ) || Say 3 output=123 + + False 1 && Truth 2 || Say 3 output=13 +( False 1 && Truth 2 ) || Say 3 output=13 + + False 1 && False 2 || Say 3 output=13 +( False 1 && False 2 ) || Say 3 output=13 + +Truth 1 || Truth 2 && Say 3 output=13 +Truth 1 || ( Truth 2 && Say 3 ) output=1 + +Truth 1 || False 2 && Say 3 output=13 +Truth 1 || ( False 2 && Say 3 ) output=1 + +False 1 || Truth 2 && Say 3 output=123 +False 1 || ( Truth 2 && Say 3 ) output=123 + +False 1 || False 2 && Say 3 output=12 +False 1 || ( False 2 && Say 3 ) output=12 + Index: precedence =================================================================== RCS file: /cvsroot/winbash/winbash/tests/precedence,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- precedence 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ precedence 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,75 +1,75 @@ -# @(#)precedence_test 1.0 91/07/24 Maarten Litmaath -# test of relative precedences for `&&' and `||' operators - -echo "\`Say' echos its argument. Its return value is of no interest." -case `echo -n` in - '') Say () { echo -n "$*" ; } ;; - *) Say () { echo "$*\c" ; } ;; -esac - -echo "\`Truth' echos its argument and returns a TRUE result." -Truth () { - Say $1; - return 0; -} - -echo "\`False' echos its argument and returns a FALSE result." -False () { - Say $1; - return 1; -} - -echo "" - -cmd1='$open $test1 && $test2 $close || $test3' -cmd2='$test1 || $open $test2 && $test3 $close' - -grouping_sh= -grouping_C='( )' - -test3='Say 3' - -for i in 1 2 -do - eval proto=\$cmd$i - - for test1 in 'Truth 1' 'False 1' - do - for test2 in 'Truth 2' 'False 2' - do - for precedence in sh C - do - eval set x \$grouping_$precedence - shift - open=${1-' '} - close=${2-' '} - eval cmd=\""$proto"\" - Say "$cmd output=" - output=`eval "$cmd"` - Say "$output" - read correct || { echo 'Input fubar. Abort.' >&2; exit 1; } - test "X$output" = "X$correct" || echo " correct=$correct" - echo '' - done - - echo '' - done - done -done << EOF -12 -12 -123 -123 -13 -13 -13 -13 -13 -1 -13 -1 -123 -123 -12 -12 -EOF +# @(#)precedence_test 1.0 91/07/24 Maarten Litmaath +# test of relative precedences for `&&' and `||' operators + +echo "\`Say' echos its argument. Its return value is of no interest." +case `echo -n` in + '') Say () { echo -n "$*" ; } ;; + *) Say () { echo "$*\c" ; } ;; +esac + +echo "\`Truth' echos its argument and returns a TRUE result." +Truth () { + Say $1; + return 0; +} + +echo "\`False' echos its argument and returns a FALSE result." +False () { + Say $1; + return 1; +} + +echo "" + +cmd1='$open $test1 && $test2 $close || $test3' +cmd2='$test1 || $open $test2 && $test3 $close' + +grouping_sh= +grouping_C='( )' + +test3='Say 3' + +for i in 1 2 +do + eval proto=\$cmd$i + + for test1 in 'Truth 1' 'False 1' + do + for test2 in 'Truth 2' 'False 2' + do + for precedence in sh C + do + eval set x \$grouping_$precedence + shift + open=${1-' '} + close=${2-' '} + eval cmd=\""$proto"\" + Say "$cmd output=" + output=`eval "$cmd"` + Say "$output" + read correct || { echo 'Input fubar. Abort.' >&2; exit 1; } + test "X$output" = "X$correct" || echo " correct=$correct" + echo '' + done + + echo '' + done + done +done << EOF +12 +12 +123 +123 +13 +13 +13 +13 +13 +1 +13 +1 +123 +123 +12 +12 +EOF Index: run-all =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-all,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-all 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-all 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,16 +1,16 @@ -#! /bin/sh - -PATH=$PATH:. -export PATH - -echo Any output from any test indicates an anomaly worth investigating -for x in run-* -do - case $x in - $0) ;; - *.orig|*~) ;; - *) echo $x ; sh $x ;; - esac -done - -exit 0 +#! /bin/sh + +PATH=$PATH:. +export PATH + +echo Any output from any test indicates an anomaly worth investigating +for x in run-* +do + case $x in + $0) ;; + *.orig|*~) ;; + *) echo $x ; sh $x ;; + esac +done + +exit 0 Index: run-dollars =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-dollars,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-dollars 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-dollars 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,3 +1,3 @@ -../bash ./dollar-star.sh a b > x 2>&1 -../bash ./dollar-at.sh a b >>x 2>&1 -diff x dollar.right && rm -f x +../bash ./dollar-star.sh a b > x 2>&1 +../bash ./dollar-at.sh a b >>x 2>&1 +diff x dollar.right && rm -f x Index: run-exp-tests =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-exp-tests,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-exp-tests 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-exp-tests 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,2 +1,2 @@ -../bash ./exp-tests | grep -v '^expect' > xx -diff xx exp.right && rm -f xx +../bash ./exp-tests | grep -v '^expect' > xx +diff xx exp.right && rm -f xx Index: run-glob-test =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-glob-test,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-glob-test 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-glob-test 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,4 +1,4 @@ -PATH=$PATH:`pwd` -export PATH -../bash ./glob-test | grep -v '^expect' > xx -diff xx glob.right && rm -f xx +PATH=$PATH:`pwd` +export PATH +../bash ./glob-test | grep -v '^expect' > xx +diff xx glob.right && rm -f xx Index: run-ifs-tests =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-ifs-tests,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-ifs-tests 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-ifs-tests 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,13 +1,13 @@ -# -# show that IFS is only applied to the result of expansions -# -../bash ifs-test-1.sh > xx -diff xx ./ifs.1.right - -../bash ifs-test-2.sh > xx -diff xx ./ifs.2.right - -../bash ifs-test-3.sh > xx -diff xx ./ifs.3.right - -rm -f xx +# +# show that IFS is only applied to the result of expansions +# +../bash ifs-test-1.sh > xx +diff xx ./ifs.1.right + +../bash ifs-test-2.sh > xx +diff xx ./ifs.2.right + +../bash ifs-test-3.sh > xx +diff xx ./ifs.3.right + +rm -f xx Index: run-input-test =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-input-test,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-input-test 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-input-test 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,2 +1,2 @@ -../bash < ./input-line.sh > xx -diff xx input.right && rm -f xx +../bash < ./input-line.sh > xx +diff xx input.right && rm -f xx Index: run-minus-e =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-minus-e,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-minus-e 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-minus-e 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,2 +1,2 @@ -../bash ./minus-e > xx -diff xx minus-e.right && rm -f xx +../bash ./minus-e > xx +diff xx minus-e.right && rm -f xx Index: run-new-exp =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-new-exp,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-new-exp 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-new-exp 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,2 +1,2 @@ -../bash ./new-exp.tests 2>&1 | grep -v '^expect' > xx -diff xx new-exp.right && rm -f xx +../bash ./new-exp.tests 2>&1 | grep -v '^expect' > xx +diff xx new-exp.right && rm -f xx Index: run-precedence =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-precedence,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-precedence 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-precedence 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,2 +1,2 @@ -../bash ./precedence > xx -diff xx prec.right && rm -f xx +../bash ./precedence > xx +diff xx prec.right && rm -f xx Index: run-set-e-test =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-set-e-test,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-set-e-test 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-set-e-test 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,2 +1,2 @@ -../bash ./set-e-test > xx -diff xx set-e.right && rm -f xx +../bash ./set-e-test > xx +diff xx set-e.right && rm -f xx Index: run-strip =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-strip,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-strip 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-strip 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,2 +1,2 @@ -../bash ./strip.tests > xx -diff xx strip.right && rm -f xx +../bash ./strip.tests > xx +diff xx strip.right && rm -f xx Index: run-varenv =================================================================== RCS file: /cvsroot/winbash/winbash/tests/run-varenv,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- run-varenv 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ run-varenv 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,2 +1,2 @@ -../bash ./varenv.sh | grep -v '^expect' > xx -diff xx varenv.right && rm -f xx +../bash ./varenv.sh | grep -v '^expect' > xx +diff xx varenv.right && rm -f xx Index: set-e-test =================================================================== RCS file: /cvsroot/winbash/winbash/tests/set-e-test,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- set-e-test 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ set-e-test 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,16 +1,16 @@ -if : ; then - set -e - N=95 - while :; do - # expr returns 1 if expression is null or 0 - set +e - N_MOD_100=`expr $N % 100` - set -e - echo $N_MOD_100 - N=`expr $N + 1` - if [ $N -eq 110 ]; then - break - fi - done - set +e -fi +if : ; then + set -e + N=95 + while :; do + # expr returns 1 if expression is null or 0 + set +e + N_MOD_100=`expr $N % 100` + set -e + echo $N_MOD_100 + N=`expr $N + 1` + if [ $N -eq 110 ]; then + break + fi + done + set +e +fi Index: set-e.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/set-e.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- set-e.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ set-e.right 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,15 +1,15 @@ -95 -96 -97 -98 -99 -0 -1 -2 -3 -4 -5 -6 -7 -8 -9 +95 +96 +97 +98 +99 +0 +1 +2 +3 +4 +5 +6 +7 +8 +9 Index: strip.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/strip.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- strip.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ strip.right 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,12 +1,12 @@ -'' -' ab ' -' ' -'' -'' -'' -'ababababababab' -'ababababababab ' -'ababababababab ' -'abababa -bababab ' -'' +'' +' ab ' +' ' +'' +'' +'' +'ababababababab' +'ababababababab ' +'ababababababab ' +'abababa +bababab ' +'' Index: strip.tests =================================================================== RCS file: /cvsroot/winbash/winbash/tests/strip.tests,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- strip.tests 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ strip.tests 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,22 +1,22 @@ -v=`echo "" ; echo "" ; echo ""` -echo "'$v'" -v=`echo -n " ab "` -echo "'$v'" -v=`echo -n " "` -echo "'$v'" -v=`echo -n ""` -echo "'$v'" -v=`echo ""` -echo "'$v'" -v=`echo` -echo "'$v'" -v=`echo ababababababab` -echo "'$v'" -v=`echo "ababababababab "` -echo "'$v'" -v=`echo -n "ababababababab "` -echo "'$v'" -v=`echo -ne "abababa\nbababab "` -echo "'$v'" -v="`echo -e '\n\n\n\n'`" -echo "'$v'" +v=`echo "" ; echo "" ; echo ""` +echo "'$v'" +v=`echo -n " ab "` +echo "'$v'" +v=`echo -n " "` +echo "'$v'" +v=`echo -n ""` +echo "'$v'" +v=`echo ""` +echo "'$v'" +v=`echo` +echo "'$v'" +v=`echo ababababababab` +echo "'$v'" +v=`echo "ababababababab "` +echo "'$v'" +v=`echo -n "ababababababab "` +echo "'$v'" +v=`echo -ne "abababa\nbababab "` +echo "'$v'" +v="`echo -e '\n\n\n\n'`" +echo "'$v'" Index: tilde-tests =================================================================== RCS file: /cvsroot/winbash/winbash/tests/tilde-tests,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- tilde-tests 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ tilde-tests 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,16 +1,16 @@ -HOME=/usr/xyz -set -v -echo ~chet -echo ~ch\et -echo ~chet/"foo" -echo "~chet"/"foo" -echo \~chet/"foo" -echo \~chet/bar -echo ~\chet/bar -echo ~chet""/bar -echo ":~chet/" -echo abcd~chet -echo "SHELL=~/bash" -echo SHELL=~/bash -echo abcd:~chet -echo PATH=/usr/ucb:/bin:~/bin:~/tmp/bin:/usr/bin +HOME=/usr/xyz +set -v +echo ~chet +echo ~ch\et +echo ~chet/"foo" +echo "~chet"/"foo" +echo \~chet/"foo" +echo \~chet/bar +echo ~\chet/bar +echo ~chet""/bar +echo ":~chet/" +echo abcd~chet +echo "SHELL=~/bash" +echo SHELL=~/bash +echo abcd:~chet +echo PATH=/usr/ucb:/bin:~/bin:~/tmp/bin:/usr/bin Index: tilde.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/tilde.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- tilde.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ tilde.right 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,14 +1,14 @@ -/usr/homes/chet -~chet -/usr/homes/chet/foo -~chet/foo -~chet/foo -~chet/bar -~chet/bar -~chet/bar -:~chet/ -abcd~chet -SHELL=~/bash -SHELL=/usr/xyz/bash -abcd:~chet -PATH=/usr/ucb:/bin:~/bin:~/tmp/bin:/usr/bin +/usr/homes/chet +~chet +/usr/homes/chet/foo +~chet/foo +~chet/foo +~chet/bar +~chet/bar +~chet/bar +:~chet/ +abcd~chet +SHELL=~/bash +SHELL=/usr/xyz/bash +abcd:~chet +PATH=/usr/ucb:/bin:~/bin:~/tmp/bin:/usr/bin Index: varenv.right =================================================================== RCS file: /cvsroot/winbash/winbash/tests/varenv.right,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- varenv.right 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ varenv.right 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,14 +1,14 @@ -3 4 -5 6 7 8 9 -7 8 9 -/usr/chet -/usr/chet -/usr/chet -/a/b/c -/usr/chet -/usr/chet 7 -/a/b/c 9 /a/b/c -/a/b/c 9 /a/b/c -/a/b/c /a/b/c -1 2 -1 1 +3 4 +5 6 7 8 9 +7 8 9 +/usr/chet +/usr/chet +/usr/chet +/a/b/c +/usr/chet +/usr/chet 7 +/a/b/c 9 /a/b/c +/a/b/c 9 /a/b/c +/a/b/c /a/b/c +1 2 +1 1 Index: varenv.sh =================================================================== RCS file: /cvsroot/winbash/winbash/tests/varenv.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- varenv.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ varenv.sh 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,94 +1,94 @@ -# -# varenv.sh -# -# Test the behavior of the shell with respect to variable and environment -# assignments -# -expect() -{ - echo expect "$@" -} - -a=1 -b=2 -c=3 -d=4 -e=5 -f=6 g=7 h=8 - -a=3 b=4 $CHMOD $MODE $FN - -# This should echo "3 4" according to Posix.2 -expect "3 4" -echo $a $b - -set -k - -# Assignment statements made when no words are left affect the shell's -# environment -a=5 b=6 $CHMOD c=7 $MODE d=8 $FN e=9 - -expect "5 6 7 8 9" -echo $a $b $c $d $e - -$CHMOD f=7 $MODE g=8 $FN h=9 -expect "7 8 9" -echo $f $g $h - -set +k - -# The temporary environment does not affect variable expansion, only the -# environment given to the command - -export HOME=/usr/chet -expect $HOME -echo $HOME - -expect $HOME -HOME=/a/b/c /bin/echo $HOME - -expect $HOME -echo $HOME - -# This should echo /a/b/c -expect /a/b/c -HOME=/a/b/c printenv HOME - -set -k - -# This should echo $HOME 9, NOT /a/b/c 9 - -expect "$HOME" -HOME=/a/b/c /bin/echo $HOME c=9 -expect "$HOME 7" -echo $HOME $c - -# I claim the next two echo calls should give identical output. -# ksh agrees, the System V.3 sh does not - -expect "/a/b/c 9 /a/b/c" -HOME=/a/b/c $ECHO a=$HOME c=9 -echo $HOME $c $a - -expect "/a/b/c 9 /a/b/c" -HOME=/a/b/c a=$HOME c=9 -echo $HOME $c $a -set +k - -# How do assignment statements affect subsequent assignments on the same -# line? -expect "/a/b/c /a/b/c" -HOME=/a/b/c a=$HOME -echo $HOME $a - -# The system V.3 sh does this wrong; the last echo should output "1 1", -# but the system V.3 sh has it output "2 2". Posix.2 says the assignment -# statements are processed left-to-right. bash and ksh output the right -# thing -c=1 -d=2 -expect "1 2" -echo $c $d -d=$c c=$d -expect "1 1" -echo $c $d +# +# varenv.sh +# +# Test the behavior of the shell with respect to variable and environment +# assignments +# +expect() +{ + echo expect "$@" +} + +a=1 +b=2 +c=3 +d=4 +e=5 +f=6 g=7 h=8 + +a=3 b=4 $CHMOD $MODE $FN + +# This should echo "3 4" according to Posix.2 +expect "3 4" +echo $a $b + +set -k + +# Assignment statements made when no words are left affect the shell's +# environment +a=5 b=6 $CHMOD c=7 $MODE d=8 $FN e=9 + +expect "5 6 7 8 9" +echo $a $b $c $d $e + +$CHMOD f=7 $MODE g=8 $FN h=9 +expect "7 8 9" +echo $f $g $h + +set +k + +# The temporary environment does not affect variable expansion, only the +# environment given to the command + +export HOME=/usr/chet +expect $HOME +echo $HOME + +expect $HOME +HOME=/a/b/c /bin/echo $HOME + +expect $HOME +echo $HOME + +# This should echo /a/b/c +expect /a/b/c +HOME=/a/b/c printenv HOME + +set -k + +# This should echo $HOME 9, NOT /a/b/c 9 + +expect "$HOME" +HOME=/a/b/c /bin/echo $HOME c=9 +expect "$HOME 7" +echo $HOME $c + +# I claim the next two echo calls should give identical output. +# ksh agrees, the System V.3 sh does not + +expect "/a/b/c 9 /a/b/c" +HOME=/a/b/c $ECHO a=$HOME c=9 +echo $HOME $c $a + +expect "/a/b/c 9 /a/b/c" +HOME=/a/b/c a=$HOME c=9 +echo $HOME $c $a +set +k + +# How do assignment statements affect subsequent assignments on the same +# line? +expect "/a/b/c /a/b/c" +HOME=/a/b/c a=$HOME +echo $HOME $a + +# The system V.3 sh does this wrong; the last echo should output "1 1", +# but the system V.3 sh has it output "2 2". Posix.2 says the assignment +# statements are processed left-to-right. bash and ksh output the right +# thing +c=1 +d=2 +expect "1 2" +echo $c $d +d=$c c=$d +expect "1 1" +echo $c $d Index: x =================================================================== RCS file: /cvsroot/winbash/winbash/tests/x,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- x 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ x 9 Mar 2002 04:43:17 -0000 1.2 @@ -1,2 +1,2 @@ -./dollar-star.sh: recho: command not found -./dollar-at.sh: recho: command not found +./dollar-star.sh: recho: command not found +./dollar-at.sh: recho: command not found Index: xx =======... [truncated message content] |
From: Enrico B. <enr...@us...> - 2002-03-09 04:43:21
|
Update of /cvsroot/winbash/winbash/support In directory usw-pr-cvs1:/tmp/cvs-serv381/support Modified Files: FAQ PORTING SYMLINKS bash.xbm bashbug.sh cat-s clone-bash cppmagic fixlinks getcppsyms.c inpath install.sh mkdirs mklinks mkmachtype mksysdefs printenv recho.c srcdir Log Message: Fixed more cr/lf problems. Index: FAQ =================================================================== RCS file: /cvsroot/winbash/winbash/support/FAQ,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- FAQ 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ FAQ 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,202 +1,202 @@ -This Frequently Asked Questions file is edited in -*- indented-text -*- mode. - -If you are viewing this text in a GNU Emacs Buffer, you can type "M-2 C-x $" to -get an overview of just the questions. Then, when you want to look at the text -of the answers, just type "C-x $". - -To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a C-r if -that doesn't work, then type ESC to end the search. - -1: How do I convert all of my Csh aliases over to Bash aliases? - Bash uses a different syntax to support aliases than Csh does. The - details can be found in the documentation. We have provided a shell - script which does most of the work of conversion for you; this - script can be found in ./examples/alias-conv.sh. Here is how you - use it: - - Start Csh in the normal way for you. (e.g., "csh") - - Pipe the output of "alias" through "alias-conv.sh", saving the - results into "bash_aliases": - - alias | alias-conv.sh >.bash_aliases - - Edit "bash_aliases" carefully reading through any created - functions. You will need to change the names of Csh specific - variables (like $cwd) to the Bash equivalents (like $PWD). You - will also need to remove recursive references to commands which - are defined as functions. For example, the Csh alias: - - alias cd 'cd \!*;echo $cwd' - - is converted to the Bash function: - - cd () - { - cd $*; - echo $cwd - } - - This function contains a self-pointing reference to "cd", which - should be changed to use the "builtin" version. It also uses - the Csh variable `$cwd' which has an equivalent in Bash. - Precede the recursive reference with the word "builtin", and - change the name of the variable: - - cd () { builtin cd $*; echo $PWD } - - Merge the edited file into your ~/.bashrc. - -2: Background jobs have staggered output, as if there was no CR before the LF. - This is a result of bash using the BSD-style tty driver on Ultrix. The BSD - driver ties input and output carriage return translation together with the - CRMOD bit. (The CRMOD bit causes CR->LF translation on input and LF->CRLF - translation on output.) Unless the CRMOD bit is cleared, it is impossible - to get a literal ^M in an input line. Unfortunately, one of the effects of - clearing it is the loss of output processing you've observed. - - The Ultrix Posix-style tty driver can't be used because it has serious - problems with losing typeahead when ICANON is switched on and off. These - characters seem to reappear later without warning, usually when a - program that uses the BSD-style ioctls turns on CBREAK (e.g., `more'). - -3: Bash's "test" different from "/bin/test"? ([ ! x -o x ] -> false) - Bash's builtin "test" implements the Posix.2 spec, which can be - summarized as follows (the wording is due to David Korn): - - Here is the set of rules for processing test arguments. - - 0 Args: False - 1 Arg: True iff argument is not null. - 2 Args: If first arg is !, True iff second argument is null. - If first argument is unary, then true if unary test is true - Otherwise error. - 3 Args: If second argument is a binary operator, do binary test of $1 $3 - If first argument is !, negate two argument test of $2 $3 - Otherwise error. - 4 Args: If first argument is !, negate three argument test of $2 $3 $4. - Otherwise unspecified - 5 or more Args: unspecified. (Historical shells would used their - current algorithm). - - The operators -a and -o are considered binary operators for the purpose - of the 3 Arg case. - - As you can see, the test becomes (not (x or x)), which is false. - -4: Completion listings can differ from `ls' in the number of columns output. - This can happen because `ls' calls stat () on every file before - listing the output, while GNU Readline only calls stat () on the - files when they are being printed. This means that `ls' knows how - many characters will be added to each filename in advance, and can - accurately calculate the maximum length, while Bash must assume that - each filename will have characters added to it. - -5: Bash crashes when I do "cd". - If you have `cd' defined as a function, it is likely that the - function is recursively calling itself. See the answer to question - 1 above. - -6: Why does Bash sometimes say "Broken pipe"? - If a sequence of commands appear in a pipeline, and one of the - reading commands finishes before the writer has finished, the writer - receives a SIGPIPE signal. Many other shells special-case SIGPIPE as - an exit status in the pipeline and do not report it. For example, - in: - - ps -aux | head - - `head' can finish before `ps' writes all of its output. In that case, - Bash will print `Broken pipe' to stderr on behalf of the `ps' - command. - -7: How can I use `!' to reinvoke a command starting with a digit? - If you had issued a command such as `8086engine foo', and then at a - later time wished to reinvoke the command, typing `!80' would probably - not work since Bash would think you meant the 80'th command in the - history, not the command starting with `80'. You can type `!?80', - which says to re-execute the most recent command containing `80'. - -Questions About Input Line Editing: - -1: What do things like this mean: C-h, M-C-a, RET, etc.? - - C-a means press the "a" key while holding down the "Control" key. The - ASCII code this sends will generally be the value that would be sent by - pressing just "a" minus 96 or 64. Either way it will be a number from 0 - to 31. - - M-a means press the "a" key while holding down the "Meta" key. The - ASCII code this sends is the sum of the ASCII code that would be sent by - pressing just "a" and 128. - - M-C-a means press the "a" key while holding down both the "Control" key - and the "Meta" key. C-M-a is a synonym for M-C-a. - - * RET means press the "Return" key. RET is the same as C-m. This sends - ASCII code 13. - - * LFD means press the "Linefeed" key. LFD is also the same as C-j. This - sends ASCII code 10. Under Unix, ASCII code 10 is more often called - "Newline". - - * DEL means press the "Delete" key. DEL is the same as C-?. This sends - ASCII code 127. (WARNING: It is a misnomer to call C-? a "control" key, - since 127 has both bits 6 and 7 turned ON, and the rule for control keys - is that they have 6 and 7 turned OFF. Also, on very few keyboards does - Control-? generate ASCII code 127. In fact, Control-? (which is - actually Control-Shift-/) is more likely to generate C-_, ASCII code - 31!) - - * ESC means press the "Escape" key. ESC is the same as C-[. This sends - ASCII code 27. - - * SPC means press the "Space" key. This send ASCII code 32. - - * TAB means press the "Tab" key. TAB is the same as C-i. This send ASCII - code 9. - - For C-@ and C-^, usually you don't have to hold down the shift key and you - can type Control-2 or Control-6 instead. For C-_, you may have to hold - down the shift key, typing Control-Shift-Hyphen. C-@ can often be - generated by typing Control-Space. C-@ is often called the NUL character, - and has ASCII value 0. C-_ can often be generated by typing Control-7 or - Control-/. Try Control with all of the digits on your keyboard to see - what gets generated. - - To read more about this online, type "C-h i m emacs RET m characters - RET", and also "C-h i m emacs RET m keys RET". - -2: What do you mean when you write things like this: type "ESC a"? - - I will enclose key sequences that are longer than one key inside double - quotes. These notations refer to single key strokes (some with - modifiers): - - C-x, M-x, M-C-x - RET, LFD, DEL, ESC, SPC, TAB - - I separate these from other keys within double quotes by spaces. Any - real spaces that I write inside double quotes can be ignored, only SPC - means press the space key. All other characters within double quotes - represent single keys (some shifted). - -3: What if I don't have a Meta key? - - Instead of typing M-a, you can type "ESC a" instead. In fact, Emacs - converts M-a internally into "ESC a" anyway (depending on the value of - meta-prefix-char). - -4: What if I don't have an Escape key? - - Type C-[ instead. This should send ASCII code 27 just like an Escape - key would. - -5: What does "M-x command" mean? - - "M-x command" means type M-x, then type the name of the command, then - - -Local Variables: -eval: (set-selective-display 2) -End: +This Frequently Asked Questions file is edited in -*- indented-text -*- mode. + +If you are viewing this text in a GNU Emacs Buffer, you can type "M-2 C-x $" to +get an overview of just the questions. Then, when you want to look at the text +of the answers, just type "C-x $". + +To search for a question numbered XXX, type "M-C-s ^XXX:", followed by a C-r if +that doesn't work, then type ESC to end the search. + +1: How do I convert all of my Csh aliases over to Bash aliases? + Bash uses a different syntax to support aliases than Csh does. The + details can be found in the documentation. We have provided a shell + script which does most of the work of conversion for you; this + script can be found in ./examples/alias-conv.sh. Here is how you + use it: + + Start Csh in the normal way for you. (e.g., "csh") + + Pipe the output of "alias" through "alias-conv.sh", saving the + results into "bash_aliases": + + alias | alias-conv.sh >.bash_aliases + + Edit "bash_aliases" carefully reading through any created + functions. You will need to change the names of Csh specific + variables (like $cwd) to the Bash equivalents (like $PWD). You + will also need to remove recursive references to commands which + are defined as functions. For example, the Csh alias: + + alias cd 'cd \!*;echo $cwd' + + is converted to the Bash function: + + cd () + { + cd $*; + echo $cwd + } + + This function contains a self-pointing reference to "cd", which + should be changed to use the "builtin" version. It also uses + the Csh variable `$cwd' which has an equivalent in Bash. + Precede the recursive reference with the word "builtin", and + change the name of the variable: + + cd () { builtin cd $*; echo $PWD } + + Merge the edited file into your ~/.bashrc. + +2: Background jobs have staggered output, as if there was no CR before the LF. + This is a result of bash using the BSD-style tty driver on Ultrix. The BSD + driver ties input and output carriage return translation together with the + CRMOD bit. (The CRMOD bit causes CR->LF translation on input and LF->CRLF + translation on output.) Unless the CRMOD bit is cleared, it is impossible + to get a literal ^M in an input line. Unfortunately, one of the effects of + clearing it is the loss of output processing you've observed. + + The Ultrix Posix-style tty driver can't be used because it has serious + problems with losing typeahead when ICANON is switched on and off. These + characters seem to reappear later without warning, usually when a + program that uses the BSD-style ioctls turns on CBREAK (e.g., `more'). + +3: Bash's "test" different from "/bin/test"? ([ ! x -o x ] -> false) + Bash's builtin "test" implements the Posix.2 spec, which can be + summarized as follows (the wording is due to David Korn): + + Here is the set of rules for processing test arguments. + + 0 Args: False + 1 Arg: True iff argument is not null. + 2 Args: If first arg is !, True iff second argument is null. + If first argument is unary, then true if unary test is true + Otherwise error. + 3 Args: If second argument is a binary operator, do binary test of $1 $3 + If first argument is !, negate two argument test of $2 $3 + Otherwise error. + 4 Args: If first argument is !, negate three argument test of $2 $3 $4. + Otherwise unspecified + 5 or more Args: unspecified. (Historical shells would used their + current algorithm). + + The operators -a and -o are considered binary operators for the purpose + of the 3 Arg case. + + As you can see, the test becomes (not (x or x)), which is false. + +4: Completion listings can differ from `ls' in the number of columns output. + This can happen because `ls' calls stat () on every file before + listing the output, while GNU Readline only calls stat () on the + files when they are being printed. This means that `ls' knows how + many characters will be added to each filename in advance, and can + accurately calculate the maximum length, while Bash must assume that + each filename will have characters added to it. + +5: Bash crashes when I do "cd". + If you have `cd' defined as a function, it is likely that the + function is recursively calling itself. See the answer to question + 1 above. + +6: Why does Bash sometimes say "Broken pipe"? + If a sequence of commands appear in a pipeline, and one of the + reading commands finishes before the writer has finished, the writer + receives a SIGPIPE signal. Many other shells special-case SIGPIPE as + an exit status in the pipeline and do not report it. For example, + in: + + ps -aux | head + + `head' can finish before `ps' writes all of its output. In that case, + Bash will print `Broken pipe' to stderr on behalf of the `ps' + command. + +7: How can I use `!' to reinvoke a command starting with a digit? + If you had issued a command such as `8086engine foo', and then at a + later time wished to reinvoke the command, typing `!80' would probably + not work since Bash would think you meant the 80'th command in the + history, not the command starting with `80'. You can type `!?80', + which says to re-execute the most recent command containing `80'. + +Questions About Input Line Editing: + +1: What do things like this mean: C-h, M-C-a, RET, etc.? + + C-a means press the "a" key while holding down the "Control" key. The + ASCII code this sends will generally be the value that would be sent by + pressing just "a" minus 96 or 64. Either way it will be a number from 0 + to 31. + + M-a means press the "a" key while holding down the "Meta" key. The + ASCII code this sends is the sum of the ASCII code that would be sent by + pressing just "a" and 128. + + M-C-a means press the "a" key while holding down both the "Control" key + and the "Meta" key. C-M-a is a synonym for M-C-a. + + * RET means press the "Return" key. RET is the same as C-m. This sends + ASCII code 13. + + * LFD means press the "Linefeed" key. LFD is also the same as C-j. This + sends ASCII code 10. Under Unix, ASCII code 10 is more often called + "Newline". + + * DEL means press the "Delete" key. DEL is the same as C-?. This sends + ASCII code 127. (WARNING: It is a misnomer to call C-? a "control" key, + since 127 has both bits 6 and 7 turned ON, and the rule for control keys + is that they have 6 and 7 turned OFF. Also, on very few keyboards does + Control-? generate ASCII code 127. In fact, Control-? (which is + actually Control-Shift-/) is more likely to generate C-_, ASCII code + 31!) + + * ESC means press the "Escape" key. ESC is the same as C-[. This sends + ASCII code 27. + + * SPC means press the "Space" key. This send ASCII code 32. + + * TAB means press the "Tab" key. TAB is the same as C-i. This send ASCII + code 9. + + For C-@ and C-^, usually you don't have to hold down the shift key and you + can type Control-2 or Control-6 instead. For C-_, you may have to hold + down the shift key, typing Control-Shift-Hyphen. C-@ can often be + generated by typing Control-Space. C-@ is often called the NUL character, + and has ASCII value 0. C-_ can often be generated by typing Control-7 or + Control-/. Try Control with all of the digits on your keyboard to see + what gets generated. + + To read more about this online, type "C-h i m emacs RET m characters + RET", and also "C-h i m emacs RET m keys RET". + +2: What do you mean when you write things like this: type "ESC a"? + + I will enclose key sequences that are longer than one key inside double + quotes. These notations refer to single key strokes (some with + modifiers): + + C-x, M-x, M-C-x + RET, LFD, DEL, ESC, SPC, TAB + + I separate these from other keys within double quotes by spaces. Any + real spaces that I write inside double quotes can be ignored, only SPC + means press the space key. All other characters within double quotes + represent single keys (some shifted). + +3: What if I don't have a Meta key? + + Instead of typing M-a, you can type "ESC a" instead. In fact, Emacs + converts M-a internally into "ESC a" anyway (depending on the value of + meta-prefix-char). + +4: What if I don't have an Escape key? + + Type C-[ instead. This should send ASCII code 27 just like an Escape + key would. + +5: What does "M-x command" mean? + + "M-x command" means type M-x, then type the name of the command, then + + +Local Variables: +eval: (set-selective-display 2) +End: Index: PORTING =================================================================== RCS file: /cvsroot/winbash/winbash/support/PORTING,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- PORTING 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ PORTING 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,22 +1,22 @@ -if _mkfifo cannot be found, add "-DMKFIFO_MISSING" to SYSDEP_CFLAGS in -your machine's entry in machines.h. - -If bash compiles, but hangs when executing a non-builtin, there is a -problem with the defines in your /usr/include/sys/wait.h. If you -don't have one, there is a problem in our defines. At any rate, -perhaps you have a partially POSIX system, instead of a fully -operational one. Try defining _POSIX_SOURCE just before the inclusion -of <sys/wait.h> in jobs.h, and then undefining it immediately after -the inclusion. - -Finding out if your system has something (like setpgid, for example) -You can always do "nm -o /lib/*.a | grep setpgid". If an entry for -the function appears, you have it, and you might have to link with -that library by adding "#defined REQUIRED_LIBRARIES -lfoo" to the -entry in machines.h. - -If you seem to be going around in circles, and they are related to -job control and posixness, try #undef HAVE_UNISTD_H in the entry for -your machine in machines.h. This can work by keeping unistd.h from -defining _POSIX_VERSION, which in turn prevents bash from assuming -full Posix semantics. +if _mkfifo cannot be found, add "-DMKFIFO_MISSING" to SYSDEP_CFLAGS in +your machine's entry in machines.h. + +If bash compiles, but hangs when executing a non-builtin, there is a +problem with the defines in your /usr/include/sys/wait.h. If you +don't have one, there is a problem in our defines. At any rate, +perhaps you have a partially POSIX system, instead of a fully +operational one. Try defining _POSIX_SOURCE just before the inclusion +of <sys/wait.h> in jobs.h, and then undefining it immediately after +the inclusion. + +Finding out if your system has something (like setpgid, for example) +You can always do "nm -o /lib/*.a | grep setpgid". If an entry for +the function appears, you have it, and you might have to link with +that library by adding "#defined REQUIRED_LIBRARIES -lfoo" to the +entry in machines.h. + +If you seem to be going around in circles, and they are related to +job control and posixness, try #undef HAVE_UNISTD_H in the entry for +your machine in machines.h. This can work by keeping unistd.h from +defining _POSIX_VERSION, which in turn prevents bash from assuming +full Posix semantics. Index: SYMLINKS =================================================================== RCS file: /cvsroot/winbash/winbash/support/SYMLINKS,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- SYMLINKS 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ SYMLINKS 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,23 +1,23 @@ -# -# symlink map for bash source tree -# -# link name link target -# -lib/readline/doc/texindex.c ../../doc-support/texindex.c -# -lib/readline/tilde.c ../tilde/tilde.c -lib/readline/tilde.h ../tilde/tilde.h -lib/readline/posixstat.h ../posixheaders/posixstat.h -lib/readline/ansi_stdlib.h ../posixheaders/ansi_stdlib.h -lib/readline/memalloc.h ../posixheaders/memalloc.h -lib/readline/xmalloc.c ../malloc/xmalloc.c -# -lib/tilde/memalloc.h ../posixheaders/memalloc.h -# -lib/doc-support/getopt.h ../../builtins/getopt.h -# -posixstat.h lib/posixheaders/posixstat.h -ansi_stdlib.h lib/posixheaders/ansi_stdlib.h -stdc.h lib/posixheaders/stdc.h -memalloc.h lib/posixheaders/memalloc.h -filecntl.h lib/posixheaders/filecntl.h +# +# symlink map for bash source tree +# +# link name link target +# +lib/readline/doc/texindex.c ../../doc-support/texindex.c +# +lib/readline/tilde.c ../tilde/tilde.c +lib/readline/tilde.h ../tilde/tilde.h +lib/readline/posixstat.h ../posixheaders/posixstat.h +lib/readline/ansi_stdlib.h ../posixheaders/ansi_stdlib.h +lib/readline/memalloc.h ../posixheaders/memalloc.h +lib/readline/xmalloc.c ../malloc/xmalloc.c +# +lib/tilde/memalloc.h ../posixheaders/memalloc.h +# +lib/doc-support/getopt.h ../../builtins/getopt.h +# +posixstat.h lib/posixheaders/posixstat.h +ansi_stdlib.h lib/posixheaders/ansi_stdlib.h +stdc.h lib/posixheaders/stdc.h +memalloc.h lib/posixheaders/memalloc.h +filecntl.h lib/posixheaders/filecntl.h Index: bash.xbm =================================================================== RCS file: /cvsroot/winbash/winbash/support/bash.xbm,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bash.xbm 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ bash.xbm 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,59 +1,59 @@ -From: Simon Marshall <sm...@se...> -Date: Wed, 8 May 91 17:15:58 +0100 -To: bug...@ai... -Subject: X bitmap for bash - - Since other GNU software comes with its very own X bitmap, I - thought it was about time bash had one too & here it is! To use, - stick the stuff after my signature in a file <path>/bash.xbm. If - using a twm window manager, insert the lines: - -IconDirectory "<path>" -Icons { - "<xterm title>" "bash.xbm" -} - in your ~/.twmrc file. The <xterm title> can be a prefix, so if - you have titles "bash@machine", the prefix "bash" will do. I'm not - familiar enough with other window managers, but they should be - similar. - - If you like it, you're welcome to it... - - Simon. - -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -#define bash_width 64 -#define bash_height 48 -static char bash_bits[] = { - 0x00, 0x60, 0x06, 0x30, 0x04, 0x00, 0x00, 0x00, 0x60, 0x98, 0x01, 0x40, - 0x03, 0x00, 0x00, 0x00, 0x19, 0x00, 0xa0, 0x80, 0x80, 0xff, 0x00, 0x00, - 0x06, 0x00, 0x1c, 0x03, 0xe1, 0x5f, 0x03, 0x00, 0x02, 0x00, 0x22, 0x0c, - 0x5d, 0xf4, 0x0e, 0x00, 0xe1, 0x02, 0x09, 0x19, 0x17, 0x91, 0x3d, 0x00, - 0xf8, 0x87, 0x40, 0x90, 0x88, 0x88, 0x6e, 0x00, 0x8e, 0x9b, 0x04, 0x62, - 0x22, 0x22, 0xd6, 0x00, 0x02, 0xee, 0x4c, 0x68, 0x44, 0x44, 0x6c, 0x01, - 0x02, 0xf8, 0xa1, 0x4a, 0x11, 0x11, 0xb1, 0x02, 0x05, 0xa0, 0x22, 0xe0, - 0x88, 0x88, 0x68, 0x03, 0x42, 0x50, 0x5d, 0x40, 0x22, 0x22, 0xa2, 0x05, - 0x11, 0x81, 0x00, 0x44, 0x44, 0x44, 0x44, 0x07, 0x02, 0x20, 0x84, 0x60, - 0x11, 0x11, 0xd1, 0x0d, 0x02, 0x0a, 0x02, 0xc0, 0x88, 0x88, 0x48, 0x0b, - 0x44, 0x40, 0x00, 0x42, 0x22, 0x22, 0xa2, 0x1d, 0x24, 0x08, 0x02, 0x64, - 0x44, 0x44, 0xc4, 0x1a, 0x08, 0x00, 0x20, 0x20, 0x11, 0x11, 0x91, 0x15, - 0x88, 0x00, 0x00, 0xe1, 0xff, 0xff, 0xff, 0x1a, 0x10, 0x08, 0x22, 0x10, - 0x00, 0x00, 0xc0, 0x15, 0x31, 0x40, 0x00, 0xf2, 0x03, 0xc0, 0xc1, 0x1a, - 0x41, 0x24, 0x48, 0x6c, 0x06, 0x80, 0xc1, 0x15, 0x82, 0x01, 0x00, 0x66, - 0x06, 0x80, 0xc1, 0x1a, 0x04, 0x22, 0x12, 0x67, 0x06, 0x80, 0xc1, 0x15, - 0x0a, 0x04, 0xe0, 0x66, 0xe6, 0xb8, 0xc7, 0x1a, 0x09, 0xf0, 0x17, 0xee, - 0xb3, 0xa5, 0xcf, 0x15, 0x30, 0x00, 0x00, 0x6e, 0x86, 0x8d, 0xcd, 0x1a, - 0x00, 0x01, 0x80, 0x67, 0xe6, 0xbd, 0xcd, 0x15, 0x00, 0x46, 0x40, 0x66, - 0xb6, 0xb1, 0xcd, 0x1a, 0x00, 0x38, 0x3c, 0x66, 0xb6, 0xa5, 0xcd, 0x15, - 0x00, 0x00, 0x02, 0xf6, 0xe3, 0x9d, 0xdd, 0x1a, 0x00, 0x04, 0x60, 0x06, - 0x00, 0x00, 0xc0, 0x15, 0x00, 0x04, 0x40, 0xfe, 0xff, 0xff, 0xff, 0x1a, - 0x00, 0x02, 0x80, 0x12, 0x11, 0x11, 0x91, 0x15, 0x00, 0x00, 0x00, 0x8a, - 0x88, 0x88, 0x88, 0x1a, 0x00, 0x00, 0x00, 0x22, 0x22, 0x22, 0xa2, 0x15, - 0x00, 0x00, 0x00, 0x46, 0x44, 0x44, 0xc4, 0x9a, 0x00, 0x00, 0x00, 0x12, - 0x11, 0x11, 0x91, 0xb5, 0x00, 0x00, 0x10, 0x8a, 0x88, 0x88, 0x88, 0xba, - 0x00, 0x00, 0x10, 0x22, 0x22, 0x22, 0xa2, 0xd5, 0x00, 0x00, 0x30, 0xc6, - 0x44, 0x44, 0xcc, 0xdf, 0x00, 0x20, 0x39, 0x96, 0x15, 0x51, 0x99, 0xf5, - 0x80, 0xf2, 0x56, 0x8b, 0x9a, 0xea, 0x9b, 0xff, 0xc1, 0xad, 0x5e, 0xaf, - 0xbb, 0xfa, 0xba, 0xdf, 0x22, 0x9b, 0xae, 0xd7, 0x54, 0x5d, 0xd7, 0xbf, - 0x3b, 0x32, 0xce, 0xff, 0xff, 0xff, 0xff, 0xab, 0xae, 0x2b, 0x59, 0xaf, - 0xd4, 0xae, 0x2e, 0xc3, 0xdd, 0x43, 0xa9, 0xd1, 0xba, 0xae, 0x2c, 0xcd}; +From: Simon Marshall <sm...@se...> +Date: Wed, 8 May 91 17:15:58 +0100 +To: bug...@ai... +Subject: X bitmap for bash + + Since other GNU software comes with its very own X bitmap, I + thought it was about time bash had one too & here it is! To use, + stick the stuff after my signature in a file <path>/bash.xbm. If + using a twm window manager, insert the lines: + +IconDirectory "<path>" +Icons { + "<xterm title>" "bash.xbm" +} + in your ~/.twmrc file. The <xterm title> can be a prefix, so if + you have titles "bash@machine", the prefix "bash" will do. I'm not + familiar enough with other window managers, but they should be + similar. + + If you like it, you're welcome to it... + + Simon. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +#define bash_width 64 +#define bash_height 48 +static char bash_bits[] = { + 0x00, 0x60, 0x06, 0x30, 0x04, 0x00, 0x00, 0x00, 0x60, 0x98, 0x01, 0x40, + 0x03, 0x00, 0x00, 0x00, 0x19, 0x00, 0xa0, 0x80, 0x80, 0xff, 0x00, 0x00, + 0x06, 0x00, 0x1c, 0x03, 0xe1, 0x5f, 0x03, 0x00, 0x02, 0x00, 0x22, 0x0c, + 0x5d, 0xf4, 0x0e, 0x00, 0xe1, 0x02, 0x09, 0x19, 0x17, 0x91, 0x3d, 0x00, + 0xf8, 0x87, 0x40, 0x90, 0x88, 0x88, 0x6e, 0x00, 0x8e, 0x9b, 0x04, 0x62, + 0x22, 0x22, 0xd6, 0x00, 0x02, 0xee, 0x4c, 0x68, 0x44, 0x44, 0x6c, 0x01, + 0x02, 0xf8, 0xa1, 0x4a, 0x11, 0x11, 0xb1, 0x02, 0x05, 0xa0, 0x22, 0xe0, + 0x88, 0x88, 0x68, 0x03, 0x42, 0x50, 0x5d, 0x40, 0x22, 0x22, 0xa2, 0x05, + 0x11, 0x81, 0x00, 0x44, 0x44, 0x44, 0x44, 0x07, 0x02, 0x20, 0x84, 0x60, + 0x11, 0x11, 0xd1, 0x0d, 0x02, 0x0a, 0x02, 0xc0, 0x88, 0x88, 0x48, 0x0b, + 0x44, 0x40, 0x00, 0x42, 0x22, 0x22, 0xa2, 0x1d, 0x24, 0x08, 0x02, 0x64, + 0x44, 0x44, 0xc4, 0x1a, 0x08, 0x00, 0x20, 0x20, 0x11, 0x11, 0x91, 0x15, + 0x88, 0x00, 0x00, 0xe1, 0xff, 0xff, 0xff, 0x1a, 0x10, 0x08, 0x22, 0x10, + 0x00, 0x00, 0xc0, 0x15, 0x31, 0x40, 0x00, 0xf2, 0x03, 0xc0, 0xc1, 0x1a, + 0x41, 0x24, 0x48, 0x6c, 0x06, 0x80, 0xc1, 0x15, 0x82, 0x01, 0x00, 0x66, + 0x06, 0x80, 0xc1, 0x1a, 0x04, 0x22, 0x12, 0x67, 0x06, 0x80, 0xc1, 0x15, + 0x0a, 0x04, 0xe0, 0x66, 0xe6, 0xb8, 0xc7, 0x1a, 0x09, 0xf0, 0x17, 0xee, + 0xb3, 0xa5, 0xcf, 0x15, 0x30, 0x00, 0x00, 0x6e, 0x86, 0x8d, 0xcd, 0x1a, + 0x00, 0x01, 0x80, 0x67, 0xe6, 0xbd, 0xcd, 0x15, 0x00, 0x46, 0x40, 0x66, + 0xb6, 0xb1, 0xcd, 0x1a, 0x00, 0x38, 0x3c, 0x66, 0xb6, 0xa5, 0xcd, 0x15, + 0x00, 0x00, 0x02, 0xf6, 0xe3, 0x9d, 0xdd, 0x1a, 0x00, 0x04, 0x60, 0x06, + 0x00, 0x00, 0xc0, 0x15, 0x00, 0x04, 0x40, 0xfe, 0xff, 0xff, 0xff, 0x1a, + 0x00, 0x02, 0x80, 0x12, 0x11, 0x11, 0x91, 0x15, 0x00, 0x00, 0x00, 0x8a, + 0x88, 0x88, 0x88, 0x1a, 0x00, 0x00, 0x00, 0x22, 0x22, 0x22, 0xa2, 0x15, + 0x00, 0x00, 0x00, 0x46, 0x44, 0x44, 0xc4, 0x9a, 0x00, 0x00, 0x00, 0x12, + 0x11, 0x11, 0x91, 0xb5, 0x00, 0x00, 0x10, 0x8a, 0x88, 0x88, 0x88, 0xba, + 0x00, 0x00, 0x10, 0x22, 0x22, 0x22, 0xa2, 0xd5, 0x00, 0x00, 0x30, 0xc6, + 0x44, 0x44, 0xcc, 0xdf, 0x00, 0x20, 0x39, 0x96, 0x15, 0x51, 0x99, 0xf5, + 0x80, 0xf2, 0x56, 0x8b, 0x9a, 0xea, 0x9b, 0xff, 0xc1, 0xad, 0x5e, 0xaf, + 0xbb, 0xfa, 0xba, 0xdf, 0x22, 0x9b, 0xae, 0xd7, 0x54, 0x5d, 0xd7, 0xbf, + 0x3b, 0x32, 0xce, 0xff, 0xff, 0xff, 0xff, 0xab, 0xae, 0x2b, 0x59, 0xaf, + 0xd4, 0xae, 0x2e, 0xc3, 0xdd, 0x43, 0xa9, 0xd1, 0xba, 0xae, 0x2c, 0xcd}; Index: bashbug.sh =================================================================== RCS file: /cvsroot/winbash/winbash/support/bashbug.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bashbug.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ bashbug.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,72 +1,72 @@ -#!/bin/sh - -# -# bashbug - create a bug report and mail it to bug...@pr... -# -# configuration section: -# these variables are filled in by the make target in cpp-Makefile -# -MACHINE="@MACHINE@" -OS="@OS@" -CC="@CC@" -CFLAGS="@CFLAGS@" -RELEASE="@RELEASE@" -PATCHLEVEL="@PATCHLEVEL@" - -PATH=/bin:/usr/bin:usr/local/bin:$PATH -export PATH - -TEMP=/tmp/bashbug.$$ - -BUGADDR=${1:-bu...@pr...} - -: ${EDITOR=emacs} - -trap 'rm -f $TEMP $TEMP.x; exit 1' 1 2 3 13 15 -trap 'rm -f $TEMP $TEMP.x' 0 - -UN= -if (uname) >/dev/null 2>&1; then - UN=`uname -a` -fi - -cat > $TEMP <<EOF -To: ${BUGADDR} -Subject: [50 character or so descriptive subject here (for reference)] - -Configuration Information [Automatically generated, do not change]: -Machine: $MACHINE -OS: $OS -Compiler: $CC -Compilation CFLAGS: $CFLAGS -uname output: $UN - -Bash Version: $RELEASE -Patch Level: $PATCHLEVEL - -Description: - [Detailed description of the problem, suggestion, or complaint.] - -Repeat-By: - [Describe the sequence of events that causes the problem - to occur.] - -Fix: - [Description of how to fix the problem. If you don't know a - fix for the problem, don't include this section.] -EOF - -chmod u+w $TEMP -cp $TEMP $TEMP.x - -if $EDITOR $TEMP -then - if cmp -s $TEMP $TEMP.x - then - echo "File not changed, no bug report submitted." - exit - fi - - rmail $BUGADDR < $TEMP || cat $TEMP >> $HOME/dead.bashbug -fi - -exit 0 +#!/bin/sh - +# +# bashbug - create a bug report and mail it to bug...@pr... +# +# configuration section: +# these variables are filled in by the make target in cpp-Makefile +# +MACHINE="@MACHINE@" +OS="@OS@" +CC="@CC@" +CFLAGS="@CFLAGS@" +RELEASE="@RELEASE@" +PATCHLEVEL="@PATCHLEVEL@" + +PATH=/bin:/usr/bin:usr/local/bin:$PATH +export PATH + +TEMP=/tmp/bashbug.$$ + +BUGADDR=${1:-bu...@pr...} + +: ${EDITOR=emacs} + +trap 'rm -f $TEMP $TEMP.x; exit 1' 1 2 3 13 15 +trap 'rm -f $TEMP $TEMP.x' 0 + +UN= +if (uname) >/dev/null 2>&1; then + UN=`uname -a` +fi + +cat > $TEMP <<EOF +To: ${BUGADDR} +Subject: [50 character or so descriptive subject here (for reference)] + +Configuration Information [Automatically generated, do not change]: +Machine: $MACHINE +OS: $OS +Compiler: $CC +Compilation CFLAGS: $CFLAGS +uname output: $UN + +Bash Version: $RELEASE +Patch Level: $PATCHLEVEL + +Description: + [Detailed description of the problem, suggestion, or complaint.] + +Repeat-By: + [Describe the sequence of events that causes the problem + to occur.] + +Fix: + [Description of how to fix the problem. If you don't know a + fix for the problem, don't include this section.] +EOF + +chmod u+w $TEMP +cp $TEMP $TEMP.x + +if $EDITOR $TEMP +then + if cmp -s $TEMP $TEMP.x + then + echo "File not changed, no bug report submitted." + exit + fi + + rmail $BUGADDR < $TEMP || cat $TEMP >> $HOME/dead.bashbug +fi + +exit 0 Index: cat-s =================================================================== RCS file: /cvsroot/winbash/winbash/support/cat-s,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- cat-s 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ cat-s 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,16 +1,16 @@ -# This awk script is called from within Makefile to strip multiple blank -# lines from stdin. -BEGIN { newlines = 0 } -{ - if (NF == 0) - newlines = 1; - else - { - if (newlines) - { - printf "\n"; - newlines = 0; - } - print $0; - } -} +# This awk script is called from within Makefile to strip multiple blank +# lines from stdin. +BEGIN { newlines = 0 } +{ + if (NF == 0) + newlines = 1; + else + { + if (newlines) + { + printf "\n"; + newlines = 0; + } + print $0; + } +} Index: clone-bash =================================================================== RCS file: /cvsroot/winbash/winbash/support/clone-bash,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- clone-bash 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ clone-bash 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,95 +1,95 @@ -#! /bin/sh -# -# -src=src -case "$1" in --s) shift; src=$1; shift ;; -esac - -if [ ! -d $1 ]; then - mkdir $1 -fi - -prog=`basename $0` - -echo "${prog}: creating clone of bash source tree (from $src) in $1" - -case $src in -/*) abs=yes ;; -esac - -d=${PWD-`pwd`} - -cd $1 || { echo "$0: cannot cd to $1" ; exit 1; } - -d=$d/$1 - -SUBDIRS="CWRU builtins documentation examples support tests" -LIBDIRS="malloc termcap glob readline tilde malloclib posixheaders doc-support" -CWRUDIRS="misc" - -mkdir $SUBDIRS -for i in $SUBDIRS -do - cd $i - case "$abs" in - yes) ln -s $src/$i/* . ;; - *) ln -s ../../$src/$i/* . ;; - esac - echo -n $i.. - cd .. -done -cd $d - -cd CWRU -for i in $CWRUDIRS -do - rm -f $i - mkdir $i - cd $i - case "$abs" in - yes) ln -s $src/CWRU/$i/* . ;; - *) ln -s ../../../$src/CWRU/$i/* . ;; - esac - echo -n "CWRU/$i.." - cd .. -done -cd $d - -if [ ! -d lib ] ; then - mkdir lib -fi - -cd lib -mkdir $LIBDIRS - -for i in $LIBDIRS -do - cd $i - case "$abs" in - yes) ln -s $src/lib/$i/* . ;; - *) ln -s ../../../$src/lib/$i/* . ;; - esac - echo -n "lib/$i.." - cd .. -done - -cd $d - -case "$abs" in -yes) ln -s $src/.[a-z]* . ; ln -s $src/* . 2>&1 | grep -v exists ;; -*) ln -s ../$src/.[a-z]* . ; ln -s ../$src/* . 2>&1 | grep -v exists ;; -esac - -echo -n src.. - -SPECIAL="parser-built y.tab.h y.tab.c" -for x in $SPECIAL -do - rm -f $x - cp ../$src/$x . -done - -echo special - -exit 0 +#! /bin/sh +# +# +src=src +case "$1" in +-s) shift; src=$1; shift ;; +esac + +if [ ! -d $1 ]; then + mkdir $1 +fi + +prog=`basename $0` + +echo "${prog}: creating clone of bash source tree (from $src) in $1" + +case $src in +/*) abs=yes ;; +esac + +d=${PWD-`pwd`} + +cd $1 || { echo "$0: cannot cd to $1" ; exit 1; } + +d=$d/$1 + +SUBDIRS="CWRU builtins documentation examples support tests" +LIBDIRS="malloc termcap glob readline tilde malloclib posixheaders doc-support" +CWRUDIRS="misc" + +mkdir $SUBDIRS +for i in $SUBDIRS +do + cd $i + case "$abs" in + yes) ln -s $src/$i/* . ;; + *) ln -s ../../$src/$i/* . ;; + esac + echo -n $i.. + cd .. +done +cd $d + +cd CWRU +for i in $CWRUDIRS +do + rm -f $i + mkdir $i + cd $i + case "$abs" in + yes) ln -s $src/CWRU/$i/* . ;; + *) ln -s ../../../$src/CWRU/$i/* . ;; + esac + echo -n "CWRU/$i.." + cd .. +done +cd $d + +if [ ! -d lib ] ; then + mkdir lib +fi + +cd lib +mkdir $LIBDIRS + +for i in $LIBDIRS +do + cd $i + case "$abs" in + yes) ln -s $src/lib/$i/* . ;; + *) ln -s ../../../$src/lib/$i/* . ;; + esac + echo -n "lib/$i.." + cd .. +done + +cd $d + +case "$abs" in +yes) ln -s $src/.[a-z]* . ; ln -s $src/* . 2>&1 | grep -v exists ;; +*) ln -s ../$src/.[a-z]* . ; ln -s ../$src/* . 2>&1 | grep -v exists ;; +esac + +echo -n src.. + +SPECIAL="parser-built y.tab.h y.tab.c" +for x in $SPECIAL +do + rm -f $x + cp ../$src/$x . +done + +echo special + +exit 0 Index: cppmagic =================================================================== RCS file: /cvsroot/winbash/winbash/support/cppmagic,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- cppmagic 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ cppmagic 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,51 +1,51 @@ -#!/bin/sh -# Return a full cpp specification, complete with system dependent flags. -# -# Syntax: cppmagic [ program-to-generate-flags [ guessed-cpp ]] -# -# If only one arg is present it is the name of a program to invoke -# which should generate -Dfoo defines. -# -# If two args are present the second arg is the name of the C -# preprocessor to use. -# -# Invoked with no args, provides a C preprocessor name and -# -traditional flag if that is appropriate. -# -# ../Makefile calls this file thusly: "cppmagic getcppsyms". -# -# Typical output: -# -# /lib/cpp -Dunix -Dm68k -# - -Cpp= - -if [ "$2" ]; then - Cpp=$2 -else - for cpp in /lib/cpp /usr/lib/cpp /usr/ccs/lib/cpp; do - if [ -f $cpp ]; then - Cpp=$cpp - fi - done - if [ "$Cpp" = "" ]; then - Cpp=cpp - fi -fi - -TRADITIONAL= -FLAGS= - -# First flag might be `-traditional' if this is Gnu Cpp. -unknown_flag=`$Cpp -traditional /dev/null 2>&1 | - egrep 'known|recognized|valid|bad|legal'` -if [ "$unknown_flag" = "" ]; then - TRADITIONAL=-traditional -fi - -if [ "$1" ]; then - FLAGS=`$1` -fi - -echo $Cpp $TRADITIONAL $FLAGS +#!/bin/sh +# Return a full cpp specification, complete with system dependent flags. +# +# Syntax: cppmagic [ program-to-generate-flags [ guessed-cpp ]] +# +# If only one arg is present it is the name of a program to invoke +# which should generate -Dfoo defines. +# +# If two args are present the second arg is the name of the C +# preprocessor to use. +# +# Invoked with no args, provides a C preprocessor name and +# -traditional flag if that is appropriate. +# +# ../Makefile calls this file thusly: "cppmagic getcppsyms". +# +# Typical output: +# +# /lib/cpp -Dunix -Dm68k +# + +Cpp= + +if [ "$2" ]; then + Cpp=$2 +else + for cpp in /lib/cpp /usr/lib/cpp /usr/ccs/lib/cpp; do + if [ -f $cpp ]; then + Cpp=$cpp + fi + done + if [ "$Cpp" = "" ]; then + Cpp=cpp + fi +fi + +TRADITIONAL= +FLAGS= + +# First flag might be `-traditional' if this is Gnu Cpp. +unknown_flag=`$Cpp -traditional /dev/null 2>&1 | + egrep 'known|recognized|valid|bad|legal'` +if [ "$unknown_flag" = "" ]; then + TRADITIONAL=-traditional +fi + +if [ "$1" ]; then + FLAGS=`$1` +fi + +echo $Cpp $TRADITIONAL $FLAGS Index: fixlinks =================================================================== RCS file: /cvsroot/winbash/winbash/support/fixlinks,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- fixlinks 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ fixlinks 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,61 +1,61 @@ -#! /bin/sh -# -# fixlinks - make symlinks in the bash source tree so that there is -# exactly one version of any given source file. -# -# - -SRCDIR=. -while [ $# -gt 0 ]; do - case "$1" in - -s) shift; SRCDIR=$1 ;; - -u) unfix=yes ;; - -*) echo "$0: $1: bad option" 1>&2 - echo "$0: usage: $0 [-u] [-s srcdir] [linkmap]" 1>&2 - exit 1;; - *) break ;; - esac - shift -done - -if [ ! -d $SRCDIR/builtins ]; then - echo "$0: must be run with valid -s argument or from source directory" 1>&2 - exit 1 -fi - -if [ $# -eq 0 ]; then - linkfile=$SRCDIR/support/SYMLINKS -else - linkfile=$1 -fi - -if [ ! -f "$linkfile" ]; then - echo "$0: symlink map file \`$linkfile' does not exist" - exit 1 -fi - -rm -f /tmp/z -if (ln -s /dev/null /tmp/z) >/dev/null 2>&1; then - LN="ln -s" -else - LN=ln -fi - -while read name target -do - case "$name" in - \#*) continue;; - esac - - rm -f $name - case "$unfix" in - yes) dirname=`expr "$name" ':' '^\(.*\)/[^/]*'` - [ -z "$dirname" ] && dirname=. - cp $dirname/$target $name - echo $target copied to $name ;; - *) $LN $target $name ; echo "$name -> $target" ;; - esac - -done < $linkfile - -exit 0 +#! /bin/sh +# +# fixlinks - make symlinks in the bash source tree so that there is +# exactly one version of any given source file. +# +# + +SRCDIR=. +while [ $# -gt 0 ]; do + case "$1" in + -s) shift; SRCDIR=$1 ;; + -u) unfix=yes ;; + -*) echo "$0: $1: bad option" 1>&2 + echo "$0: usage: $0 [-u] [-s srcdir] [linkmap]" 1>&2 + exit 1;; + *) break ;; + esac + shift +done + +if [ ! -d $SRCDIR/builtins ]; then + echo "$0: must be run with valid -s argument or from source directory" 1>&2 + exit 1 +fi + +if [ $# -eq 0 ]; then + linkfile=$SRCDIR/support/SYMLINKS +else + linkfile=$1 +fi + +if [ ! -f "$linkfile" ]; then + echo "$0: symlink map file \`$linkfile' does not exist" + exit 1 +fi + +rm -f /tmp/z +if (ln -s /dev/null /tmp/z) >/dev/null 2>&1; then + LN="ln -s" +else + LN=ln +fi + +while read name target +do + case "$name" in + \#*) continue;; + esac + + rm -f $name + case "$unfix" in + yes) dirname=`expr "$name" ':' '^\(.*\)/[^/]*'` + [ -z "$dirname" ] && dirname=. + cp $dirname/$target $name + echo $target copied to $name ;; + *) $LN $target $name ; echo "$name -> $target" ;; + esac + +done < $linkfile + +exit 0 Index: getcppsyms.c =================================================================== RCS file: /cvsroot/winbash/winbash/support/getcppsyms.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- getcppsyms.c 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ getcppsyms.c 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,425 +1,425 @@ -/* getcppsyms.c - Find unique compiler symbols. */ - -/* Copyright (C) 1993 Free Software Foundation, Inc. - - This file is part of GNU Bash, the Bourne Again SHell. - - Bash is free software; you can redistribute it and/or modify it under - the terms of the GNU General Public License as published by the Free - Software Foundation; either version 2, or (at your option) any later - version. - - Bash is distributed in the hope that it will be useful, but WITHOUT ANY - WARRANTY; without even the implied warranty of MERCHANTABILITY or - FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - for more details. - - You should have received a copy of the GNU General Public License along - with Bash; see the file COPYING. If not, write to the Free Software - Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ - -/* Some cpp's do not define any symbols, but instead let /bin/cc do it - for them. For such machines, running this file may prove useful. It - outputs the list of symbols which /bin/cc or /lib/cpp define and which - we had the foresight to guess at. */ - -#include <stdio.h> -main () -{ -#if defined (__BSD_4_4__) - printf ("-D__BSD_4_4__"); -#endif /* __BSD_4_4__ */ -#if defined (CMU) - printf (" -DCMU"); -#endif /* CMU */ -#if defined (_COFF) - printf (" -D_COFF"); -#endif /* _COFF */ -#if defined (DGUX) - printf (" -DDGUX"); -#endif /* DGUX */ -#if defined (GOULD_PN) - printf (" -DGOULD_PN"); -#endif /* GOULD_PN */ -#if defined (MACH) - printf (" -DMACH"); -#endif /* MACH */ -#if defined (MIPSEB) - printf (" -DMIPSEB"); -#endif /* MIPSEB */ -#if defined (MIPSEL) - printf (" -DMIPSEL"); -#endif /* MIPSEL */ -#if defined (MULTIMAX) - printf (" -DMULTIMAX"); -#endif /* MULTIMAX */ -#if defined (M_UNIX) - printf (" -DM_UNIX"); -#endif /* M_UNIX */ -#if defined (M_XENIX) - printf (" -DM_XENIX"); -#endif /* M_XENIX */ -#if defined (_M_XENIX) - printf (" -D_M_XENIX"); -#endif /* _M_XENIX */ -#if defined (NeXT) - printf (" -DNeXT"); -#endif /* NeXT */ -#if defined (__PARAGON__) - printf (" -D__PARAGON__"); -#endif /* __PARAGON__ */ -#if defined (_PGC_) - printf (" -D_PGC_"); -#endif /* _PGC_ */ -#if defined (__PGC__) - printf (" -D__PGC__"); -#endif /* __PGC__ */ -#if defined (RES) - printf (" -DRES"); -#endif /* RES */ -#if defined (RISC6000) - printf (" -DRISC6000"); -#endif /* RISC6000 */ -#if defined (RT) - printf (" -DRT"); -#endif /* RT */ -#if defined (SYSTYPE_BSD) - printf (" -DSYSTYPE_BSD"); -#endif /* SYSTYPE_BSD */ -#if defined (SYSTYPE_SYSV) - printf (" -DSYSTYPE_SYSV"); -#endif /* SYSTYPE_SYSV */ -#if defined (Sun386i) - printf (" -DSun386i"); -#endif /* Sun386i */ -#if defined (Tek4132) - printf (" -DTek4132"); -#endif /* Tek4132 */ -#if defined (Tek4300) - printf (" -DTek4300"); -#endif /* Tek4300 */ -#if defined (UMAXV) - printf (" -DUMAXV"); -#endif /* UMAXV */ -#if defined (USGr4) - printf (" -DUSGr4"); -#endif /* USGr4 */ -#if defined (USGr4_2) - printf (" -DUSGr4_2"); -#endif /* USGr4_2 */ -#if defined (__SVR4_2__) - printf (" -D__SVR4_2__"); -#endif /* __SVR4_2__ */ -#if defined (Xenix286) - printf (" -DXenix286"); -#endif /* Xenix286 */ -#if defined (_AIX) - printf (" -D_AIX"); -#endif /* _AIX */ -#if defined (_AIX370) - printf (" -D_AIX370"); -#endif /* _AIX370 */ -#if defined (_IBMESA) - printf (" -D_IBMESA"); -#endif /* _IBMESA */ -#if defined (__ibmesa) - printf (" -D__ibmesa"); -#endif /* __ibmesa */ -#if defined (_U370) - printf (" -D_U370"); -#endif /* _U370 */ -#if defined (_NLS) - printf (" -D_NLS"); -#endif /* _NLS */ -#if defined (_CX_UX) - printf (" -D_CX_UX"); -#endif /* _CX_UX */ -#if defined (_IBMR2) - printf (" -D_IBMR2"); -#endif /* _IBMR2 */ -#if defined (_M88K) - printf (" -D_M88K"); -#endif /* _M88K */ -#if defined (_M88KBCS_TARGET) - printf (" -D_M88KBCS_TARGET"); -#endif /* _M88KBCS_TARGET */ -#if defined (__DGUX__) - printf (" -D__DGUX__"); -#endif /* __DGUX__ */ -#if defined (__UMAXV__) - printf (" -D__UMAXV__"); -#endif /* __UMAXV__ */ -#if defined (__m88k) - printf (" -D__m88k"); -#endif /* __m88k */ -#if defined (__uxpm__) - printf (" -DUSGr4 -Du370 -D__uxpm__"); -#endif /* __uxpm__ */ -#if defined (__uxps__) - printf (" -D__svr4__ -D__uxps__"); -#endif /* __uxps__ */ -#if defined (alliant) - printf (" -Dalliant"); -#endif /* alliant */ -#if defined (alpha) - printf (" -Dalpha"); -#endif /* alpha */ -#if defined (__alpha) - printf (" -D__alpha"); -#endif /* __alpha */ -#if defined (aix) - printf (" -Daix"); -#endif /* aix */ -#if defined (aixpc) - printf (" -Daixpc"); -#endif /* aixpc */ -#if defined (apollo) - printf (" -Dapollo"); -#endif /* apollo */ -#if defined (ardent) - printf (" -Dardent"); -#endif /* ardent */ -#if defined (att386) - printf (" -Datt386"); -#endif /* att386 */ -#if defined (att3b) - printf (" -Datt3b"); -#endif /* att3b */ -#if defined (bsd4_2) - printf (" -Dbsd4_2"); -#endif /* bsd4_2 */ -#if defined (bsd4_3) - printf (" -Dbsd4_3"); -#endif /* bsd4_3 */ -#if defined (__bsdi__) - printf (" -D__bsdi__"); -#endif /* __bsdi__ */ -#if defined (bsdi) - printf (" -Dbsdi"); -#endif /* bsdi */ -#if defined (__386BSD__) - printf (" -D__386BSD__"); -#endif /* __386BSD__ */ -#if defined (cadmus) - printf (" -Dcadmus"); -#endif /* cadmus */ -#if defined (clipper) - printf (" -Dclipper"); -#endif /* clipper */ -#if defined (concurrent) - printf (" -Dconcurrent"); -#endif /* concurrent */ -#if defined (convex) || defined (__convex__) || defined (__convexc__) -# if !defined (__GNUC__) - printf (" -pcc"); -# endif /* !__GNUC__ */ - printf (" -Dconvex"); -#endif /* convex */ -#if defined (dmert) - printf (" -Ddmert"); -#endif /* dmert */ -#if defined (gcos) - printf (" -Dgcos"); -#endif /* gcos */ -#if defined (gcx) - printf (" -Dgcx"); -#endif /* gcx */ -#if defined (gould) - printf (" -Dgould"); -#endif /* gould */ -#if defined (hbullx20) - printf (" -Dhbullx20"); -#endif /* hbullx20 */ -#if defined (hcx) - printf (" -Dhcx"); -#endif /* hcx */ -#if defined (host_mips) - printf (" -Dhost_mips"); -#endif /* host_mips */ -#if defined (hp9000) || defined (__hp9000) - printf (" -Dhp9000"); -#endif /* hp9000 || __hp9000 */ -#if defined (hp9000s200) || defined (__hp9000s200) - printf (" -Dhp9000s200"); -#endif /* hp9000s200 || __hp9000s200 */ -#if defined (hp9000s300) || defined (__hp9000s300) - printf (" -Dhp9000s300"); -#endif /* hp9000s300 || __hp9000s300 */ -#if defined (hp9000s500) || defined (__hp9000s500) - printf (" -Dhp9000s500"); -#endif /* hp9000s500 || __hp9000s500 */ -#if defined (hp9000s700) || defined (__hp9000s700) - printf (" -Dhp9000s700"); -#endif /* hp9000s700 || __hp9000s700 */ -#if defined (hp9000s800) || defined (__hp9000s800) - printf (" -Dhp9000s800"); -#endif /* hp9000s800 || __hp9000s800 */ -#if defined (hppa) || defined (__hppa) - printf (" -Dhppa"); -#endif /* hppa || __hppa */ -#if defined (hpux) || defined (__hpux) - printf (" -Dhpux"); -#endif /* hpux */ -#if defined (__hp_osf) - printf (" -D__hp_osf"); -#endif /* __hp_osf */ -#if defined (i386) - printf (" -Di386"); -#endif /* i386 */ -#if defined (__i386__) - printf (" -D__i386__"); -#endif -#if defined (__i860) - printf(" -D__i860"); -#endif /* __i860 */ -#if defined (__i860__) - printf(" -D__i860__"); -#endif /* __i860__ */ -#if defined (ibm) - printf (" -Dibm"); -#endif /* ibm */ -#if defined (ibm032) - printf (" -Dibm032"); -#endif /* ibm032 */ -#if defined (ibmrt) - printf (" -Dibmrt"); -#endif /* ibmrt */ -#if defined (interdata) - printf (" -Dinterdata"); -#endif /* interdata */ -#if defined (is68k) - printf (" -Dis68k"); -#endif /* is68k */ -#if defined (ksr1) - printf (" -Dksr1"); -#endif /* ksr1 */ -#if defined (__ksr1__) - printf (" -D__ksr1__"); -#endif /* __ksr1__ */ -#if defined (linux) - printf (" -Dlinux"); -#endif /* linux */ -#if defined (__linux__) - printf (" -D__linux__"); -#endif /* __linux__ */ -#if defined (luna88k) - printf (" -Dluna88k"); -#endif /* luna88k */ -#if defined (m68k) - printf (" -Dm68k"); -#endif /* m68k */ -#if defined (m88k) - printf (" -Dm88k"); -#endif /* m88k */ -#if defined (mc68010) - printf (" -Dmc68010"); -#endif /* mc68010 */ -#if defined (mc68020) - printf (" -Dmc68020"); -#endif /* mc68020 */ -#if defined (mc68030) - printf (" -Dmc68030"); -#endif /* mc68030 */ -#if defined (mc68040) - printf (" -Dmc68040"); -#endif /* mc68040 */ -#if defined (mc68k32) - printf (" -Dmc68k32"); -#endif /* mc68k32 */ -#if defined (mips) - printf (" -Dmips"); -#endif /* mips */ -#if defined (n16) - printf (" -Dn16"); -#endif /* n16 */ -#if defined (ns32000) - printf (" -Dns32000"); -#endif /* ns32000 */ -#if defined (os) - printf (" -Dos"); -#endif /* os */ -#if defined (osf) - printf (" -Dosf"); -#endif /* osf */ -#if defined (__osf__) - printf (" -D__osf__"); -#endif /* __osf__ */ -#if defined (__OSF1__) - printf(" -D__OSF1__"); -#endif /* __OSF1__ */ -#if defined (pdp11) - printf (" -Dpdp11"); -#endif /* pdp11 */ -#if defined (plexus) - printf (" -Dplexus") -#endif /* plexus */ -#if defined (pyr) - printf (" -Dpyr"); -#endif /* pyr */ -#if defined (scs) - printf (" -Dscs"); -#endif /* scs */ -#if defined (sequent) - printf (" -Dsequent"); -#endif /* sequent */ -#if defined (sgi) - printf (" -Dsgi"); -#endif /* sgi */ -#if defined (sony) - printf (" -Dsony"); -#endif /* sony */ -#if defined (sparc) - printf (" -Dsparc"); -#endif /* sparc */ -#if defined (stardent) - printf (" -Dstardent"); -#endif /* stardent */ -#if defined (sun) - printf (" -Dsun"); -#endif /* sun */ -#if defined (sun2) - printf (" -Dsun2"); -#endif /* sun2 */ -#if defined (sun3) - printf (" -Dsun3"); -#endif /* sun3 */ -#if defined (sun4) - printf (" -Dsun4"); -#endif /* sun4 */ -#if defined (__svr4__) - printf (" -D__svr4__"); -#endif /* __svr4__ */ -#if defined (tower32) - printf (" -Dtower32"); -#endif /* tower32 */ -#if defined (tss) - printf (" -Dtss"); -#endif /* tss */ -#if defined (u370) - printf (" -Du370"); -#endif /* u370 */ -#if defined (u3b) - printf (" -Du3b"); -#endif /* u3b */ -#if defined (u3b2) - printf (" -Du3b2"); -#endif /* u3b2 */ -#if defined (u3b20d) - printf (" -Du3b20d"); -#endif /* u3b20d */ -#if defined (u3b5) - printf (" -Du3b5"); -#endif /* u3b5 */ -#if defined (ultrix) - printf (" -Dultrix"); -#endif /* ultrix */ -#if defined (unix) - printf (" -Dunix"); -#endif /* unix */ -#if defined (vax) - printf (" -Dvax"); -#endif /* vax */ - - printf ("\n"); - exit (0); -} +/* getcppsyms.c - Find unique compiler symbols. */ + +/* Copyright (C) 1993 Free Software Foundation, Inc. + + This file is part of GNU Bash, the Bourne Again SHell. + + Bash is free software; you can redistribute it and/or modify it under + the terms of the GNU General Public License as published by the Free + Software Foundation; either version 2, or (at your option) any later + version. + + Bash is distributed in the hope that it will be useful, but WITHOUT ANY + WARRANTY; without even the implied warranty of MERCHANTABILITY or + FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + for more details. + + You should have received a copy of the GNU General Public License along + with Bash; see the file COPYING. If not, write to the Free Software + Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ + +/* Some cpp's do not define any symbols, but instead let /bin/cc do it + for them. For such machines, running this file may prove useful. It + outputs the list of symbols which /bin/cc or /lib/cpp define and which + we had the foresight to guess at. */ + +#include <stdio.h> +main () +{ +#if defined (__BSD_4_4__) + printf ("-D__BSD_4_4__"); +#endif /* __BSD_4_4__ */ +#if defined (CMU) + printf (" -DCMU"); +#endif /* CMU */ +#if defined (_COFF) + printf (" -D_COFF"); +#endif /* _COFF */ +#if defined (DGUX) + printf (" -DDGUX"); +#endif /* DGUX */ +#if defined (GOULD_PN) + printf (" -DGOULD_PN"); +#endif /* GOULD_PN */ +#if defined (MACH) + printf (" -DMACH"); +#endif /* MACH */ +#if defined (MIPSEB) + printf (" -DMIPSEB"); +#endif /* MIPSEB */ +#if defined (MIPSEL) + printf (" -DMIPSEL"); +#endif /* MIPSEL */ +#if defined (MULTIMAX) + printf (" -DMULTIMAX"); +#endif /* MULTIMAX */ +#if defined (M_UNIX) + printf (" -DM_UNIX"); +#endif /* M_UNIX */ +#if defined (M_XENIX) + printf (" -DM_XENIX"); +#endif /* M_XENIX */ +#if defined (_M_XENIX) + printf (" -D_M_XENIX"); +#endif /* _M_XENIX */ +#if defined (NeXT) + printf (" -DNeXT"); +#endif /* NeXT */ +#if defined (__PARAGON__) + printf (" -D__PARAGON__"); +#endif /* __PARAGON__ */ +#if defined (_PGC_) + printf (" -D_PGC_"); +#endif /* _PGC_ */ +#if defined (__PGC__) + printf (" -D__PGC__"); +#endif /* __PGC__ */ +#if defined (RES) + printf (" -DRES"); +#endif /* RES */ +#if defined (RISC6000) + printf (" -DRISC6000"); +#endif /* RISC6000 */ +#if defined (RT) + printf (" -DRT"); +#endif /* RT */ +#if defined (SYSTYPE_BSD) + printf (" -DSYSTYPE_BSD"); +#endif /* SYSTYPE_BSD */ +#if defined (SYSTYPE_SYSV) + printf (" -DSYSTYPE_SYSV"); +#endif /* SYSTYPE_SYSV */ +#if defined (Sun386i) + printf (" -DSun386i"); +#endif /* Sun386i */ +#if defined (Tek4132) + printf (" -DTek4132"); +#endif /* Tek4132 */ +#if defined (Tek4300) + printf (" -DTek4300"); +#endif /* Tek4300 */ +#if defined (UMAXV) + printf (" -DUMAXV"); +#endif /* UMAXV */ +#if defined (USGr4) + printf (" -DUSGr4"); +#endif /* USGr4 */ +#if defined (USGr4_2) + printf (" -DUSGr4_2"); +#endif /* USGr4_2 */ +#if defined (__SVR4_2__) + printf (" -D__SVR4_2__"); +#endif /* __SVR4_2__ */ +#if defined (Xenix286) + printf (" -DXenix286"); +#endif /* Xenix286 */ +#if defined (_AIX) + printf (" -D_AIX"); +#endif /* _AIX */ +#if defined (_AIX370) + printf (" -D_AIX370"); +#endif /* _AIX370 */ +#if defined (_IBMESA) + printf (" -D_IBMESA"); +#endif /* _IBMESA */ +#if defined (__ibmesa) + printf (" -D__ibmesa"); +#endif /* __ibmesa */ +#if defined (_U370) + printf (" -D_U370"); +#endif /* _U370 */ +#if defined (_NLS) + printf (" -D_NLS"); +#endif /* _NLS */ +#if defined (_CX_UX) + printf (" -D_CX_UX"); +#endif /* _CX_UX */ +#if defined (_IBMR2) + printf (" -D_IBMR2"); +#endif /* _IBMR2 */ +#if defined (_M88K) + printf (" -D_M88K"); +#endif /* _M88K */ +#if defined (_M88KBCS_TARGET) + printf (" -D_M88KBCS_TARGET"); +#endif /* _M88KBCS_TARGET */ +#if defined (__DGUX__) + printf (" -D__DGUX__"); +#endif /* __DGUX__ */ +#if defined (__UMAXV__) + printf (" -D__UMAXV__"); +#endif /* __UMAXV__ */ +#if defined (__m88k) + printf (" -D__m88k"); +#endif /* __m88k */ +#if defined (__uxpm__) + printf (" -DUSGr4 -Du370 -D__uxpm__"); +#endif /* __uxpm__ */ +#if defined (__uxps__) + printf (" -D__svr4__ -D__uxps__"); +#endif /* __uxps__ */ +#if defined (alliant) + printf (" -Dalliant"); +#endif /* alliant */ +#if defined (alpha) + printf (" -Dalpha"); +#endif /* alpha */ +#if defined (__alpha) + printf (" -D__alpha"); +#endif /* __alpha */ +#if defined (aix) + printf (" -Daix"); +#endif /* aix */ +#if defined (aixpc) + printf (" -Daixpc"); +#endif /* aixpc */ +#if defined (apollo) + printf (" -Dapollo"); +#endif /* apollo */ +#if defined (ardent) + printf (" -Dardent"); +#endif /* ardent */ +#if defined (att386) + printf (" -Datt386"); +#endif /* att386 */ +#if defined (att3b) + printf (" -Datt3b"); +#endif /* att3b */ +#if defined (bsd4_2) + printf (" -Dbsd4_2"); +#endif /* bsd4_2 */ +#if defined (bsd4_3) + printf (" -Dbsd4_3"); +#endif /* bsd4_3 */ +#if defined (__bsdi__) + printf (" -D__bsdi__"); +#endif /* __bsdi__ */ +#if defined (bsdi) + printf (" -Dbsdi"); +#endif /* bsdi */ +#if defined (__386BSD__) + printf (" -D__386BSD__"); +#endif /* __386BSD__ */ +#if defined (cadmus) + printf (" -Dcadmus"); +#endif /* cadmus */ +#if defined (clipper) + printf (" -Dclipper"); +#endif /* clipper */ +#if defined (concurrent) + printf (" -Dconcurrent"); +#endif /* concurrent */ +#if defined (convex) || defined (__convex__) || defined (__convexc__) +# if !defined (__GNUC__) + printf (" -pcc"); +# endif /* !__GNUC__ */ + printf (" -Dconvex"); +#endif /* convex */ +#if defined (dmert) + printf (" -Ddmert"); +#endif /* dmert */ +#if defined (gcos) + printf (" -Dgcos"); +#endif /* gcos */ +#if defined (gcx) + printf (" -Dgcx"); +#endif /* gcx */ +#if defined (gould) + printf (" -Dgould"); +#endif /* gould */ +#if defined (hbullx20) + printf (" -Dhbullx20"); +#endif /* hbullx20 */ +#if defined (hcx) + printf (" -Dhcx"); +#endif /* hcx */ +#if defined (host_mips) + printf (" -Dhost_mips"); +#endif /* host_mips */ +#if defined (hp9000) || defined (__hp9000) + printf (" -Dhp9000"); +#endif /* hp9000 || __hp9000 */ +#if defined (hp9000s200) || defined (__hp9000s200) + printf (" -Dhp9000s200"); +#endif /* hp9000s200 || __hp9000s200 */ +#if defined (hp9000s300) || defined (__hp9000s300) + printf (" -Dhp9000s300"); +#endif /* hp9000s300 || __hp9000s300 */ +#if defined (hp9000s500) || defined (__hp9000s500) + printf (" -Dhp9000s500"); +#endif /* hp9000s500 || __hp9000s500 */ +#if defined (hp9000s700) || defined (__hp9000s700) + printf (" -Dhp9000s700"); +#endif /* hp9000s700 || __hp9000s700 */ +#if defined (hp9000s800) || defined (__hp9000s800) + printf (" -Dhp9000s800"); +#endif /* hp9000s800 || __hp9000s800 */ +#if... [truncated message content] |
Update of /cvsroot/winbash/winbash/dum_inc In directory usw-pr-cvs1:/tmp/cvs-serv381/dum_inc Modified Files: alloca.h bash_dum.c bash_endian.h bcopy.c bzero.c dir.h dirent.c dirent.h dtypes.h fab.h grp.h nam.h ndir.h pwd.h rmsdef.h sgtty.h signal.c strings.h system.h termcap.h termio.h termios.h unistd.c unistd.h Log Message: Fixed more cr/lf problems. Index: alloca.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/alloca.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- alloca.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ alloca.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -#include <malloc.h> +#include <malloc.h> Index: bash_dum.c =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/bash_dum.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bash_dum.c 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ bash_dum.c 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,6 +1,6 @@ -/* dummy functions that we need to write eventually */ -int gethostname(char *name, int len) -{ - if (name && len) *name = 0 ; - return -1 ; -} +/* dummy functions that we need to write eventually */ +int gethostname(char *name, int len) +{ + if (name && len) *name = 0 ; + return -1 ; +} Index: bash_endian.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/bash_endian.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bash_endian.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ bash_endian.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: bcopy.c =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/bcopy.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bcopy.c 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ bcopy.c 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,57 +1,57 @@ -/* bcopy -- copy memory regions of arbitary length - Copyright (C) 1991 Free Software Foundation, Inc. - -This file is part of the libiberty library. -Libiberty is free software; you can redistribute it and/or -modify it under the terms of the GNU Library General Public -License as published by the Free Software Foundation; either -version 2 of the License, or (at your option) any later version. - -Libiberty is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -Library General Public License for more details. - -You should have received a copy of the GNU Library General Public -License along with libiberty; see the file COPYING.LIB. If -not, write to the Free Software Foundation, Inc., 675 Mass Ave, -Cambridge, MA 02139, USA. */ - -/* - -NAME - - bcopy -- copy memory regions of arbitrary length - -SYNOPSIS - - void bcopy (char *in, char *out, int length) - -DESCRIPTION - - Copy LENGTH bytes from memory region pointed to by IN to memory - region pointed to by OUT. - -BUGS - Significant speed improvements can be made in some cases by - implementing copies of multiple bytes simultaneously, or unrolling - the copy loop. - -*/ - -void -bcopy (src, dest, len) - register char *src, *dest; - int len; -{ - if (dest < src) - while (len--) - *dest++ = *src++; - else - { - char *lasts = src + (len-1); - char *lastd = dest + (len-1); - while (len--) - *(char *)lastd-- = *(char *)lasts--; - } -} +/* bcopy -- copy memory regions of arbitary length + Copyright (C) 1991 Free Software Foundation, Inc. + +This file is part of the libiberty library. +Libiberty is free software; you can redistribute it and/or +modify it under the terms of the GNU Library General Public +License as published by the Free Software Foundation; either +version 2 of the License, or (at your option) any later version. + +Libiberty is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +Library General Public License for more details. + +You should have received a copy of the GNU Library General Public +License along with libiberty; see the file COPYING.LIB. If +not, write to the Free Software Foundation, Inc., 675 Mass Ave, +Cambridge, MA 02139, USA. */ + +/* + +NAME + + bcopy -- copy memory regions of arbitrary length + +SYNOPSIS + + void bcopy (char *in, char *out, int length) + +DESCRIPTION + + Copy LENGTH bytes from memory region pointed to by IN to memory + region pointed to by OUT. + +BUGS + Significant speed improvements can be made in some cases by + implementing copies of multiple bytes simultaneously, or unrolling + the copy loop. + +*/ + +void +bcopy (src, dest, len) + register char *src, *dest; + int len; +{ + if (dest < src) + while (len--) + *dest++ = *src++; + else + { + char *lasts = src + (len-1); + char *lastd = dest + (len-1); + while (len--) + *(char *)lastd-- = *(char *)lasts--; + } +} Index: bzero.c =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/bzero.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bzero.c 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ bzero.c 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,53 +1,53 @@ -/* Portable version of bzero for systems without it. - Copyright (C) 1991 Free Software Foundation, Inc. - -This file is part of the libiberty library. -Libiberty is free software; you can redistribute it and/or -modify it under the terms of the GNU Library General Public -License as published by the Free Software Foundation; either -version 2 of the License, or (at your option) any later version. - -Libiberty is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -Library General Public License for more details. - -You should have received a copy of the GNU Library General Public -License along with libiberty; see the file COPYING.LIB. If -not, write to the Free Software Foundation, Inc., 675 Mass Ave, -Cambridge, MA 02139, USA. */ - - -/* - -NAME - - bzero -- zero the contents of a specified memory region - -SYNOPSIS - - void bzero (char *to, int count) - -DESCRIPTION - - Zero COUNT bytes of memory pointed to by TO. - -BUGS - - Significant speed enhancements may be made in some environments - by zeroing more than a single byte at a time, or by unrolling the - loop. - -*/ - - -void -bzero (to, count) - char *to; - int count; -{ - while (count-- > 0) - { - *to++ = 0; - } -} +/* Portable version of bzero for systems without it. + Copyright (C) 1991 Free Software Foundation, Inc. + +This file is part of the libiberty library. +Libiberty is free software; you can redistribute it and/or +modify it under the terms of the GNU Library General Public +License as published by the Free Software Foundation; either +version 2 of the License, or (at your option) any later version. + +Libiberty is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +Library General Public License for more details. + +You should have received a copy of the GNU Library General Public +License along with libiberty; see the file COPYING.LIB. If +not, write to the Free Software Foundation, Inc., 675 Mass Ave, +Cambridge, MA 02139, USA. */ + + +/* + +NAME + + bzero -- zero the contents of a specified memory region + +SYNOPSIS + + void bzero (char *to, int count) + +DESCRIPTION + + Zero COUNT bytes of memory pointed to by TO. + +BUGS + + Significant speed enhancements may be made in some environments + by zeroing more than a single byte at a time, or by unrolling the + loop. + +*/ + + +void +bzero (to, count) + char *to; + int count; +{ + while (count-- > 0) + { + *to++ = 0; + } +} Index: dir.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/dir.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- dir.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ dir.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: dirent.c =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/dirent.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- dirent.c 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ dirent.c 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,193 +1,193 @@ -/***************************************************************************** - * * - * Was DH_DIR.C * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ -/* -dirent.c -Modified by Paul Budnik for GNU Bash -*/ -/***************************************************************************** - * * - * sys/dirent.h * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ - - - -/* Include stuff *************************************************************/ -#include <stdlib.h> -#include <windows.h> -#include <sys/types.h> -#include <sys/stat.h> -#include <errno.h> -#include <io.h> - - - -/* Struct and typedef stuff **************************************************/ - -/* Directory entry (file) struct =========================================== */ -struct dirent -{ - unsigned long d_fileno; - unsigned short d_namlen; - char d_name[_MAX_PATH+1]; -}; - -/* Directory info typedef ================================================== */ -typedef struct __dirdesc -{ - char dir_Name[_MAX_PATH+1]; - HANDLE dir_Handle; - int dir_FileCount; - struct dirent dir_FileUnix; -} DIR; - - -/* Prototype stuff **********************************************************/ -DIR* opendir(char* dir_Name); -struct dirent* readdir(DIR* dir_Info); -void rewinddir(DIR* dir_Info); -int closedir(DIR* dir_Info); -long telldir(DIR* dir_Info); -void seekdir(DIR* dir_Info,long dir_Position); - -/* Open a directory ======================================================== */ -DIR* opendir(char* dir_Name) -{ - DIR* dir_Info; - /*struct stat dir_Stat; - int len; - char myDir[1024]; - - if (!dir_Name) return NULL; - len = strlen(dir_Name); - if ((len > 1 && dir_Name[len - 1] == '/') && !(len == 3 && dir_Name[1] == ':' && dir_Name[2] == '/')) { - strcpy(myDir, dir_Name); - myDir[len - 1] = 0; - dir_Name = myDir; - }*/ - - /* Make sure directory is actually a directory */ - /*if (stat(dir_Name,&dir_Stat) != 0) - { - errno = ENOENT; - return NULL; - } - if ((dir_Stat.st_mode&_S_IFDIR) == 0) - { - errno = ENOTDIR; - return NULL; - }*/ - - /* Get some memory */ - dir_Info = (DIR*)calloc(1,sizeof(DIR)); - if (dir_Info == NULL) - { - return NULL; - } - - /* Save some info about the directory */ - strcpy(dir_Info->dir_Name,dir_Name); - if ((dir_Info->dir_Name[strlen(dir_Info->dir_Name)-1] != '/') && - (dir_Info->dir_Name[strlen(dir_Info->dir_Name)-1] != '\\')) - { - strcat(dir_Info->dir_Name,"/"); - } - strcat(dir_Info->dir_Name,"*"); - dir_Info->dir_Handle = INVALID_HANDLE_VALUE; - dir_Info->dir_FileCount = 0; - - /* And return the directory info */ - return dir_Info; -} - -/* Read the next file in a directory ======================================= */ -struct dirent* readdir(DIR* dir_Info) -{ - WIN32_FIND_DATA dir_FileWin; - - /* Get the info about the next file */ - if (dir_Info->dir_FileCount == 0) - { - dir_Info->dir_Handle = FindFirstFile(dir_Info->dir_Name, - &dir_FileWin); - if (dir_Info->dir_Handle == INVALID_HANDLE_VALUE) - { - return NULL; - } - } - else - { - if (!FindNextFile(dir_Info->dir_Handle,&dir_FileWin)) - { - return NULL; - } - } - - /* Dummy up a UNIX file */ - dir_Info->dir_FileUnix.d_fileno = dir_Info->dir_FileCount; - dir_Info->dir_FileUnix.d_namlen = strlen(dir_FileWin.cFileName); - strcpy(dir_Info->dir_FileUnix.d_name,dir_FileWin.cFileName); - - /* Bump the number we've read */ - dir_Info->dir_FileCount++; - - /* And return the UNIX file info */ - return &(dir_Info->dir_FileUnix); -} - -/* Rewind a directory ====================================================== */ -void rewinddir(DIR* dir_Info) -{ - /* Re-set to the beginning */ - dir_Info->dir_Handle = INVALID_HANDLE_VALUE; - dir_Info->dir_FileCount = 0; -} - -/* Close a directory ======================================================= */ -int closedir(DIR* dir_Info) -{ - /* Close down the directory */ - if (!FindClose(dir_Info->dir_Handle)) - { - errno = EBADF; - return -1; - } - - /* Free up the memory */ - free(dir_Info); - - /* And return that everything went fine */ - return 0; -} - -/* Tell our position in a directory ======================================== */ -long telldir(DIR* dir_Info) -{ - /* Return our last position */ - return dir_Info->dir_FileCount; -} - -/* Seek to a position in a directory ======================================= */ -void seekdir(DIR* dir_Info,long dir_Position) -{ - /* Jump back to the beginning of the file */ - rewinddir(dir_Info); - - /* And read to a specific position */ - while (--dir_Position > 0) - { - readdir(dir_Info); - } -} - +/***************************************************************************** + * * + * Was DH_DIR.C * + * * + * Freely redistributable and modifiable. Use at your own risk. * + * * + * Copyright 1994 The Downhill Project * + * * + *****************************************************************************/ +/* +dirent.c +Modified by Paul Budnik for GNU Bash +*/ +/***************************************************************************** + * * + * sys/dirent.h * + * * + * Freely redistributable and modifiable. Use at your own risk. * + * * + * Copyright 1994 The Downhill Project * + * * + *****************************************************************************/ + + + +/* Include stuff *************************************************************/ +#include <stdlib.h> +#include <windows.h> +#include <sys/types.h> +#include <sys/stat.h> +#include <errno.h> +#include <io.h> + + + +/* Struct and typedef stuff **************************************************/ + +/* Directory entry (file) struct =========================================== */ +struct dirent +{ + unsigned long d_fileno; + unsigned short d_namlen; + char d_name[_MAX_PATH+1]; +}; + +/* Directory info typedef ================================================== */ +typedef struct __dirdesc +{ + char dir_Name[_MAX_PATH+1]; + HANDLE dir_Handle; + int dir_FileCount; + struct dirent dir_FileUnix; +} DIR; + + +/* Prototype stuff **********************************************************/ +DIR* opendir(char* dir_Name); +struct dirent* readdir(DIR* dir_Info); +void rewinddir(DIR* dir_Info); +int closedir(DIR* dir_Info); +long telldir(DIR* dir_Info); +void seekdir(DIR* dir_Info,long dir_Position); + +/* Open a directory ======================================================== */ +DIR* opendir(char* dir_Name) +{ + DIR* dir_Info; + /*struct stat dir_Stat; + int len; + char myDir[1024]; + + if (!dir_Name) return NULL; + len = strlen(dir_Name); + if ((len > 1 && dir_Name[len - 1] == '/') && !(len == 3 && dir_Name[1] == ':' && dir_Name[2] == '/')) { + strcpy(myDir, dir_Name); + myDir[len - 1] = 0; + dir_Name = myDir; + }*/ + + /* Make sure directory is actually a directory */ + /*if (stat(dir_Name,&dir_Stat) != 0) + { + errno = ENOENT; + return NULL; + } + if ((dir_Stat.st_mode&_S_IFDIR) == 0) + { + errno = ENOTDIR; + return NULL; + }*/ + + /* Get some memory */ + dir_Info = (DIR*)calloc(1,sizeof(DIR)); + if (dir_Info == NULL) + { + return NULL; + } + + /* Save some info about the directory */ + strcpy(dir_Info->dir_Name,dir_Name); + if ((dir_Info->dir_Name[strlen(dir_Info->dir_Name)-1] != '/') && + (dir_Info->dir_Name[strlen(dir_Info->dir_Name)-1] != '\\')) + { + strcat(dir_Info->dir_Name,"/"); + } + strcat(dir_Info->dir_Name,"*"); + dir_Info->dir_Handle = INVALID_HANDLE_VALUE; + dir_Info->dir_FileCount = 0; + + /* And return the directory info */ + return dir_Info; +} + +/* Read the next file in a directory ======================================= */ +struct dirent* readdir(DIR* dir_Info) +{ + WIN32_FIND_DATA dir_FileWin; + + /* Get the info about the next file */ + if (dir_Info->dir_FileCount == 0) + { + dir_Info->dir_Handle = FindFirstFile(dir_Info->dir_Name, + &dir_FileWin); + if (dir_Info->dir_Handle == INVALID_HANDLE_VALUE) + { + return NULL; + } + } + else + { + if (!FindNextFile(dir_Info->dir_Handle,&dir_FileWin)) + { + return NULL; + } + } + + /* Dummy up a UNIX file */ + dir_Info->dir_FileUnix.d_fileno = dir_Info->dir_FileCount; + dir_Info->dir_FileUnix.d_namlen = strlen(dir_FileWin.cFileName); + strcpy(dir_Info->dir_FileUnix.d_name,dir_FileWin.cFileName); + + /* Bump the number we've read */ + dir_Info->dir_FileCount++; + + /* And return the UNIX file info */ + return &(dir_Info->dir_FileUnix); +} + +/* Rewind a directory ====================================================== */ +void rewinddir(DIR* dir_Info) +{ + /* Re-set to the beginning */ + dir_Info->dir_Handle = INVALID_HANDLE_VALUE; + dir_Info->dir_FileCount = 0; +} + +/* Close a directory ======================================================= */ +int closedir(DIR* dir_Info) +{ + /* Close down the directory */ + if (!FindClose(dir_Info->dir_Handle)) + { + errno = EBADF; + return -1; + } + + /* Free up the memory */ + free(dir_Info); + + /* And return that everything went fine */ + return 0; +} + +/* Tell our position in a directory ======================================== */ +long telldir(DIR* dir_Info) +{ + /* Return our last position */ + return dir_Info->dir_FileCount; +} + +/* Seek to a position in a directory ======================================= */ +void seekdir(DIR* dir_Info,long dir_Position) +{ + /* Jump back to the beginning of the file */ + rewinddir(dir_Info); + + /* And read to a specific position */ + while (--dir_Position > 0) + { + readdir(dir_Info); + } +} + Index: dirent.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/dirent.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- dirent.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ dirent.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,55 +1,55 @@ -#ifndef DIRENT_DOT_H -#define DIRENT_DOT_H -/***************************************************************************** - * * - * Was sys/dirent.h * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ -/* -dirent.h -Modified by Paul Budnik for GNU Bash -*/ - - - - -/* Include stuff *************************************************************/ -#include "dtypes.h" -#include <stdlib.h> -#include <windows.h> - - -/* Struct and typedef stuff **************************************************/ - -/* Directory entry (file) struct =========================================== */ -struct dirent -{ - unsigned long d_fileno; - unsigned short d_namlen; - char d_name[_MAX_PATH+1]; -}; - -/* Directory info typedef ================================================== */ -typedef struct __dirdesc -{ - char dir_Name[_MAX_PATH+1]; - HANDLE dir_Handle; - int dir_FileCount; - struct dirent dir_FileUnix; -} DIR; - - -/* Prototype stuff **********************************************************/ -DIR* opendir(char* dir_Name); -struct dirent* readdir(DIR* dir_Info); -void rewinddir(DIR* dir_Info); -int closedir(DIR* dir_Info); -long telldir(DIR* dir_Info); -void seekdir(DIR* dir_Info,long dir_Position); - - -#endif /* #ifdef DIRENT_DOT_H */ +#ifndef DIRENT_DOT_H +#define DIRENT_DOT_H +/***************************************************************************** + * * + * Was sys/dirent.h * + * * + * Freely redistributable and modifiable. Use at your own risk. * + * * + * Copyright 1994 The Downhill Project * + * * + *****************************************************************************/ +/* +dirent.h +Modified by Paul Budnik for GNU Bash +*/ + + + + +/* Include stuff *************************************************************/ +#include "dtypes.h" +#include <stdlib.h> +#include <windows.h> + + +/* Struct and typedef stuff **************************************************/ + +/* Directory entry (file) struct =========================================== */ +struct dirent +{ + unsigned long d_fileno; + unsigned short d_namlen; + char d_name[_MAX_PATH+1]; +}; + +/* Directory info typedef ================================================== */ +typedef struct __dirdesc +{ + char dir_Name[_MAX_PATH+1]; + HANDLE dir_Handle; + int dir_FileCount; + struct dirent dir_FileUnix; +} DIR; + + +/* Prototype stuff **********************************************************/ +DIR* opendir(char* dir_Name); +struct dirent* readdir(DIR* dir_Info); +void rewinddir(DIR* dir_Info); +int closedir(DIR* dir_Info); +long telldir(DIR* dir_Info); +void seekdir(DIR* dir_Info,long dir_Position); + + +#endif /* #ifdef DIRENT_DOT_H */ Index: dtypes.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/dtypes.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- dtypes.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ dtypes.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,34 +1,34 @@ -#ifndef DTYPES_DOT_H -#define DTYPES_DOT_H -/***************************************************************************** - * * - * From sys/types.h * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ -/* -Modified for GNU Bash by Paul Budnik -*/ - - -/* Good typedefs =========================================================== */ -typedef long uid_t; -typedef long gid_t; -typedef long pid_t; -typedef unsigned short mode_t; -typedef short nlink_t; -typedef char* caddr_t; - -/* Bad typedefs ============================================================ */ -typedef unsigned char u_char; -typedef unsigned short u_short; -typedef unsigned int u_int; -typedef unsigned long u_long; -typedef u_int uint; -typedef u_short ushort; - - -#endif /* #ifdef DTYPES_DOT_H */ +#ifndef DTYPES_DOT_H +#define DTYPES_DOT_H +/***************************************************************************** + * * + * From sys/types.h * + * * + * Freely redistributable and modifiable. Use at your own risk. * + * * + * Copyright 1994 The Downhill Project * + * * + *****************************************************************************/ +/* +Modified for GNU Bash by Paul Budnik +*/ + + +/* Good typedefs =========================================================== */ +typedef long uid_t; +typedef long gid_t; +typedef long pid_t; +typedef unsigned short mode_t; +typedef short nlink_t; +typedef char* caddr_t; + +/* Bad typedefs ============================================================ */ +typedef unsigned char u_char; +typedef unsigned short u_short; +typedef unsigned int u_int; +typedef unsigned long u_long; +typedef u_int uint; +typedef u_short ushort; + + +#endif /* #ifdef DTYPES_DOT_H */ Index: fab.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/fab.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- fab.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ fab.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: grp.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/grp.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- grp.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ grp.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,41 +1,41 @@ -#ifndef GRP_DOT_H -#define GRP_DOT_H -/***************************************************************************** - * * - * grp.h * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ -/* modified by Paul Budnik for GNU Bash -*/ - -#include "dtypes.h" - - - -/* Include stuff *************************************************************/ -#include <sys/types.h> - - -/* Struct stuff **************************************************************/ -struct group -{ - char* gr_name; - char* gr_passwd; - gid_t gr_gid; - char* gr_mem[2]; -}; - - -/* Prototype stuff ***********************************************************/ -struct group* getgrent(void); -void setgrent(void); -void endgrent(void); -struct group* getgrgid(gid_t group_Id); -struct group* getgrnam(char* group_Name); - - -#endif /* #ifdef GRP_DOT_H */ +#ifndef GRP_DOT_H +#define GRP_DOT_H +/***************************************************************************** + * * + * grp.h * + * * + * Freely redistributable and modifiable. Use at your own risk. * + * * + * Copyright 1994 The Downhill Project * + * * + *****************************************************************************/ +/* modified by Paul Budnik for GNU Bash +*/ + +#include "dtypes.h" + + + +/* Include stuff *************************************************************/ +#include <sys/types.h> + + +/* Struct stuff **************************************************************/ +struct group +{ + char* gr_name; + char* gr_passwd; + gid_t gr_gid; + char* gr_mem[2]; +}; + + +/* Prototype stuff ***********************************************************/ +struct group* getgrent(void); +void setgrent(void); +void endgrent(void); +struct group* getgrgid(gid_t group_Id); +struct group* getgrnam(char* group_Name); + + +#endif /* #ifdef GRP_DOT_H */ Index: nam.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/nam.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- nam.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ nam.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: ndir.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/ndir.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ndir.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ndir.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: pwd.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/pwd.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- pwd.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ pwd.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,45 +1,45 @@ -#ifndef PWD_DOT_H -#define PWD_DOT_H -/***************************************************************************** - * * - * pwd.h * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ -/* -Modified by Paul Budnik for GNU BASH -*/ - - - - -/* Include stuff *************************************************************/ -#include "dtypes.h" -#include <sys/types.h> - - -/* Struct stuff **************************************************************/ -struct passwd -{ - char* pw_name; - char* pw_passwd; - uid_t pw_uid; - gid_t pw_gid; - char* pw_gecos; - char* pw_dir; - char* pw_shell; -}; - - -/* Prototype stuff ***********************************************************/ -struct passwd* getpwent(void); -void setpwent(void); -void endpwent(void); -struct passwd* getpwuid(uid_t user_Id); -struct passwd* getpwnam(char* user_Name); - - -#endif /* #ifdef PWD_DOT_H */ +#ifndef PWD_DOT_H +#define PWD_DOT_H +/***************************************************************************** + * * + * pwd.h * + * * + * Freely redistributable and modifiable. Use at your own risk. * + * * + * Copyright 1994 The Downhill Project * + * * + *****************************************************************************/ +/* +Modified by Paul Budnik for GNU BASH +*/ + + + + +/* Include stuff *************************************************************/ +#include "dtypes.h" +#include <sys/types.h> + + +/* Struct stuff **************************************************************/ +struct passwd +{ + char* pw_name; + char* pw_passwd; + uid_t pw_uid; + gid_t pw_gid; + char* pw_gecos; + char* pw_dir; + char* pw_shell; +}; + + +/* Prototype stuff ***********************************************************/ +struct passwd* getpwent(void); +void setpwent(void); +void endpwent(void); +struct passwd* getpwuid(uid_t user_Id); +struct passwd* getpwnam(char* user_Name); + + +#endif /* #ifdef PWD_DOT_H */ Index: rmsdef.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/rmsdef.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- rmsdef.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ rmsdef.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: sgtty.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sgtty.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- sgtty.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ sgtty.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: signal.c =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/signal.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- signal.c 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ signal.c 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,36 +1,36 @@ -/***************************************************************************** - * * - * From DH_SIG.C * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ -/* -Modified for GNU Bash by Paul Budnik -&/ - - -/* Include stuff *************************************************************/ -#include <windows.h> -#include <stdlib.h> -#include <stdio.h> -#include <stdarg.h> -#include <errno.h> -#include <signal.h> -#include <dtypes.h> - - -int kill(pid_t pid,int sig) -{ - if (pid == getpid()) return raise(sig); - return -1 ; -} - -int killpg(int pgrp, int sig) -{ - return -1 ; -} - - +/***************************************************************************** + * * + * From DH_SIG.C * + * * + * Freely redistributable and modifiable. Use at your own risk. * + * * + * Copyright 1994 The Downhill Project * + * * + *****************************************************************************/ +/* +Modified for GNU Bash by Paul Budnik +&/ + + +/* Include stuff *************************************************************/ +#include <windows.h> +#include <stdlib.h> +#include <stdio.h> +#include <stdarg.h> +#include <errno.h> +#include <signal.h> +#include <dtypes.h> + + +int kill(pid_t pid,int sig) +{ + if (pid == getpid()) return raise(sig); + return -1 ; +} + +int killpg(int pgrp, int sig) +{ + return -1 ; +} + + Index: strings.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/strings.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- strings.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ strings.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: system.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/system.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- system.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ system.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: termcap.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/termcap.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- termcap.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ termcap.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: termio.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/termio.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- termio.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ termio.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: termios.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/termios.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- termios.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ termios.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: unistd.c =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/unistd.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- unistd.c 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ unistd.c 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,959 +1,959 @@ -/***************************************************************************** - * * - * Taken from DH_GRP.C * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ -/* modified by Paul Budnik -for GNU Bash [...1887 lines suppressed...] +{ + /* Reset to the beginning */ + pwd_Position = -1; + + return; +} + +/* Stop using the password file ============================================ */ +void endpwent(void) +{ + /* Reset to the beginning */ + pwd_Position = -1; + + return; +} + +long ulimit(int a, long b) +{ + return 1000000 ; +} Index: unistd.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/unistd.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- unistd.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ unistd.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,44 +1,44 @@ -#ifndef UNISTD_DOT_H -#define UNISTD_DOT_H -/***************************************************************************** - * * - * sys/unistd.h * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ -/* -Modified by Paul Budnik for GNU BASH -*/ - - -#include "dtypes.h" -#include <stdio.h> -#include <sys/types.h> - - - - -/* Prototype stuff ***********************************************************/ -uid_t getuid(void); -uid_t geteuid(void); -gid_t getgid(void); -gid_t getegid(void); -int getgroups(int group_Max,gid_t group_Id[]); -unsigned int sleep(unsigned int sleep_Duration); -int pause(void); -int chown(char* file_Name,uid_t file_User,gid_t file_Group); -int fchown(int file_Fd,uid_t file_User,gid_t file_Group); -int getopt(int arg_Count,char* arg_Value[],char flag_List[]); -int readlink(char* file_Name,char* buf_Mem,int buf_Size); - -int pipe(int filedes[2]); -int getppid(void); -int getdtablesize(); -int setuid(uid_t id); -int setgid(gid_t gid); -long ulimit(int a, long b); - -#endif /* #ifdef UNISTD_DOT_H */ +#ifndef UNISTD_DOT_H +#define UNISTD_DOT_H +/***************************************************************************** + * * + * sys/unistd.h * + * * + * Freely redistributable and modifiable. Use at your own risk. * + * * + * Copyright 1994 The Downhill Project * + * * + *****************************************************************************/ +/* +Modified by Paul Budnik for GNU BASH +*/ + + +#include "dtypes.h" +#include <stdio.h> +#include <sys/types.h> + + + + +/* Prototype stuff ***********************************************************/ +uid_t getuid(void); +uid_t geteuid(void); +gid_t getgid(void); +gid_t getegid(void); +int getgroups(int group_Max,gid_t group_Id[]); +unsigned int sleep(unsigned int sleep_Duration); +int pause(void); +int chown(char* file_Name,uid_t file_User,gid_t file_Group); +int fchown(int file_Fd,uid_t file_User,gid_t file_Group); +int getopt(int arg_Count,char* arg_Value[],char flag_List[]); +int readlink(char* file_Name,char* buf_Mem,int buf_Size); + +int pipe(int filedes[2]); +int getppid(void); +int getdtablesize(); +int setuid(uid_t id); +int setgid(gid_t gid); +long ulimit(int a, long b); + +#endif /* #ifdef UNISTD_DOT_H */ |
From: Enrico B. <enr...@us...> - 2002-03-09 04:43:20
|
Update of /cvsroot/winbash/winbash/dum_inc/sys In directory usw-pr-cvs1:/tmp/cvs-serv381/dum_inc/sys Modified Files: dir.h file.h ioctl.h ndir.h param.h pc.h pte.h ptem.h resource.h socket.h stream.h time.h times.h ttold.h utsname.h wait.h Log Message: Fixed more cr/lf problems. Index: dir.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/dir.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- dir.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ dir.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: file.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/file.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- file.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ file.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: ioctl.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/ioctl.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ioctl.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ioctl.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: ndir.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/ndir.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ndir.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ndir.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: param.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/param.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- param.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ param.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: pc.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/pc.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- pc.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ pc.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: pte.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/pte.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- pte.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ pte.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: ptem.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/ptem.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ptem.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ptem.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: resource.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/resource.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- resource.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ resource.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: socket.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/socket.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- socket.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ socket.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: stream.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/stream.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- stream.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ stream.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: time.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/time.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- time.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ time.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,33 +1,33 @@ -/***************************************************************************** - * * - * sys/time.h * - * * - * Freely redistributable and modifiable. Use at your own risk. * - * * - * Copyright 1994 The Downhill Project * - * * - *****************************************************************************/ - - -#if !defined(_DOWNHILL_SYS_TIME_H) -#define _DOWNHILL_SYS_TIME_H - - -/* Include stuff *************************************************************/ -#include <winsock.h> -#include <time.h> - - -/* Struct stuff **************************************************************/ -struct timezone -{ - int tz_minuteswest; - int tz_dsttime; -}; - - -/* Prototype stuff ***********************************************************/ -int gettimeofday(struct timeval* time_Info,struct timezone* timezone_Info); - - -#endif /* _DOWNHILL_SYS_TIME_H */ +/***************************************************************************** + * * + * sys/time.h * + * * + * Freely redistributable and modifiable. Use at your own risk. * + * * + * Copyright 1994 The Downhill Project * + * * + *****************************************************************************/ + + +#if !defined(_DOWNHILL_SYS_TIME_H) +#define _DOWNHILL_SYS_TIME_H + + +/* Include stuff *************************************************************/ +#include <winsock.h> +#include <time.h> + + +/* Struct stuff **************************************************************/ +struct timezone +{ + int tz_minuteswest; + int tz_dsttime; +}; + + +/* Prototype stuff ***********************************************************/ +int gettimeofday(struct timeval* time_Info,struct timezone* timezone_Info); + + +#endif /* _DOWNHILL_SYS_TIME_H */ Index: times.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/times.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- times.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ times.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: ttold.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/ttold.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- ttold.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ ttold.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: utsname.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/utsname.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- utsname.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ utsname.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ Index: wait.h =================================================================== RCS file: /cvsroot/winbash/winbash/dum_inc/sys/wait.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- wait.h 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ wait.h 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -/* Dummy header file to get Visual C++ happy */ +/* Dummy header file to get Visual C++ happy */ |
From: Enrico B. <enr...@us...> - 2002-03-09 04:43:20
|
Update of /cvsroot/winbash/winbash/examples In directory usw-pr-cvs1:/tmp/cvs-serv381/examples Modified Files: alias-conv.sh suncmd.termcap Log Message: Fixed more cr/lf problems. Index: alias-conv.sh =================================================================== RCS file: /cvsroot/winbash/winbash/examples/alias-conv.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- alias-conv.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ alias-conv.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,22 +1,22 @@ -#! /bin/sh -# -# Convert Csh aliases to Bash aliases. Adapted from a similar program -# supplied with zsh. -# -# This is a quick script to convert csh aliases to Bash aliases/functions. -# Pipe the output of csh's alias command through this; it will generate -# a series of alias/function definitions on stdout, suitable for -# processing by bash. -# -# This is not perfect, but it gets most common aliases; it should manage to -# cut down a lot of the busy work. -# -sed -e 's/ (\(.*\))/ \1/' >/tmp/cz$$.1 -grep ! /tmp/cz$$.1 >/tmp/cz$$.2 -grep -v ! /tmp/cz$$.1 >/tmp/cz$$.3 -sed -e "s/'/'"\\\\"''"/g -e 's/^\([^ ]*\) \(.*\)$/alias \1='"'\2'/" \ - /tmp/cz$$.3 -sed -e 's/![:#]*/$/g' -e 's/^\([^ ]*\) \(.*\)$/\1 () { \2 }/' /tmp/cz$$.2 -rm /tmp/cz$$.? - -exit 0 +#! /bin/sh +# +# Convert Csh aliases to Bash aliases. Adapted from a similar program +# supplied with zsh. +# +# This is a quick script to convert csh aliases to Bash aliases/functions. +# Pipe the output of csh's alias command through this; it will generate +# a series of alias/function definitions on stdout, suitable for +# processing by bash. +# +# This is not perfect, but it gets most common aliases; it should manage to +# cut down a lot of the busy work. +# +sed -e 's/ (\(.*\))/ \1/' >/tmp/cz$$.1 +grep ! /tmp/cz$$.1 >/tmp/cz$$.2 +grep -v ! /tmp/cz$$.1 >/tmp/cz$$.3 +sed -e "s/'/'"\\\\"''"/g -e 's/^\([^ ]*\) \(.*\)$/alias \1='"'\2'/" \ + /tmp/cz$$.3 +sed -e 's/![:#]*/$/g' -e 's/^\([^ ]*\) \(.*\)$/\1 () { \2 }/' /tmp/cz$$.2 +rm /tmp/cz$$.? + +exit 0 Index: suncmd.termcap =================================================================== RCS file: /cvsroot/winbash/winbash/examples/suncmd.termcap,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- suncmd.termcap 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ suncmd.termcap 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,30 +1,30 @@ -#Posted-Date: Fri, 9 Mar 90 18:34:29 EST -#Date: Fri, 9 Mar 90 18:34:29 EST -#From: "Eirik Fuller" <wonton.tn.cornell.edu!eirik@ucsbcsl.UUCP> -#To: bf...@ai... (Brian Fox) -#Subject: Patch to bash 1.05 for SunView -# -#I think this works: -# -Mu|sun-cmd:am:bs:km:pt:li#34:co#80:cl=^L:ce=\E[K:cd=\E[J:rs=\E[s: -# -#Another alternative is to send the ti string at startup time (and, I -#guess, the te string at exit time); that is how vi works in a cmdtool. -#The best reason to not do this is that this also disables scrolling -#which, as I understand it, is why anyone would use cmdtool in the -#first place. Sending the ti string at startup time would do strange -#things on other systems too; in xterm it would use the alternate -#screen. -# -#The problem with cmdtool, in case that is less than obvious, is that -#almost none of the capabilities advertised in /etc/termcap are enabled -#while scrolling is enabled. It has other problems too, like being -#part of an outdated proprietary windowing system, but there's probably -#no need to dwell on that. In a sense, though, the sun-cmd termcap -#entry doesn't lie about the capabilities; I think the termcap man page -#does warn about some terminals having cursor motion capabilities only -#in the "ti/te window". -# -#A general solution to this problem would require a termcap capability -#which somehow tells which features are available outside of the ti/te -#window. There is no such capability in termcap now, of course. +#Posted-Date: Fri, 9 Mar 90 18:34:29 EST +#Date: Fri, 9 Mar 90 18:34:29 EST +#From: "Eirik Fuller" <wonton.tn.cornell.edu!eirik@ucsbcsl.UUCP> +#To: bf...@ai... (Brian Fox) +#Subject: Patch to bash 1.05 for SunView +# +#I think this works: +# +Mu|sun-cmd:am:bs:km:pt:li#34:co#80:cl=^L:ce=\E[K:cd=\E[J:rs=\E[s: +# +#Another alternative is to send the ti string at startup time (and, I +#guess, the te string at exit time); that is how vi works in a cmdtool. +#The best reason to not do this is that this also disables scrolling +#which, as I understand it, is why anyone would use cmdtool in the +#first place. Sending the ti string at startup time would do strange +#things on other systems too; in xterm it would use the alternate +#screen. +# +#The problem with cmdtool, in case that is less than obvious, is that +#almost none of the capabilities advertised in /etc/termcap are enabled +#while scrolling is enabled. It has other problems too, like being +#part of an outdated proprietary windowing system, but there's probably +#no need to dwell on that. In a sense, though, the sun-cmd termcap +#entry doesn't lie about the capabilities; I think the termcap man page +#does warn about some terminals having cursor motion capabilities only +#in the "ti/te window". +# +#A general solution to this problem would require a termcap capability +#which somehow tells which features are available outside of the ti/te +#window. There is no such capability in termcap now, of course. |
From: Enrico B. <enr...@us...> - 2002-03-09 04:43:19
|
Update of /cvsroot/winbash/winbash/portbash In directory usw-pr-cvs1:/tmp/cvs-serv381/portbash Modified Files: README libc.sh mkdesc.sh pgrp.c signals.sh stdio.sh strings.sh syscalls.sh Log Message: Fixed more cr/lf problems. Index: README =================================================================== RCS file: /cvsroot/winbash/winbash/portbash/README,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- README 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ README 9 Mar 2002 04:43:16 -0000 1.2 @@ -1 +1 @@ -run sh mkdesc.sh for a first cut at a machines.h entry +run sh mkdesc.sh for a first cut at a machines.h entry Index: libc.sh =================================================================== RCS file: /cvsroot/winbash/winbash/portbash/libc.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- libc.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ libc.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,172 +1,172 @@ -#! /bin/sh - -CC=cc -export CC - -cat > x.c <<EOF -extern char *alloca(); - -main() -{ - char *s; - s = alloca(20); -} -EOF - -if ${CC} x.c > /dev/null 2>&1; then - : -else - echo '#undef HAVE_ALLOCA' -fi -rm -f x.c x.o a.out - -cat > x.c << EOF -#include <sys/types.h> -#include <sys/param.h> -extern char *getwd(); -main() -{ - getwd(); -} -EOF - -if ${CC} x.c > /dev/null 2>&1; then - echo '#define HAVE_GETWD' -else - echo '#undef HAVE_GETWD' - rm -f x.c x.o a.out - - cat > x.c << EOF -extern char *getcwd(); - -main() -{ - getcwd(); -} -EOF - - if ${CC} x.c >/dev/null 2>&1; then - echo '#define HAVE_GETCWD' - fi -fi -rm -f a.out x.c x.o - -cat > x.c << EOF -/* - * exit 0 if we have bcopy in libc and it works as in BSD - */ - -extern int bcopy(); - -char x[] = "12345"; -char y[] = "67890"; - -main() -{ - bcopy(x, y, 5); - exit(strcmp(x, y)); -} -EOF - -if ${CC} x.c > /dev/null 2>&1 && ./a.out ; then - BC='-DHAVE_BCOPY' -fi - -rm -f x.c x.o a.out - -cat > x.c << EOF -/* - * If this compiles, the system has uid_t and gid_t - */ - -#include <sys/types.h> - -uid_t u; -gid_t g; - -main() -{ - exit(0); -} -EOF - -if ${CC} x.c > /dev/null 2>&1; then - UIDT='-DHAVE_UID_T' -fi - -rm -f x.c x.o a.out - -cat > x.c <<EOF -#include <signal.h> - -extern char *sys_siglist[]; - -main() -{ - char *x; - - x = sys_siglist[3]; - write(2, x, strlen(x)); - exit(0); -} -EOF - -if ${CC} ./x.c >/dev/null 2>&1; then - echo '#define HAVE_SYS_SIGLIST' -else - - cat > x.c <<EOF -#include <signal.h> - -extern char *_sys_siglist[]; - -main() -{ - exit(0); -} -EOF - - if ${CC} ./x.c >/dev/null 2>&1; then - echo '#define HAVE_SYS_SIGLIST' - SL='-Dsys_siglist=_sys_siglist' - fi -fi - -PG= -if ${CC} pgrp.c >/dev/null 2>&1; then - PG=`./a.out` -fi - -if [ -f /unix ] && [ -f /usr/ccs/lib/libc.so ]; then - R4="-DUSGr4" -fi - -touch not_a_directory -if [ -f /usr/include/dirent.h ]; then - d='<dirent.h>' -else - d='<sys/dir.h>' -fi - -cat > x.c << EOF -/* - * exit 0 if opendir does not check whether its argument is a directory - */ - -#include $d -DIR *dir; - -main() -{ - dir = opendir("not_a_directory"); - exit (dir == 0); -} -EOF - -if ${CC} x.c > /dev/null 2>&1 && ./a.out ; then - OD='-DOPENDIR_NOT_ROBUST' -fi - -rm -f x.c x.o a.out pgrp.o not_a_directory -echo "#define SYSDEP_CFLAGS $BC $UIDT $SL $PG $R4 $OD" -exit 0 +#! /bin/sh + +CC=cc +export CC + +cat > x.c <<EOF +extern char *alloca(); + +main() +{ + char *s; + s = alloca(20); +} +EOF + +if ${CC} x.c > /dev/null 2>&1; then + : +else + echo '#undef HAVE_ALLOCA' +fi +rm -f x.c x.o a.out + +cat > x.c << EOF +#include <sys/types.h> +#include <sys/param.h> +extern char *getwd(); +main() +{ + getwd(); +} +EOF + +if ${CC} x.c > /dev/null 2>&1; then + echo '#define HAVE_GETWD' +else + echo '#undef HAVE_GETWD' + rm -f x.c x.o a.out + + cat > x.c << EOF +extern char *getcwd(); + +main() +{ + getcwd(); +} +EOF + + if ${CC} x.c >/dev/null 2>&1; then + echo '#define HAVE_GETCWD' + fi +fi +rm -f a.out x.c x.o + +cat > x.c << EOF +/* + * exit 0 if we have bcopy in libc and it works as in BSD + */ + +extern int bcopy(); + +char x[] = "12345"; +char y[] = "67890"; + +main() +{ + bcopy(x, y, 5); + exit(strcmp(x, y)); +} +EOF + +if ${CC} x.c > /dev/null 2>&1 && ./a.out ; then + BC='-DHAVE_BCOPY' +fi + +rm -f x.c x.o a.out + +cat > x.c << EOF +/* + * If this compiles, the system has uid_t and gid_t + */ + +#include <sys/types.h> + +uid_t u; +gid_t g; + +main() +{ + exit(0); +} +EOF + +if ${CC} x.c > /dev/null 2>&1; then + UIDT='-DHAVE_UID_T' +fi + +rm -f x.c x.o a.out + +cat > x.c <<EOF +#include <signal.h> + +extern char *sys_siglist[]; + +main() +{ + char *x; + + x = sys_siglist[3]; + write(2, x, strlen(x)); + exit(0); +} +EOF + +if ${CC} ./x.c >/dev/null 2>&1; then + echo '#define HAVE_SYS_SIGLIST' +else + + cat > x.c <<EOF +#include <signal.h> + +extern char *_sys_siglist[]; + +main() +{ + exit(0); +} +EOF + + if ${CC} ./x.c >/dev/null 2>&1; then + echo '#define HAVE_SYS_SIGLIST' + SL='-Dsys_siglist=_sys_siglist' + fi +fi + +PG= +if ${CC} pgrp.c >/dev/null 2>&1; then + PG=`./a.out` +fi + +if [ -f /unix ] && [ -f /usr/ccs/lib/libc.so ]; then + R4="-DUSGr4" +fi + +touch not_a_directory +if [ -f /usr/include/dirent.h ]; then + d='<dirent.h>' +else + d='<sys/dir.h>' +fi + +cat > x.c << EOF +/* + * exit 0 if opendir does not check whether its argument is a directory + */ + +#include $d +DIR *dir; + +main() +{ + dir = opendir("not_a_directory"); + exit (dir == 0); +} +EOF + +if ${CC} x.c > /dev/null 2>&1 && ./a.out ; then + OD='-DOPENDIR_NOT_ROBUST' +fi + +rm -f x.c x.o a.out pgrp.o not_a_directory +echo "#define SYSDEP_CFLAGS $BC $UIDT $SL $PG $R4 $OD" +exit 0 Index: mkdesc.sh =================================================================== RCS file: /cvsroot/winbash/winbash/portbash/mkdesc.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- mkdesc.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ mkdesc.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,11 +1,11 @@ -#! /bin/sh - -if [ -f /unix ]; then - echo '#define M_OS "USG"' -fi - -sh signals.sh -sh stdio.sh -sh strings.sh -sh syscalls.sh -sh libc.sh +#! /bin/sh + +if [ -f /unix ]; then + echo '#define M_OS "USG"' +fi + +sh signals.sh +sh stdio.sh +sh strings.sh +sh syscalls.sh +sh libc.sh Index: pgrp.c =================================================================== RCS file: /cvsroot/winbash/winbash/portbash/pgrp.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- pgrp.c 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ pgrp.c 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,48 +1,48 @@ -/* - * If this system has a BSD-style getpgrp() call which takes a pid - * as an argument, output a -DBSD_GETPGRP. - */ -#include <stdio.h> -#include <sys/types.h> - -int pid; -int pg1, pg2, pg3, pg4; -int ng, np, s, child; - -main() -{ - pid = getpid(); - pg1 = getpgrp(0); - pg2 = getpgrp(); - pg3 = getpgrp(pid); - pg4 = getpgrp(1); - - /* - * If all of these values are the same, it's pretty sure that - * we're on a system that ignores getpgrp's first argument. - */ - if (pg2 == pg4 && pg1 == pg3 && pg2 == pg3) - exit(0); - - child = fork(); - if (child < 0) - exit(1); - else if (child == 0) { - np = getpid(); - /* - * If this is Sys V, this will not work; pgrp will be - * set to np because setpgrp just changes a pgrp to be - * the same as the pid. - */ - setpgrp(np, pg1); - ng = getpgrp(0); /* Same result for Sys V and BSD */ - if (ng == pg1) { - printf("-DBSD_GETPGRP\n"); - exit(0); - } else - exit(1); - } else { - wait(&s); - exit(s>>8); - } -} +/* + * If this system has a BSD-style getpgrp() call which takes a pid + * as an argument, output a -DBSD_GETPGRP. + */ +#include <stdio.h> +#include <sys/types.h> + +int pid; +int pg1, pg2, pg3, pg4; +int ng, np, s, child; + +main() +{ + pid = getpid(); + pg1 = getpgrp(0); + pg2 = getpgrp(); + pg3 = getpgrp(pid); + pg4 = getpgrp(1); + + /* + * If all of these values are the same, it's pretty sure that + * we're on a system that ignores getpgrp's first argument. + */ + if (pg2 == pg4 && pg1 == pg3 && pg2 == pg3) + exit(0); + + child = fork(); + if (child < 0) + exit(1); + else if (child == 0) { + np = getpid(); + /* + * If this is Sys V, this will not work; pgrp will be + * set to np because setpgrp just changes a pgrp to be + * the same as the pid. + */ + setpgrp(np, pg1); + ng = getpgrp(0); /* Same result for Sys V and BSD */ + if (ng == pg1) { + printf("-DBSD_GETPGRP\n"); + exit(0); + } else + exit(1); + } else { + wait(&s); + exit(s>>8); + } +} Index: signals.sh =================================================================== RCS file: /cvsroot/winbash/winbash/portbash/signals.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- signals.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ signals.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,64 +1,64 @@ -#! /bin/sh -# -CC=cc -export CC - -cat > x.c <<EOF -#include <signal.h> - -main() -{ -} -EOF - -${CC} -E x.c > x.i || { rm -f x.c x.i ; exit 1; } - -if egrep 'void.*signal' x.i >/dev/null 2>&1 -then - echo '#define VOID_SIGHANDLER' -fi -rm -f x.c x.i - -cat > x.c << EOF -#include <signal.h> -sigset_t set, oset; -main() -{ - sigemptyset(&set); - sigemptyset(&oset); - sigaddset(&set, 2); - sigprocmask(SIG_BLOCK, &set, &oset); -} -EOF -if ${CC} x.c >/dev/null 2>&1; then - echo '#define HAVE_POSIX_SIGNALS' -else - cat > x.c << EOF -#include <signal.h> -main() -{ - long omask = sigblock(sigmask(2)); - sigsetmask(omask); -} -EOF - if ${CC} x.c >/dev/null 2>&1; then - echo '#define HAVE_BSD_SIGNALS' - else - cat > x.c << EOF -#include <signal.h> -main() -{ - int n; - n = sighold(2); - sigrelse(2); -} -EOF - if ${CC} x.c >/dev/null 2>&1; then - echo '#define HAVE_USG_SIGHOLD' - fi - fi -fi - -rm -f x.c x.o a.out - -exit 0 +#! /bin/sh +# +CC=cc +export CC + +cat > x.c <<EOF +#include <signal.h> + +main() +{ +} +EOF + +${CC} -E x.c > x.i || { rm -f x.c x.i ; exit 1; } + +if egrep 'void.*signal' x.i >/dev/null 2>&1 +then + echo '#define VOID_SIGHANDLER' +fi +rm -f x.c x.i + +cat > x.c << EOF +#include <signal.h> +sigset_t set, oset; +main() +{ + sigemptyset(&set); + sigemptyset(&oset); + sigaddset(&set, 2); + sigprocmask(SIG_BLOCK, &set, &oset); +} +EOF +if ${CC} x.c >/dev/null 2>&1; then + echo '#define HAVE_POSIX_SIGNALS' +else + cat > x.c << EOF +#include <signal.h> +main() +{ + long omask = sigblock(sigmask(2)); + sigsetmask(omask); +} +EOF + if ${CC} x.c >/dev/null 2>&1; then + echo '#define HAVE_BSD_SIGNALS' + else + cat > x.c << EOF +#include <signal.h> +main() +{ + int n; + n = sighold(2); + sigrelse(2); +} +EOF + if ${CC} x.c >/dev/null 2>&1; then + echo '#define HAVE_USG_SIGHOLD' + fi + fi +fi + +rm -f x.c x.o a.out + +exit 0 Index: stdio.sh =================================================================== RCS file: /cvsroot/winbash/winbash/portbash/stdio.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- stdio.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ stdio.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,87 +1,87 @@ -#! /bin/sh -# -# test certain aspects of stdio -CC=cc -export CC - -cat > x.c << EOF -#include <stdio.h> -#include <varargs.h> - -xp(va_alist) -va_dcl -{ - va_list args; - va_start (args); - vfprintf(stdout, "abcde", args); -} - -main() -{ - xp(); - exit(0); -} -EOF - -if ${CC} x.c >/dev/null 2>&1 -then - echo '#define HAVE_VFPRINTF' - rm -f x.c x.o a.out -else - - cat > x.c << EOF -#include <stdio.h> - -main() -{ - _doprnt(); -} -EOF - - if ${CC} x.c >/dev/null 2>&1 - then - echo '#define USE_VFPRINTF_EMULATION' - rm -f x.c x.o a.out - fi -fi - -cat > x.c << EOF -#include <stdio.h> -main() -{ - setlinebuf(stdout); -} -EOF - -if ${CC} x.c > /dev/null 2>&1 -then - rm -f x.c x.o a.out - echo '#define HAVE_SETLINEBUF' -else - # check for setvbuf - # If this compiles, the system has setvbuf. If this segfaults while - # running, non-reversed systems get a seg violation - - cat > x.c << EOF -#include <stdio.h> - -main() -{ - setvbuf(stdout, _IOLBF, (char *)0, BUFSIZ); /* reversed */ - exit(0); /* non-reversed systems segv */ -} -EOF - - if ${CC} x.c >/dev/null 2>&1 ; then - echo '#define HAVE_SETVBUF' - if a.out; then - : - else - rm -f core - echo '#define REVERSED_SETVBUF_ARGS' - fi - fi -fi - -rm -f x.c x.o a.out -exit 0 +#! /bin/sh +# +# test certain aspects of stdio +CC=cc +export CC + +cat > x.c << EOF +#include <stdio.h> +#include <varargs.h> + +xp(va_alist) +va_dcl +{ + va_list args; + va_start (args); + vfprintf(stdout, "abcde", args); +} + +main() +{ + xp(); + exit(0); +} +EOF + +if ${CC} x.c >/dev/null 2>&1 +then + echo '#define HAVE_VFPRINTF' + rm -f x.c x.o a.out +else + + cat > x.c << EOF +#include <stdio.h> + +main() +{ + _doprnt(); +} +EOF + + if ${CC} x.c >/dev/null 2>&1 + then + echo '#define USE_VFPRINTF_EMULATION' + rm -f x.c x.o a.out + fi +fi + +cat > x.c << EOF +#include <stdio.h> +main() +{ + setlinebuf(stdout); +} +EOF + +if ${CC} x.c > /dev/null 2>&1 +then + rm -f x.c x.o a.out + echo '#define HAVE_SETLINEBUF' +else + # check for setvbuf + # If this compiles, the system has setvbuf. If this segfaults while + # running, non-reversed systems get a seg violation + + cat > x.c << EOF +#include <stdio.h> + +main() +{ + setvbuf(stdout, _IOLBF, (char *)0, BUFSIZ); /* reversed */ + exit(0); /* non-reversed systems segv */ +} +EOF + + if ${CC} x.c >/dev/null 2>&1 ; then + echo '#define HAVE_SETVBUF' + if a.out; then + : + else + rm -f core + echo '#define REVERSED_SETVBUF_ARGS' + fi + fi +fi + +rm -f x.c x.o a.out +exit 0 Index: strings.sh =================================================================== RCS file: /cvsroot/winbash/winbash/portbash/strings.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- strings.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ strings.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,87 +1,87 @@ -#! /bin/sh -CC=cc -export CC - -if [ -f /usr/include/string.h ]; then - STRINGH='<string.h>' -elif [ -f /usr/include/strings.h ]; then - STRINGH='<strings.h>' -else - exit 1 -fi - -cat > x.c << EOF -#include $STRINGH - -#ifndef strchr -extern char *strchr(); -#endif - -char *x = "12345"; - -main() -{ - char *s; - - s = strchr(x, '2'); - if (s) - exit(0); - exit(1); -} -EOF - -if ${CC} x.c >/dev/null 2>&1 -then - if ./a.out - then - echo '#define HAVE_STRCHR' - fi -fi - -rm -f x.c x.o a.out - -cat > x.c << EOF -extern char *strerror(); - -main() -{ - char *s; - - s = strerror(2); - if (s) - exit(0); - exit(1); -} -EOF - -if ${CC} x.c >/dev/null 2>&1 -then - if ./a.out - then - echo '#define HAVE_STRERROR' - fi -fi - -rm -f x.c x.o a.out - - -cat > x.c << EOF - -main() -{ - if (strcasecmp("abc", "AbC") == 0) - exit(0); - exit(1); -} -EOF - -if ${CC} x.c >/dev/null 2>&1 -then - if ./a.out - then - echo '#define HAVE_STRCASECMP' - fi -fi - -rm -f x.c x.o a.out -exit 0 +#! /bin/sh +CC=cc +export CC + +if [ -f /usr/include/string.h ]; then + STRINGH='<string.h>' +elif [ -f /usr/include/strings.h ]; then + STRINGH='<strings.h>' +else + exit 1 +fi + +cat > x.c << EOF +#include $STRINGH + +#ifndef strchr +extern char *strchr(); +#endif + +char *x = "12345"; + +main() +{ + char *s; + + s = strchr(x, '2'); + if (s) + exit(0); + exit(1); +} +EOF + +if ${CC} x.c >/dev/null 2>&1 +then + if ./a.out + then + echo '#define HAVE_STRCHR' + fi +fi + +rm -f x.c x.o a.out + +cat > x.c << EOF +extern char *strerror(); + +main() +{ + char *s; + + s = strerror(2); + if (s) + exit(0); + exit(1); +} +EOF + +if ${CC} x.c >/dev/null 2>&1 +then + if ./a.out + then + echo '#define HAVE_STRERROR' + fi +fi + +rm -f x.c x.o a.out + + +cat > x.c << EOF + +main() +{ + if (strcasecmp("abc", "AbC") == 0) + exit(0); + exit(1); +} +EOF + +if ${CC} x.c >/dev/null 2>&1 +then + if ./a.out + then + echo '#define HAVE_STRCASECMP' + fi +fi + +rm -f x.c x.o a.out +exit 0 Index: syscalls.sh =================================================================== RCS file: /cvsroot/winbash/winbash/portbash/syscalls.sh,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- syscalls.sh 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ syscalls.sh 9 Mar 2002 04:43:16 -0000 1.2 @@ -1,80 +1,80 @@ -#! /bin/sh -CC=cc -export CC - -cat > x.c << EOF -/* - * exit 0 if we have the getgroups system or library call. - */ - -main() -{ - int g[100], ng; - - ng = getgroups(100, g); - if (ng) - exit(0); - exit(1); -} -EOF -if ${CC} x.c > /dev/null 2>&1 && ./a.out ; then - echo '#define HAVE_GETGROUPS' -fi -rm -f x.c x.o a.out - -cat > x.c << EOF -extern int dup2(); -main() -{ - exit(dup2(1, 2) == -1); -} -EOF - -if ${CC} x.c > /dev/null 2>&1 && ./a.out ; then - echo '#define HAVE_DUP2' -fi -rm -f a.out x.c x.o - -cat > x.c << EOF -extern int getpageesize(); -main() -{ - int n = getpagesize(); -} -EOF - -if ${CC} x.c > /dev/null 2>&1 -then - echo '#define HAVE_GETPAGESIZE' -fi -rm -f a.out x.c x.o - -cat > x.c << EOF -extern int getdtablesize(); -main() -{ - int n = getdtablesize(); -} -EOF - -if ${CC} x.c > /dev/null 2>&1 -then - echo '#define HAVE_GETDTABLESIZE' -fi -rm -f a.out x.c x.o - -cat > x.c << EOF -extern int setdtablesize(); -main() -{ - int n = setdtablesize(128); -} -EOF - -if ${CC} x.c > /dev/null 2>&1 -then - echo '#define HAVE_SETDTABLESIZE' -fi -rm -f a.out x.c x.o - -exit 0 +#! /bin/sh +CC=cc +export CC + +cat > x.c << EOF +/* + * exit 0 if we have the getgroups system or library call. + */ + +main() +{ + int g[100], ng; + + ng = getgroups(100, g); + if (ng) + exit(0); + exit(1); +} +EOF +if ${CC} x.c > /dev/null 2>&1 && ./a.out ; then + echo '#define HAVE_GETGROUPS' +fi +rm -f x.c x.o a.out + +cat > x.c << EOF +extern int dup2(); +main() +{ + exit(dup2(1, 2) == -1); +} +EOF + +if ${CC} x.c > /dev/null 2>&1 && ./a.out ; then + echo '#define HAVE_DUP2' +fi +rm -f a.out x.c x.o + +cat > x.c << EOF +extern int getpageesize(); +main() +{ + int n = getpagesize(); +} +EOF + +if ${CC} x.c > /dev/null 2>&1 +then + echo '#define HAVE_GETPAGESIZE' +fi +rm -f a.out x.c x.o + +cat > x.c << EOF +extern int getdtablesize(); +main() +{ + int n = getdtablesize(); +} +EOF + +if ${CC} x.c > /dev/null 2>&1 +then + echo '#define HAVE_GETDTABLESIZE' +fi +rm -f a.out x.c x.o + +cat > x.c << EOF +extern int setdtablesize(); +main() +{ + int n = setdtablesize(128); +} +EOF + +if ${CC} x.c > /dev/null 2>&1 +then + echo '#define HAVE_SETDTABLESIZE' +fi +rm -f a.out x.c x.o + +exit 0 |
From: Enrico B. <enr...@us...> - 2002-03-09 04:43:18
|
Update of /cvsroot/winbash/winbash/CWRU In directory usw-pr-cvs1:/tmp/cvs-serv381/CWRU Modified Files: README Log Message: Fixed more cr/lf problems. Index: README =================================================================== RCS file: /cvsroot/winbash/winbash/CWRU/README,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- README 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ README 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,52 +1,52 @@ -This README file is in -*- text -*- mode, because Emacs likes it that way. - -This is GNU Bash, version 1.14. Bash is the GNU Project's Bourne -Again SHell, an interactive shell with Bourne shell syntax (/bin/sh); -but also with interactive command line editing, job control on -architectures that support it, Csh-like history features and brace -expansion, and a slew of other stuff. For more information on the -features of Bash that are new to this type of shell, see the file -`documentation/features.texi'. There is also a DVI file there, as -well as a large man page. - -To compile it, try typing `make'. Bash auto-configures the build -process, so no intervention should be necessary. If you want to -use gcc, type `make CC=gcc CPPNAME='$(CC) -E''. - -You may want to read the file INSTALL in this directory for more -information if the make fails. - -If you are a csh user and wish to convert your csh aliases to Bash -aliases, you may wish to use the script in examples/alias-conv.sh -as a starting point. - -Bug reports for 1.14 should be sent to: - - bug...@pr... - -using the `bashbug' program that is built and installed at the same -time as bash. - -The discussion list "bug...@pr..." often contains information -about new ports of Bash, or discussions of new features or behavior -changes that people would like. This mailing list is also available -as a usenet newsgroup: gnu.bash.bug. - -When you send a bug report to bas...@pr..., please -include: - - * the version number of Bash - * the machine and OS that it is running on (see .machine or .made) - * a description of the bug - * a recipe for recreating the bug reliably - * a fix for the bug if you have one! - -The `bashbug' program includes much of this automatically. - -While the Bash maintainers do not promise to fix all bugs, we would -like this shell to be the best that we can make it. - -Enjoy! - -Chet Ramey -c...@po... +This README file is in -*- text -*- mode, because Emacs likes it that way. + +This is GNU Bash, version 1.14. Bash is the GNU Project's Bourne +Again SHell, an interactive shell with Bourne shell syntax (/bin/sh); +but also with interactive command line editing, job control on +architectures that support it, Csh-like history features and brace +expansion, and a slew of other stuff. For more information on the +features of Bash that are new to this type of shell, see the file +`documentation/features.texi'. There is also a DVI file there, as +well as a large man page. + +To compile it, try typing `make'. Bash auto-configures the build +process, so no intervention should be necessary. If you want to +use gcc, type `make CC=gcc CPPNAME='$(CC) -E''. + +You may want to read the file INSTALL in this directory for more +information if the make fails. + +If you are a csh user and wish to convert your csh aliases to Bash +aliases, you may wish to use the script in examples/alias-conv.sh +as a starting point. + +Bug reports for 1.14 should be sent to: + + bug...@pr... + +using the `bashbug' program that is built and installed at the same +time as bash. + +The discussion list "bug...@pr..." often contains information +about new ports of Bash, or discussions of new features or behavior +changes that people would like. This mailing list is also available +as a usenet newsgroup: gnu.bash.bug. + +When you send a bug report to bas...@pr..., please +include: + + * the version number of Bash + * the machine and OS that it is running on (see .machine or .made) + * a description of the bug + * a recipe for recreating the bug reliably + * a fix for the bug if you have one! + +The `bashbug' program includes much of this automatically. + +While the Bash maintainers do not promise to fix all bugs, we would +like this shell to be the best that we can make it. + +Enjoy! + +Chet Ramey +c...@po... |
From: Enrico B. <enr...@us...> - 2002-03-09 04:43:18
|
Update of /cvsroot/winbash/winbash/bison In directory usw-pr-cvs1:/tmp/cvs-serv381/bison Modified Files: bison.exe bison.hairy bison.simple Log Message: Fixed more cr/lf problems. Index: bison.exe =================================================================== RCS file: /cvsroot/winbash/winbash/bison/bison.exe,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 Binary files /tmp/cvsAk102N and /tmp/cvsoPehCt differ Index: bison.hairy =================================================================== RCS file: /cvsroot/winbash/winbash/bison/bison.hairy,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bison.hairy 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ bison.hairy 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,334 +1,334 @@ - -extern int timeclock; - - -int yyerror; /* Yyerror and yycost are set by guards. */ -int yycost; /* If yyerror is set to a nonzero value by a */ - /* guard, the reduction with which the guard */ - /* is associated is not performed, and the */ - /* error recovery mechanism is invoked. */ - /* Yycost indicates the cost of performing */ - /* the reduction given the attributes of the */ - /* symbols. */ - - -/* YYMAXDEPTH indicates the size of the parser's state and value */ -/* stacks. */ - -#ifndef YYMAXDEPTH -#define YYMAXDEPTH 500 -#endif - -/* YYMAXRULES must be at least as large as the number of rules that */ -/* could be placed in the rule queue. That number could be determined */ -/* from the grammar and the size of the stack, but, as yet, it is not. */ - -#ifndef YYMAXRULES -#define YYMAXRULES 100 -#endif - -#ifndef YYMAXBACKUP -#define YYMAXBACKUP 100 -#endif - - -short yyss[YYMAXDEPTH]; /* the state stack */ -YYSTYPE yyvs[YYMAXDEPTH]; /* the semantic value stack */ -YYLTYPE yyls[YYMAXDEPTH]; /* the location stack */ -short yyrq[YYMAXRULES]; /* the rule queue */ -int yychar; /* the lookahead symbol */ - -YYSTYPE yylval; /* the semantic value of the */ - /* lookahead symbol */ - -YYSTYPE yytval; /* the semantic value for the state */ - /* at the top of the state stack. */ - -YYSTYPE yyval; /* the variable used to return */ - /* semantic values from the action */ - /* routines */ - -YYLTYPE yylloc; /* location data for the lookahead */ - /* symbol */ - -YYLTYPE yytloc; /* location data for the state at the */ - /* top of the state stack */ - - -int yynunlexed; -short yyunchar[YYMAXBACKUP]; -YYSTYPE yyunval[YYMAXBACKUP]; -YYLTYPE yyunloc[YYMAXBACKUP]; - -short *yygssp; /* a pointer to the top of the state */ - /* stack; only set during error */ - /* recovery. */ - -YYSTYPE *yygvsp; /* a pointer to the top of the value */ - /* stack; only set during error */ - /* recovery. */ - -YYLTYPE *yyglsp; /* a pointer to the top of the */ - /* location stack; only set during */ - /* error recovery. */ - - -/* Yyget is an interface between the parser and the lexical analyzer. */ -/* It is costly to provide such an interface, but it avoids requiring */ -/* the lexical analyzer to be able to back up the scan. */ - -yyget() -{ - if (yynunlexed > 0) - { - yynunlexed--; - yychar = yyunchar[yynunlexed]; - yylval = yyunval[yynunlexed]; - yylloc = yyunloc[yynunlexed]; - } - else if (yychar <= 0) - yychar = 0; - else - { - yychar = yylex(); - if (yychar < 0) - yychar = 0; - else yychar = YYTRANSLATE(yychar); - } -} - - - -yyunlex(chr, val, loc) -int chr; -YYSTYPE val; -YYLTYPE loc; -{ - yyunchar[yynunlexed] = chr; - yyunval[yynunlexed] = val; - yyunloc[yynunlexed] = loc; - yynunlexed++; -} - - - -yyrestore(first, last) -register short *first; -register short *last; -{ - register short *ssp; - register short *rp; - register int symbol; - register int state; - register int tvalsaved; - - ssp = yygssp; - yyunlex(yychar, yylval, yylloc); - - tvalsaved = 0; - while (first != last) - { - symbol = yystos[*ssp]; - if (symbol < YYNTBASE) - { - yyunlex(symbol, yytval, yytloc); - tvalsaved = 1; - ssp--; - } - - ssp--; - - if (first == yyrq) - first = yyrq + YYMAXRULES; - - first--; - - for (rp = yyrhs + yyprhs[*first]; symbol = *rp; rp++) - { - if (symbol < YYNTBASE) - state = yytable[yypact[*ssp] + symbol]; - else - { - state = yypgoto[symbol - YYNTBASE] + *ssp; - - if (state >= 0 && state <= YYLAST && yycheck[state] == *ssp) - state = yytable[state]; - else - state = yydefgoto[symbol - YYNTBASE]; - } - - *++ssp = state; - } - } - - if ( ! tvalsaved && ssp > yyss) - { - yyunlex(yystos[*ssp], yytval, yytloc); - ssp--; - } - - yygssp = ssp; -} - - - -int -yyparse() -{ - register int yystate; - register int yyn; - register short *yyssp; - register short *yyrq0; - register short *yyptr; - register YYSTYPE *yyvsp; - - int yylen; - YYLTYPE *yylsp; - short *yyrq1; - short *yyrq2; - - yystate = 0; - yyssp = yyss - 1; - yyvsp = yyvs - 1; - yylsp = yyls - 1; - yyrq0 = yyrq; - yyrq1 = yyrq0; - yyrq2 = yyrq0; - - yychar = yylex(); - if (yychar < 0) - yychar = 0; - else yychar = YYTRANSLATE(yychar); - -yynewstate: - - if (yyssp >= yyss + YYMAXDEPTH - 1) - { - yyabort("Parser Stack Overflow"); - YYABORT; - } - - *++yyssp = yystate; - -yyresume: - - yyn = yypact[yystate]; - if (yyn == YYFLAG) - goto yydefault; - - yyn += yychar; - if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar) - goto yydefault; - - yyn = yytable[yyn]; - if (yyn < 0) - { - yyn = -yyn; - goto yyreduce; - } - else if (yyn == 0) - goto yyerrlab; - - yystate = yyn; - - yyptr = yyrq2; - while (yyptr != yyrq1) - { - yyn = *yyptr++; - yylen = yyr2[yyn]; - yyvsp -= yylen; - yylsp -= yylen; - - yyguard(yyn, yyvsp, yylsp); - if (yyerror) - goto yysemerr; - - yyaction(yyn, yyvsp, yylsp); - *++yyvsp = yyval; - - yylsp++; - if (yylen == 0) - { - yylsp->timestamp = timeclock; - yylsp->first_line = yytloc.first_line; - yylsp->first_column = yytloc.first_column; - yylsp->last_line = (yylsp-1)->last_line; - yylsp->last_column = (yylsp-1)->last_column; - yylsp->text = 0; - } - else - { - yylsp->last_line = (yylsp+yylen-1)->last_line; - yylsp->last_column = (yylsp+yylen-1)->last_column; - } - - if (yyptr == yyrq + YYMAXRULES) - yyptr = yyrq; - } - - if (yystate == YYFINAL) - YYACCEPT; - - yyrq2 = yyptr; - yyrq1 = yyrq0; - - *++yyvsp = yytval; - *++yylsp = yytloc; - yytval = yylval; - yytloc = yylloc; - yyget(); - - goto yynewstate; - -yydefault: - - yyn = yydefact[yystate]; - if (yyn == 0) - goto yyerrlab; - -yyreduce: - - *yyrq0++ = yyn; - - if (yyrq0 == yyrq + YYMAXRULES) - yyrq0 = yyrq; - - if (yyrq0 == yyrq2) - { - yyabort("Parser Rule Queue Overflow"); - YYABORT; - } - - yyssp -= yyr2[yyn]; - yyn = yyr1[yyn]; - - yystate = yypgoto[yyn - YYNTBASE] + *yyssp; - if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp) - yystate = yytable[yystate]; - else - yystate = yydefgoto[yyn - YYNTBASE]; - - goto yynewstate; - -yysemerr: - *--yyptr = yyn; - yyrq2 = yyptr; - yyvsp += yyr2[yyn]; - -yyerrlab: - - yygssp = yyssp; - yygvsp = yyvsp; - yyglsp = yylsp; - yyrestore(yyrq0, yyrq2); - yyrecover(); - yystate = *yygssp; - yyssp = yygssp; - yyvsp = yygvsp; - yyrq0 = yyrq; - yyrq1 = yyrq0; - yyrq2 = yyrq0; - goto yyresume; -} - -$ + +extern int timeclock; + + +int yyerror; /* Yyerror and yycost are set by guards. */ +int yycost; /* If yyerror is set to a nonzero value by a */ + /* guard, the reduction with which the guard */ + /* is associated is not performed, and the */ + /* error recovery mechanism is invoked. */ + /* Yycost indicates the cost of performing */ + /* the reduction given the attributes of the */ + /* symbols. */ + + +/* YYMAXDEPTH indicates the size of the parser's state and value */ +/* stacks. */ + +#ifndef YYMAXDEPTH +#define YYMAXDEPTH 500 +#endif + +/* YYMAXRULES must be at least as large as the number of rules that */ +/* could be placed in the rule queue. That number could be determined */ +/* from the grammar and the size of the stack, but, as yet, it is not. */ + +#ifndef YYMAXRULES +#define YYMAXRULES 100 +#endif + +#ifndef YYMAXBACKUP +#define YYMAXBACKUP 100 +#endif + + +short yyss[YYMAXDEPTH]; /* the state stack */ +YYSTYPE yyvs[YYMAXDEPTH]; /* the semantic value stack */ +YYLTYPE yyls[YYMAXDEPTH]; /* the location stack */ +short yyrq[YYMAXRULES]; /* the rule queue */ +int yychar; /* the lookahead symbol */ + +YYSTYPE yylval; /* the semantic value of the */ + /* lookahead symbol */ + +YYSTYPE yytval; /* the semantic value for the state */ + /* at the top of the state stack. */ + +YYSTYPE yyval; /* the variable used to return */ + /* semantic values from the action */ + /* routines */ + +YYLTYPE yylloc; /* location data for the lookahead */ + /* symbol */ + +YYLTYPE yytloc; /* location data for the state at the */ + /* top of the state stack */ + + +int yynunlexed; +short yyunchar[YYMAXBACKUP]; +YYSTYPE yyunval[YYMAXBACKUP]; +YYLTYPE yyunloc[YYMAXBACKUP]; + +short *yygssp; /* a pointer to the top of the state */ + /* stack; only set during error */ + /* recovery. */ + +YYSTYPE *yygvsp; /* a pointer to the top of the value */ + /* stack; only set during error */ + /* recovery. */ + +YYLTYPE *yyglsp; /* a pointer to the top of the */ + /* location stack; only set during */ + /* error recovery. */ + + +/* Yyget is an interface between the parser and the lexical analyzer. */ +/* It is costly to provide such an interface, but it avoids requiring */ +/* the lexical analyzer to be able to back up the scan. */ + +yyget() +{ + if (yynunlexed > 0) + { + yynunlexed--; + yychar = yyunchar[yynunlexed]; + yylval = yyunval[yynunlexed]; + yylloc = yyunloc[yynunlexed]; + } + else if (yychar <= 0) + yychar = 0; + else + { + yychar = yylex(); + if (yychar < 0) + yychar = 0; + else yychar = YYTRANSLATE(yychar); + } +} + + + +yyunlex(chr, val, loc) +int chr; +YYSTYPE val; +YYLTYPE loc; +{ + yyunchar[yynunlexed] = chr; + yyunval[yynunlexed] = val; + yyunloc[yynunlexed] = loc; + yynunlexed++; +} + + + +yyrestore(first, last) +register short *first; +register short *last; +{ + register short *ssp; + register short *rp; + register int symbol; + register int state; + register int tvalsaved; + + ssp = yygssp; + yyunlex(yychar, yylval, yylloc); + + tvalsaved = 0; + while (first != last) + { + symbol = yystos[*ssp]; + if (symbol < YYNTBASE) + { + yyunlex(symbol, yytval, yytloc); + tvalsaved = 1; + ssp--; + } + + ssp--; + + if (first == yyrq) + first = yyrq + YYMAXRULES; + + first--; + + for (rp = yyrhs + yyprhs[*first]; symbol = *rp; rp++) + { + if (symbol < YYNTBASE) + state = yytable[yypact[*ssp] + symbol]; + else + { + state = yypgoto[symbol - YYNTBASE] + *ssp; + + if (state >= 0 && state <= YYLAST && yycheck[state] == *ssp) + state = yytable[state]; + else + state = yydefgoto[symbol - YYNTBASE]; + } + + *++ssp = state; + } + } + + if ( ! tvalsaved && ssp > yyss) + { + yyunlex(yystos[*ssp], yytval, yytloc); + ssp--; + } + + yygssp = ssp; +} + + + +int +yyparse() +{ + register int yystate; + register int yyn; + register short *yyssp; + register short *yyrq0; + register short *yyptr; + register YYSTYPE *yyvsp; + + int yylen; + YYLTYPE *yylsp; + short *yyrq1; + short *yyrq2; + + yystate = 0; + yyssp = yyss - 1; + yyvsp = yyvs - 1; + yylsp = yyls - 1; + yyrq0 = yyrq; + yyrq1 = yyrq0; + yyrq2 = yyrq0; + + yychar = yylex(); + if (yychar < 0) + yychar = 0; + else yychar = YYTRANSLATE(yychar); + +yynewstate: + + if (yyssp >= yyss + YYMAXDEPTH - 1) + { + yyabort("Parser Stack Overflow"); + YYABORT; + } + + *++yyssp = yystate; + +yyresume: + + yyn = yypact[yystate]; + if (yyn == YYFLAG) + goto yydefault; + + yyn += yychar; + if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar) + goto yydefault; + + yyn = yytable[yyn]; + if (yyn < 0) + { + yyn = -yyn; + goto yyreduce; + } + else if (yyn == 0) + goto yyerrlab; + + yystate = yyn; + + yyptr = yyrq2; + while (yyptr != yyrq1) + { + yyn = *yyptr++; + yylen = yyr2[yyn]; + yyvsp -= yylen; + yylsp -= yylen; + + yyguard(yyn, yyvsp, yylsp); + if (yyerror) + goto yysemerr; + + yyaction(yyn, yyvsp, yylsp); + *++yyvsp = yyval; + + yylsp++; + if (yylen == 0) + { + yylsp->timestamp = timeclock; + yylsp->first_line = yytloc.first_line; + yylsp->first_column = yytloc.first_column; + yylsp->last_line = (yylsp-1)->last_line; + yylsp->last_column = (yylsp-1)->last_column; + yylsp->text = 0; + } + else + { + yylsp->last_line = (yylsp+yylen-1)->last_line; + yylsp->last_column = (yylsp+yylen-1)->last_column; + } + + if (yyptr == yyrq + YYMAXRULES) + yyptr = yyrq; + } + + if (yystate == YYFINAL) + YYACCEPT; + + yyrq2 = yyptr; + yyrq1 = yyrq0; + + *++yyvsp = yytval; + *++yylsp = yytloc; + yytval = yylval; + yytloc = yylloc; + yyget(); + + goto yynewstate; + +yydefault: + + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + +yyreduce: + + *yyrq0++ = yyn; + + if (yyrq0 == yyrq + YYMAXRULES) + yyrq0 = yyrq; + + if (yyrq0 == yyrq2) + { + yyabort("Parser Rule Queue Overflow"); + YYABORT; + } + + yyssp -= yyr2[yyn]; + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTBASE] + *yyssp; + if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTBASE]; + + goto yynewstate; + +yysemerr: + *--yyptr = yyn; + yyrq2 = yyptr; + yyvsp += yyr2[yyn]; + +yyerrlab: + + yygssp = yyssp; + yygvsp = yyvsp; + yyglsp = yylsp; + yyrestore(yyrq0, yyrq2); + yyrecover(); + yystate = *yygssp; + yyssp = yygssp; + yyvsp = yygvsp; + yyrq0 = yyrq; + yyrq1 = yyrq0; + yyrq2 = yyrq0; + goto yyresume; +} + +$ Index: bison.simple =================================================================== RCS file: /cvsroot/winbash/winbash/bison/bison.simple,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bison.simple 9 Mar 2002 03:39:13 -0000 1.1.1.1 +++ bison.simple 9 Mar 2002 04:43:15 -0000 1.2 @@ -1,686 +1,686 @@ -/* -*-C-*- Note some compilers choke on comments on `#line' lines. */ -#line 3 "bison.simple" - -/* Skeleton output parser for bison, - Copyright (C) 1984, 1989, 1990 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2, or (at your option) - any later version. - [...1341 lines suppressed...] + } + else if (yyn == 0) + goto yyerrpop; + + if (yyn == YYFINAL) + YYACCEPT; + +#if YYDEBUG != 0 + if (yydebug) + fprintf(stderr, "Shifting error token, "); +#endif + + *++yyvsp = yylval; +#ifdef YYLSP_NEEDED + *++yylsp = yylloc; +#endif + + yystate = yyn; + goto yynewstate; +} |
From: Enrico B. <enr...@us...> - 2002-03-09 04:43:18
|
Update of /cvsroot/winbash/winbash In directory usw-pr-cvs1:/tmp/cvs-serv381 Modified Files: .build .machine Log Message: Fixed more cr/lf problems. Index: .build =================================================================== RCS file: /cvsroot/winbash/winbash/.build,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- .build 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ .build 9 Mar 2002 04:43:15 -0000 1.2 @@ -1 +1 @@ -7 +7 Index: .machine =================================================================== RCS file: /cvsroot/winbash/winbash/.machine,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- .machine 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ .machine 9 Mar 2002 04:43:15 -0000 1.2 @@ -1 +1 @@ -bash last made for a i386 running NT +bash last made for a i386 running NT |
Update of /cvsroot/winbash/winbash/builtins In directory usw-pr-cvs1:/tmp/cvs-serv29857 Modified Files: alias.def bashgetopt.c bashgetopt.h bind.def break.def builtin.def cd.def colon.def command.def common.c common.h declare.def echo.def enable.def eval.def exec.def exit.def fc.def fg_bg.def getopt.c getopt.h getopts.def hash.def hashcom.h help.def history.def inlib.def jobs.def kill.def let.def mkbuiltins.c pipesize.h psize.c psize.sh read.def reserved.def return.def send_files set.def setattr.def shift.def source.def suspend.def test.def times.def trap.def type.def ulimit.def umask.def wait.def Log Message: Fixed cr/lf problems.... Index: alias.def =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/alias.def,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- alias.def 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ alias.def 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,180 +1,180 @@ -This file is alias.def, from which is created alias.c -It implements the builtins "alias" and "unalias" in Bash. - -Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. - -This file is part of GNU Bash, the Bourne Again SHell. - -Bash is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 1, or (at your option) any later -version. - -Bash is distributed in the hope that it will be useful, but WITHOUT ANY -WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -for more details. - -You should have received a copy of the GNU General Public License along -with Bash; see the file COPYING. If not, write to the Free Software -Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. - -$BUILTIN alias -$FUNCTION alias_builtin -$DEPENDS_ON ALIAS -$PRODUCES alias.c -$SHORT_DOC alias [ name[=value] ... ] -`alias' with no arguments prints the list of aliases in the form -NAME=VALUE on standard output. An alias is defined for each NAME -whose VALUE is given. A trailing space in VALUE causes the next -word to be checked for alias substitution. Alias returns true -unless a NAME is given for which no alias has been defined. -$END - -#include "../config.h" - -#if defined (ALIAS) -# include <stdio.h> -# include "../shell.h" -# include "../alias.h" -# include "nt_types.h" -# include "common.h" - -static void print_alias (); - -/* Hack the alias command in a Korn shell way. */ -alias_builtin (list) - WORD_LIST *list; -{ - int any_failed = 0; - - if (!list) - { - register int i; - ASSOC **alias_list; - - if (!aliases) - return (EXECUTION_FAILURE); - - alias_list = all_aliases (); - - if (!alias_list) - return (EXECUTION_FAILURE); - - for (i = 0; alias_list[i]; i++) - print_alias (alias_list[i]); - - free (alias_list); /* XXX - Do not free the strings. */ - } - else - { - while (list) - { - register char *value, *name = list->word->word; - register int offset; - - for (offset = 0; name[offset] && name[offset] != '='; offset++) - ; - - if (offset && name[offset] == '=') - { - name[offset] = '\0'; - value = name + offset + 1; - - add_alias (name, value); - } - else - { - ASSOC *t = find_alias (name); - if (t) - print_alias (t); - else - { - if (thr_me->interactive) - builtin_error ("`%s' not found", name); - any_failed++; - } - } - list = list->next; - } - } - if (any_failed) - return (EXECUTION_FAILURE); - else - return (EXECUTION_SUCCESS); -} -#endif /* ALIAS */ - -$BUILTIN unalias -$FUNCTION unalias_builtin -$DEPENDS_ON ALIAS -$SHORT_DOC unalias [-a] [name ...] -Remove NAMEs from the list of defined aliases. If the -a option is given, -then remove all alias definitions. -$END - -#if defined (ALIAS) -/* Remove aliases named in LIST from the aliases database. */ -unalias_builtin (list) - register WORD_LIST *list; -{ - register ASSOC *alias; - int any_failed = 0; - - while (list && *list->word->word == '-') - { - register char *word = list->word->word; - - if (ISOPTION (word, 'a')) - { - delete_all_aliases (); - list = list->next; - } - else if (ISOPTION (word, '-')) - { - list = list->next; - break; - } - else - { - bad_option (word); - return (EXECUTION_FAILURE); - } - } - - while (list) - { - alias = find_alias (list->word->word); - - if (alias) - remove_alias (alias->name); - else - { - if (thr_me->interactive) - builtin_error ("`%s' not an alias", list->word->word); - - any_failed++; - } - - list = list->next; - } - - if (any_failed) - return (EXECUTION_FAILURE); - else - return (EXECUTION_SUCCESS); -} - -/* Output ALIAS in such a way as to allow it to be read back in. */ -static void -print_alias (alias) - ASSOC *alias; -{ - char *value = single_quote (alias->value); - - printf ("alias %s=%s\n", alias->name, value); - free (value); - - fflush (stdout); -} -#endif /* ALIAS */ +This file is alias.def, from which is created alias.c +It implements the builtins "alias" and "unalias" in Bash. + +Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. + +This file is part of GNU Bash, the Bourne Again SHell. + +Bash is free software; you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation; either version 1, or (at your option) any later +version. + +Bash is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License along +with Bash; see the file COPYING. If not, write to the Free Software +Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + +$BUILTIN alias +$FUNCTION alias_builtin +$DEPENDS_ON ALIAS +$PRODUCES alias.c +$SHORT_DOC alias [ name[=value] ... ] +`alias' with no arguments prints the list of aliases in the form +NAME=VALUE on standard output. An alias is defined for each NAME +whose VALUE is given. A trailing space in VALUE causes the next +word to be checked for alias substitution. Alias returns true +unless a NAME is given for which no alias has been defined. +$END + +#include "../config.h" + +#if defined (ALIAS) +# include <stdio.h> +# include "../shell.h" +# include "../alias.h" +# include "nt_types.h" +# include "common.h" + +static void print_alias (); + +/* Hack the alias command in a Korn shell way. */ +alias_builtin (list) + WORD_LIST *list; +{ + int any_failed = 0; + + if (!list) + { + register int i; + ASSOC **alias_list; + + if (!aliases) + return (EXECUTION_FAILURE); + + alias_list = all_aliases (); + + if (!alias_list) + return (EXECUTION_FAILURE); + + for (i = 0; alias_list[i]; i++) + print_alias (alias_list[i]); + + free (alias_list); /* XXX - Do not free the strings. */ + } + else + { + while (list) + { + register char *value, *name = list->word->word; + register int offset; + + for (offset = 0; name[offset] && name[offset] != '='; offset++) + ; + + if (offset && name[offset] == '=') + { + name[offset] = '\0'; + value = name + offset + 1; + + add_alias (name, value); + } + else + { + ASSOC *t = find_alias (name); + if (t) + print_alias (t); + else + { + if (thr_me->interactive) + builtin_error ("`%s' not found", name); + any_failed++; + } + } + list = list->next; + } + } + if (any_failed) + return (EXECUTION_FAILURE); + else + return (EXECUTION_SUCCESS); +} +#endif /* ALIAS */ + +$BUILTIN unalias +$FUNCTION unalias_builtin +$DEPENDS_ON ALIAS +$SHORT_DOC unalias [-a] [name ...] +Remove NAMEs from the list of defined aliases. If the -a option is given, +then remove all alias definitions. +$END + +#if defined (ALIAS) +/* Remove aliases named in LIST from the aliases database. */ +unalias_builtin (list) + register WORD_LIST *list; +{ + register ASSOC *alias; + int any_failed = 0; + + while (list && *list->word->word == '-') + { + register char *word = list->word->word; + + if (ISOPTION (word, 'a')) + { + delete_all_aliases (); + list = list->next; + } + else if (ISOPTION (word, '-')) + { + list = list->next; + break; + } + else + { + bad_option (word); + return (EXECUTION_FAILURE); + } + } + + while (list) + { + alias = find_alias (list->word->word); + + if (alias) + remove_alias (alias->name); + else + { + if (thr_me->interactive) + builtin_error ("`%s' not an alias", list->word->word); + + any_failed++; + } + + list = list->next; + } + + if (any_failed) + return (EXECUTION_FAILURE); + else + return (EXECUTION_SUCCESS); +} + +/* Output ALIAS in such a way as to allow it to be read back in. */ +static void +print_alias (alias) + ASSOC *alias; +{ + char *value = single_quote (alias->value); + + printf ("alias %s=%s\n", alias->name, value); + free (value); + + fflush (stdout); +} +#endif /* ALIAS */ Index: bashgetopt.c =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/bashgetopt.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bashgetopt.c 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ bashgetopt.c 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,136 +1,136 @@ -/* bashgetopt.c -- `getopt' for use by the builtins. */ - -/* Copyright (C) 1992 Free Software Foundation, Inc. - -This file is part of GNU Bash, the Bourne Again SHell. - -Bash is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 1, or (at your option) any later -version. - -Bash is distributed in the hope that it will be useful, but WITHOUT ANY -WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -for more details. - -You should have received a copy of the GNU General Public License along -with Bash; see the file COPYING. If not, write to the Free Software -Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ - -#include <errno.h> -#include "shell.h" - -#include "bashansi.h" - -#define ERR(S, C) builtin_error("%s%c", (S), (C)) - -static int sp; - -char *list_optarg; -int list_optopt; - -static WORD_LIST *lhead = (WORD_LIST *)NULL; -WORD_LIST *lcurrent = (WORD_LIST *)NULL; -WORD_LIST *loptend; /* Points to the first non-option argument in the list */ - -int -internal_getopt(list, opts) -WORD_LIST *list; -char *opts; -{ - register int c; - register char *cp; - - if (!list) { - list_optarg = (char *)NULL; - loptend = (WORD_LIST *)NULL; /* No non-option arguments */ - return -1; - } - - if (list != lhead || !lhead) { - /* Hmmm.... called with a different word list. Reset. */ - sp = 1; - lcurrent = lhead = list; - loptend = (WORD_LIST *)NULL; - } - - if (sp == 1) { - if (!lcurrent || - (lcurrent->word->word[0] != '-' || lcurrent->word->word[1] == '\0')) { - lhead = (WORD_LIST *)NULL; - loptend = lcurrent; - return(-1); - } else if (lcurrent->word->word[0] == '-' && - lcurrent->word->word[1] == '-' && - lcurrent->word->word[2] == 0) { - lhead = (WORD_LIST *)NULL; - loptend = lcurrent->next; - return(-1); - } - } - - list_optopt = c = lcurrent->word->word[sp]; - - if (c == ':' || (cp = strchr(opts, c)) == NULL) { - ERR("illegal option: -", c); - if (lcurrent->word->word[++sp] == '\0') { - lcurrent = lcurrent->next; - sp = 1; - } - list_optarg = NULL; - if (lcurrent) - loptend = lcurrent->next; - return('?'); - } - - if (*++cp == ':') { - /* Option requires an argument. */ - /* We allow -l2 as equivalent to -l 2 */ - if (lcurrent->word->word[sp+1] != '\0') { - list_optarg = &(lcurrent->word->word[sp+1]); - lcurrent = lcurrent->next; - } else if (lcurrent->next == NULL) { - ERR("option requires an argument: -", c); - sp = 1; - list_optarg = (char *)NULL; - return('?'); - } else { - lcurrent = lcurrent->next; - list_optarg = lcurrent->word->word; - lcurrent = lcurrent->next; - } - sp = 1; - } else { - /* No argument, just return the option. */ - if (lcurrent->word->word[++sp] == '\0') { - sp = 1; - lcurrent = lcurrent->next; - } - list_optarg = (char *)NULL; - } - - return(c); -} - -/* - * reset_internal_getopt -- force the in[ft]ernal getopt to reset - */ - -void -reset_internal_getopt () -{ - lhead = lcurrent = loptend = (WORD_LIST *)NULL; - sp = 1; -} - -void -report_bad_option () -{ - char s[3]; - - s[0] = '-'; - s[1] = list_optopt; - s[2] = '\0'; - bad_option (s); -} +/* bashgetopt.c -- `getopt' for use by the builtins. */ + +/* Copyright (C) 1992 Free Software Foundation, Inc. + +This file is part of GNU Bash, the Bourne Again SHell. + +Bash is free software; you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation; either version 1, or (at your option) any later +version. + +Bash is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License along +with Bash; see the file COPYING. If not, write to the Free Software +Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ + +#include <errno.h> +#include "shell.h" + +#include "bashansi.h" + +#define ERR(S, C) builtin_error("%s%c", (S), (C)) + +static int sp; + +char *list_optarg; +int list_optopt; + +static WORD_LIST *lhead = (WORD_LIST *)NULL; +WORD_LIST *lcurrent = (WORD_LIST *)NULL; +WORD_LIST *loptend; /* Points to the first non-option argument in the list */ + +int +internal_getopt(list, opts) +WORD_LIST *list; +char *opts; +{ + register int c; + register char *cp; + + if (!list) { + list_optarg = (char *)NULL; + loptend = (WORD_LIST *)NULL; /* No non-option arguments */ + return -1; + } + + if (list != lhead || !lhead) { + /* Hmmm.... called with a different word list. Reset. */ + sp = 1; + lcurrent = lhead = list; + loptend = (WORD_LIST *)NULL; + } + + if (sp == 1) { + if (!lcurrent || + (lcurrent->word->word[0] != '-' || lcurrent->word->word[1] == '\0')) { + lhead = (WORD_LIST *)NULL; + loptend = lcurrent; + return(-1); + } else if (lcurrent->word->word[0] == '-' && + lcurrent->word->word[1] == '-' && + lcurrent->word->word[2] == 0) { + lhead = (WORD_LIST *)NULL; + loptend = lcurrent->next; + return(-1); + } + } + + list_optopt = c = lcurrent->word->word[sp]; + + if (c == ':' || (cp = strchr(opts, c)) == NULL) { + ERR("illegal option: -", c); + if (lcurrent->word->word[++sp] == '\0') { + lcurrent = lcurrent->next; + sp = 1; + } + list_optarg = NULL; + if (lcurrent) + loptend = lcurrent->next; + return('?'); + } + + if (*++cp == ':') { + /* Option requires an argument. */ + /* We allow -l2 as equivalent to -l 2 */ + if (lcurrent->word->word[sp+1] != '\0') { + list_optarg = &(lcurrent->word->word[sp+1]); + lcurrent = lcurrent->next; + } else if (lcurrent->next == NULL) { + ERR("option requires an argument: -", c); + sp = 1; + list_optarg = (char *)NULL; + return('?'); + } else { + lcurrent = lcurrent->next; + list_optarg = lcurrent->word->word; + lcurrent = lcurrent->next; + } + sp = 1; + } else { + /* No argument, just return the option. */ + if (lcurrent->word->word[++sp] == '\0') { + sp = 1; + lcurrent = lcurrent->next; + } + list_optarg = (char *)NULL; + } + + return(c); +} + +/* + * reset_internal_getopt -- force the in[ft]ernal getopt to reset + */ + +void +reset_internal_getopt () +{ + lhead = lcurrent = loptend = (WORD_LIST *)NULL; + sp = 1; +} + +void +report_bad_option () +{ + char s[3]; + + s[0] = '-'; + s[1] = list_optopt; + s[2] = '\0'; + bad_option (s); +} Index: bashgetopt.h =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/bashgetopt.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bashgetopt.h 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ bashgetopt.h 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,37 +1,37 @@ -/* bashgetopt.h -- extern declarations for stuff defined in bashgetopt.c. */ - -/* Copyright (C) 1993 Free Software Foundation, Inc. - - This file is part of GNU Bash, the Bourne Again SHell. - - Bash is free software; you can redistribute it and/or modify it under - the terms of the GNU General Public License as published by the Free - Software Foundation; either version 2, or (at your option) any later - version. - - Bash is distributed in the hope that it will be useful, but WITHOUT ANY - WARRANTY; without even the implied warranty of MERCHANTABILITY or - FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - for more details. - - You should have received a copy of the GNU General Public License along - with Bash; see the file COPYING. If not, write to the Free Software - Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ - -/* See getopt.h for the explanation of these variables. */ - -#if !defined (__BASH_GETOPT_H) -# define __BASH_GETOPT_H - -extern char *list_optarg; - -extern int list_optopt; - -extern WORD_LIST *lcurrent; -extern WORD_LIST *loptend; - -extern int internal_getopt (); -extern void reset_internal_getopt (); -extern void report_bad_option (); - -#endif /* !__BASH_GETOPT_H */ +/* bashgetopt.h -- extern declarations for stuff defined in bashgetopt.c. */ + +/* Copyright (C) 1993 Free Software Foundation, Inc. + + This file is part of GNU Bash, the Bourne Again SHell. + + Bash is free software; you can redistribute it and/or modify it under + the terms of the GNU General Public License as published by the Free + Software Foundation; either version 2, or (at your option) any later + version. + + Bash is distributed in the hope that it will be useful, but WITHOUT ANY + WARRANTY; without even the implied warranty of MERCHANTABILITY or + FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + for more details. + + You should have received a copy of the GNU General Public License along + with Bash; see the file COPYING. If not, write to the Free Software + Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ + +/* See getopt.h for the explanation of these variables. */ + +#if !defined (__BASH_GETOPT_H) +# define __BASH_GETOPT_H + +extern char *list_optarg; + +extern int list_optopt; + +extern WORD_LIST *lcurrent; +extern WORD_LIST *loptend; + +extern int internal_getopt (); +extern void reset_internal_getopt (); +extern void report_bad_option (); + +#endif /* !__BASH_GETOPT_H */ Index: bind.def =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/bind.def,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- bind.def 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ bind.def 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,219 +1,219 @@ -This file is bind.def, from which is created bind.c. -It implements the builtin "bind" in Bash. - -Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. - -This file is part of GNU Bash, the Bourne Again SHell. - -Bash is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 1, or (at your option) any later -version. - -Bash is distributed in the hope that it will be useful, but WITHOUT ANY -WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -for more details. - -You should have received a copy of the GNU General Public License along -with Bash; see the file COPYING. If not, write to the Free Software -Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. - -$PRODUCES bind.c - -$BUILTIN bind -$DEPENDS_ON READLINE -$FUNCTION bind_builtin -$SHORT_DOC bind [-lvd] [-m keymap] [-f filename] [-q name] [keyseq:readline-function] -Bind a key sequence to a Readline function, or to a macro. The -syntax is equivalent to that found in ~/.inputrc, but must be -passed as a single argument: bind '"\C-x\C-r": re-read-init-file'. -Arguments we accept: - -m keymap Use `keymap' as the keymap for the duration of this - command. Acceptable keymap names are emacs, - emacs-standard, emacs-meta, emacs-ctlx, vi, vi-move, - vi-command, and vi-insert. - -l List names of functions. - -v List function names and bindings. - -d Dump functions and bindings such that they - can be read back in. - -f filename Read key bindings from FILENAME. - -q function-name Query about which keys invoke the named function. -$END - -#include <stdio.h> -#include "../shell.h" -#if defined (READLINE) -#include <errno.h> -#if !defined (errno) -extern int errno; -#endif /* !errno */ -#include <readline/readline.h> -#include <readline/history.h> -#include "bashgetopt.h" - -static int query_bindings (); - -extern int bash_readline_initialized; -extern int no_line_editing; - -#define BIND_RETURN(x) do { return_code = x; goto bind_exit; } while (0) - -#define USAGE "usage: bind [-lvd] [-m keymap] [-f filename] [-q name] [keyseq:readline_func]" - -int -bind_builtin (list) - WORD_LIST *list; -{ - int return_code = EXECUTION_SUCCESS; - FILE *old_rl_outstream; - Keymap kmap, saved_keymap; - int lflag, dflag, fflag, vflag, qflag, mflag, opt; - char *initfile, *map_name, *fun_name; - - if (no_line_editing) - return (EXECUTION_FAILURE); - - kmap = saved_keymap = (Keymap) NULL; - lflag = dflag = vflag = fflag = qflag = mflag = 0; - initfile = map_name = fun_name = (char *)NULL; - - if (!bash_readline_initialized) - initialize_readline (); - - /* Cannot use unwind_protect_pointer () on "FILE *", it is only - guaranteed to work for strings. */ - /* XXX -- see if we can use unwind_protect here */ - old_rl_outstream = rl_outstream; - rl_outstream = stdout; - - reset_internal_getopt (); - while ((opt = internal_getopt (list, "lvdf:q:m:")) != EOF) - { - switch (opt) - { - case 'l': - lflag++; - break; - - case 'v': - vflag++; - break; - - case 'd': - dflag++; - break; - - case 'f': - fflag++; - initfile = list_optarg; - break; - - case 'm': - mflag++; - map_name = list_optarg; - break; - - case 'q': - qflag++; - fun_name = list_optarg; - break; - - default: - builtin_error (USAGE); - BIND_RETURN (EX_USAGE); - } - } - - list = loptend; - - /* First, see if we need to install a special keymap for this - command. Then start on the arguments. */ - - if (mflag && map_name) - { - kmap = rl_get_keymap_by_name (map_name); - if (!kmap) - { - builtin_error ("`%s': illegal keymap name", map_name); - BIND_RETURN (EXECUTION_FAILURE); - } - } - - if (kmap) - { - saved_keymap = rl_get_keymap (); - rl_set_keymap (kmap); - } - - /* XXX - we need to add exclusive use tests here. It doesn't make sense - to use some of these options together. */ - /* Now hack the option arguments */ - if (lflag) - rl_list_funmap_names (0); - - if (vflag) - rl_function_dumper (0); - - if (dflag) - rl_function_dumper (1); - - if (fflag && initfile) - { - if (rl_read_init_file (initfile) != 0) - { - builtin_error ("cannot read %s: %s\n", initfile, strerror (errno)); - BIND_RETURN (EXECUTION_FAILURE); - } - } - - if (qflag && fun_name) - return_code = query_bindings (fun_name); - - /* Process the rest of the arguments as binding specifications. */ - while (list) - { - rl_parse_and_bind (list->word->word); - list = list->next; - } - - if (saved_keymap) - rl_set_keymap (saved_keymap); - - bind_exit: - rl_outstream = old_rl_outstream; - return (return_code); -} - -static int -query_bindings (name) - char *name; -{ - Function *function; - char **keyseqs; - int j; - - function = rl_named_function (name); - if (!function) - { - builtin_error ("unknown function name `%s'", name); - return EXECUTION_FAILURE; - } - - keyseqs = rl_invoking_keyseqs (function); - - if (!keyseqs) - { - printf ("%s is not bound to any keys.\n", name); - return EXECUTION_FAILURE; - } - - printf ("%s can be invoked via ", name); - for (j = 0; j < 5 && keyseqs[j]; j++) - printf ("\"%s\"%s", keyseqs[j], keyseqs[j + 1] ? ", " : ".\n"); - if (keyseqs[j]) - printf ("...\n"); - free_array (keyseqs); - return EXECUTION_SUCCESS; -} -#endif /* READLINE */ +This file is bind.def, from which is created bind.c. +It implements the builtin "bind" in Bash. + +Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. + +This file is part of GNU Bash, the Bourne Again SHell. + +Bash is free software; you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation; either version 1, or (at your option) any later +version. + +Bash is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License along +with Bash; see the file COPYING. If not, write to the Free Software +Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + +$PRODUCES bind.c + +$BUILTIN bind +$DEPENDS_ON READLINE +$FUNCTION bind_builtin +$SHORT_DOC bind [-lvd] [-m keymap] [-f filename] [-q name] [keyseq:readline-function] +Bind a key sequence to a Readline function, or to a macro. The +syntax is equivalent to that found in ~/.inputrc, but must be +passed as a single argument: bind '"\C-x\C-r": re-read-init-file'. +Arguments we accept: + -m keymap Use `keymap' as the keymap for the duration of this + command. Acceptable keymap names are emacs, + emacs-standard, emacs-meta, emacs-ctlx, vi, vi-move, + vi-command, and vi-insert. + -l List names of functions. + -v List function names and bindings. + -d Dump functions and bindings such that they + can be read back in. + -f filename Read key bindings from FILENAME. + -q function-name Query about which keys invoke the named function. +$END + +#include <stdio.h> +#include "../shell.h" +#if defined (READLINE) +#include <errno.h> +#if !defined (errno) +extern int errno; +#endif /* !errno */ +#include <readline/readline.h> +#include <readline/history.h> +#include "bashgetopt.h" + +static int query_bindings (); + +extern int bash_readline_initialized; +extern int no_line_editing; + +#define BIND_RETURN(x) do { return_code = x; goto bind_exit; } while (0) + +#define USAGE "usage: bind [-lvd] [-m keymap] [-f filename] [-q name] [keyseq:readline_func]" + +int +bind_builtin (list) + WORD_LIST *list; +{ + int return_code = EXECUTION_SUCCESS; + FILE *old_rl_outstream; + Keymap kmap, saved_keymap; + int lflag, dflag, fflag, vflag, qflag, mflag, opt; + char *initfile, *map_name, *fun_name; + + if (no_line_editing) + return (EXECUTION_FAILURE); + + kmap = saved_keymap = (Keymap) NULL; + lflag = dflag = vflag = fflag = qflag = mflag = 0; + initfile = map_name = fun_name = (char *)NULL; + + if (!bash_readline_initialized) + initialize_readline (); + + /* Cannot use unwind_protect_pointer () on "FILE *", it is only + guaranteed to work for strings. */ + /* XXX -- see if we can use unwind_protect here */ + old_rl_outstream = rl_outstream; + rl_outstream = stdout; + + reset_internal_getopt (); + while ((opt = internal_getopt (list, "lvdf:q:m:")) != EOF) + { + switch (opt) + { + case 'l': + lflag++; + break; + + case 'v': + vflag++; + break; + + case 'd': + dflag++; + break; + + case 'f': + fflag++; + initfile = list_optarg; + break; + + case 'm': + mflag++; + map_name = list_optarg; + break; + + case 'q': + qflag++; + fun_name = list_optarg; + break; + + default: + builtin_error (USAGE); + BIND_RETURN (EX_USAGE); + } + } + + list = loptend; + + /* First, see if we need to install a special keymap for this + command. Then start on the arguments. */ + + if (mflag && map_name) + { + kmap = rl_get_keymap_by_name (map_name); + if (!kmap) + { + builtin_error ("`%s': illegal keymap name", map_name); + BIND_RETURN (EXECUTION_FAILURE); + } + } + + if (kmap) + { + saved_keymap = rl_get_keymap (); + rl_set_keymap (kmap); + } + + /* XXX - we need to add exclusive use tests here. It doesn't make sense + to use some of these options together. */ + /* Now hack the option arguments */ + if (lflag) + rl_list_funmap_names (0); + + if (vflag) + rl_function_dumper (0); + + if (dflag) + rl_function_dumper (1); + + if (fflag && initfile) + { + if (rl_read_init_file (initfile) != 0) + { + builtin_error ("cannot read %s: %s\n", initfile, strerror (errno)); + BIND_RETURN (EXECUTION_FAILURE); + } + } + + if (qflag && fun_name) + return_code = query_bindings (fun_name); + + /* Process the rest of the arguments as binding specifications. */ + while (list) + { + rl_parse_and_bind (list->word->word); + list = list->next; + } + + if (saved_keymap) + rl_set_keymap (saved_keymap); + + bind_exit: + rl_outstream = old_rl_outstream; + return (return_code); +} + +static int +query_bindings (name) + char *name; +{ + Function *function; + char **keyseqs; + int j; + + function = rl_named_function (name); + if (!function) + { + builtin_error ("unknown function name `%s'", name); + return EXECUTION_FAILURE; + } + + keyseqs = rl_invoking_keyseqs (function); + + if (!keyseqs) + { + printf ("%s is not bound to any keys.\n", name); + return EXECUTION_FAILURE; + } + + printf ("%s can be invoked via ", name); + for (j = 0; j < 5 && keyseqs[j]; j++) + printf ("\"%s\"%s", keyseqs[j], keyseqs[j + 1] ? ", " : ".\n"); + if (keyseqs[j]) + printf ("...\n"); + free_array (keyseqs); + return EXECUTION_SUCCESS; +} +#endif /* READLINE */ Index: break.def =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/break.def,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- break.def 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ break.def 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,110 +1,110 @@ -This file is break.def, from which is created break.c. -It implements the builtins "break" and "continue" in Bash. - -Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. - -This file is part of GNU Bash, the Bourne Again SHell. - -Bash is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 1, or (at your option) any later -version. - -Bash is distributed in the hope that it will be useful, but WITHOUT ANY -WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -for more details. - -You should have received a copy of the GNU General Public License along -with Bash; see the file COPYING. If not, write to the Free Software -Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. - -$PRODUCES break.c - -$BUILTIN break -$FUNCTION break_builtin -$SHORT_DOC break [n] -Exit from within a FOR, WHILE or UNTIL loop. If N is specified, -break N levels. -$END - -#include "../shell.h" - -extern char *this_command_name; - -static int check_loop_level (); - -/* The depth of while's and until's. */ -int loop_level = 0; - -/* Non-zero when a "break" instruction is encountered. */ -int breaking = 0; - -/* Non-zero when we have encountered a continue instruction. */ -int continuing = 0; - -/* Set up to break x levels, where x defaults to 1, but can be specified - as the first argument. */ -break_builtin (list) - WORD_LIST *list; -{ - int newbreak; - - if (!check_loop_level ()) - return (EXECUTION_FAILURE); - - newbreak = get_numeric_arg (list); - - if (newbreak <= 0) - return (EXECUTION_FAILURE); - - if (newbreak > loop_level) - newbreak = loop_level; - - breaking = newbreak; - - return (EXECUTION_SUCCESS); -} - -$BUILTIN continue -$FUNCTION continue_builtin -$SHORT_DOC continue [n] -Resume the next iteration of the enclosing FOR, WHILE or UNTIL loop. -If N is specified, resume at the N-th enclosing loop. -$END - -/* Set up to continue x levels, where x defaults to 1, but can be specified - as the first argument. */ -continue_builtin (list) - WORD_LIST *list; -{ - int newcont; - - if (!check_loop_level ()) - return (EXECUTION_FAILURE); - - newcont = get_numeric_arg (list); - - if (newcont <= 0) - return (EXECUTION_FAILURE); - - if (newcont > loop_level) - newcont = loop_level; - - continuing = newcont; - - return (EXECUTION_SUCCESS); -} - -/* Return non-zero if a break or continue command would be okay. - Print an error message if break or continue is meaningless here. */ -static int -check_loop_level () -{ -#if defined (BREAK_COMPLAINS) - if (!loop_level) - builtin_error ("Only meaningful in a `for', `while', or `until' loop"); -#endif /* BREAK_COMPLAINS */ - - return (loop_level); -} +This file is break.def, from which is created break.c. +It implements the builtins "break" and "continue" in Bash. + +Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. + +This file is part of GNU Bash, the Bourne Again SHell. + +Bash is free software; you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation; either version 1, or (at your option) any later +version. + +Bash is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License along +with Bash; see the file COPYING. If not, write to the Free Software +Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + +$PRODUCES break.c + +$BUILTIN break +$FUNCTION break_builtin +$SHORT_DOC break [n] +Exit from within a FOR, WHILE or UNTIL loop. If N is specified, +break N levels. +$END + +#include "../shell.h" + +extern char *this_command_name; + +static int check_loop_level (); + +/* The depth of while's and until's. */ +int loop_level = 0; + +/* Non-zero when a "break" instruction is encountered. */ +int breaking = 0; + +/* Non-zero when we have encountered a continue instruction. */ +int continuing = 0; + +/* Set up to break x levels, where x defaults to 1, but can be specified + as the first argument. */ +break_builtin (list) + WORD_LIST *list; +{ + int newbreak; + + if (!check_loop_level ()) + return (EXECUTION_FAILURE); + + newbreak = get_numeric_arg (list); + + if (newbreak <= 0) + return (EXECUTION_FAILURE); + + if (newbreak > loop_level) + newbreak = loop_level; + + breaking = newbreak; + + return (EXECUTION_SUCCESS); +} + +$BUILTIN continue +$FUNCTION continue_builtin +$SHORT_DOC continue [n] +Resume the next iteration of the enclosing FOR, WHILE or UNTIL loop. +If N is specified, resume at the N-th enclosing loop. +$END + +/* Set up to continue x levels, where x defaults to 1, but can be specified + as the first argument. */ +continue_builtin (list) + WORD_LIST *list; +{ + int newcont; + + if (!check_loop_level ()) + return (EXECUTION_FAILURE); + + newcont = get_numeric_arg (list); + + if (newcont <= 0) + return (EXECUTION_FAILURE); + + if (newcont > loop_level) + newcont = loop_level; + + continuing = newcont; + + return (EXECUTION_SUCCESS); +} + +/* Return non-zero if a break or continue command would be okay. + Print an error message if break or continue is meaningless here. */ +static int +check_loop_level () +{ +#if defined (BREAK_COMPLAINS) + if (!loop_level) + builtin_error ("Only meaningful in a `for', `while', or `until' loop"); +#endif /* BREAK_COMPLAINS */ + + return (loop_level); +} Index: builtin.def =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/builtin.def,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- builtin.def 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ builtin.def 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,67 +1,67 @@ -This file is builtin.def, from which is created builtin.c. -It implements the builtin "builtin" in Bash. - -Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. - -This file is part of GNU Bash, the Bourne Again SHell. - -Bash is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 1, or (at your option) any later -version. - -Bash is distributed in the hope that it will be useful, but WITHOUT ANY -WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -for more details. - -You should have received a copy of the GNU General Public License along -with Bash; see the file COPYING. If not, write to the Free Software -Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. - -$PRODUCES builtin.c - -$BUILTIN builtin -$FUNCTION builtin_builtin -$SHORT_DOC builtin [shell-builtin [arg ...]] -Run a shell builtin. This is useful when you wish to rename a -shell builtin to be a function, but need the functionality of the -builtin within the function itself. -$END - -#include "../shell.h" - -#include "common.h" - -extern char *this_command_name; - -/* Run the command mentioned in list directly, without going through the - normal alias/function/builtin/filename lookup process. */ -builtin_builtin (list) - WORD_LIST *list; -{ - Function *function; - register char *command; - - if (!list) - return (EXECUTION_SUCCESS); - - command = (list->word->word); -#if defined (DISABLED_BUILTINS) - function = builtin_address (command); -#else /* !DISABLED_BUILTINS */ - function = find_shell_builtin (command); -#endif /* !DISABLED_BUILTINS */ - - if (!function) - { - builtin_error ("%s: not a shell builtin", command); - return (EXECUTION_FAILURE); - } - else - { - this_command_name = command; - list = list->next; - return ((*function) (list)); - } -} +This file is builtin.def, from which is created builtin.c. +It implements the builtin "builtin" in Bash. + +Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. + +This file is part of GNU Bash, the Bourne Again SHell. + +Bash is free software; you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation; either version 1, or (at your option) any later +version. + +Bash is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License along +with Bash; see the file COPYING. If not, write to the Free Software +Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + +$PRODUCES builtin.c + +$BUILTIN builtin +$FUNCTION builtin_builtin +$SHORT_DOC builtin [shell-builtin [arg ...]] +Run a shell builtin. This is useful when you wish to rename a +shell builtin to be a function, but need the functionality of the +builtin within the function itself. +$END + +#include "../shell.h" + +#include "common.h" + +extern char *this_command_name; + +/* Run the command mentioned in list directly, without going through the + normal alias/function/builtin/filename lookup process. */ +builtin_builtin (list) + WORD_LIST *list; +{ + Function *function; + register char *command; + + if (!list) + return (EXECUTION_SUCCESS); + + command = (list->word->word); +#if defined (DISABLED_BUILTINS) + function = builtin_address (command); +#else /* !DISABLED_BUILTINS */ + function = find_shell_builtin (command); +#endif /* !DISABLED_BUILTINS */ + + if (!function) + { + builtin_error ("%s: not a shell builtin", command); + return (EXECUTION_FAILURE); + } + else + { + this_command_name = command; + list = list->next; + return ((*function) (list)); + } +} Index: cd.def =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/cd.def,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- cd.def 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ cd.def 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,693 +1,693 @@ -This file is cd.def, from which is created cd.c. It implements the -builtins "cd", "pwd", "pushd", "popd", and "dirs" in Bash. - -Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. - -This file is part of GNU Bash, the Bourne Again SHell. - -Bash is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 1, or (at your option) any later -version. [...1355 lines suppressed...] + { + if (chdir (newdir) < 0) + return (0); + else + return (1); + } +} + +/* Switch to the directory in NAME. This uses the cd_builtin to do the work, + so if the result is EXECUTION_FAILURE then an error message has already + been printed. */ +static int +cd_to_string (name) + char *name; +{ + WORD_LIST *tlist = make_word_list (make_word (name), NULL); + int result = (cd_builtin (tlist)); + dispose_words (tlist); + return (result); +} Index: colon.def =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/colon.def,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- colon.def 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ colon.def 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,37 +1,37 @@ -This file is colon.def, from which is created colon.c. -It implements the builtin ":" in Bash. - -Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. - -This file is part of GNU Bash, the Bourne Again SHell. - -Bash is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 1, or (at your option) any later -version. - -Bash is distributed in the hope that it will be useful, but WITHOUT ANY -WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -for more details. - -You should have received a copy of the GNU General Public License along -with Bash; see the file COPYING. If not, write to the Free Software -Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. - -$PRODUCES colon.c - -$BUILTIN : -$DOCNAME colon_builtin -$FUNCTION colon_builtin -$SHORT_DOC : -No effect; the command does nothing. A zero exit code is returned. -$END - -/* Do nothing. This command is a no-op. */ -int -colon_builtin (ignore) - char *ignore; -{ - return (0); -} +This file is colon.def, from which is created colon.c. +It implements the builtin ":" in Bash. + +Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. + +This file is part of GNU Bash, the Bourne Again SHell. + +Bash is free software; you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation; either version 1, or (at your option) any later +version. + +Bash is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License along +with Bash; see the file COPYING. If not, write to the Free Software +Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + +$PRODUCES colon.c + +$BUILTIN : +$DOCNAME colon_builtin +$FUNCTION colon_builtin +$SHORT_DOC : +No effect; the command does nothing. A zero exit code is returned. +$END + +/* Do nothing. This command is a no-op. */ +int +colon_builtin (ignore) + char *ignore; +{ + return (0); +} Index: command.def =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/command.def,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- command.def 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ command.def 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,176 +1,176 @@ -This file is command.def, from which is created command.c. -It implements the builtin "command" in Bash. - -Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. - -This file is part of GNU Bash, the Bourne Again SHell. - -Bash is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 1, or (at your option) any later -version. - -Bash is distributed in the hope that it will be useful, but WITHOUT ANY -WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -for more details. - -You should have received a copy of the GNU General Public License along -with Bash; see the file COPYING. If not, write to the Free Software -Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. - -$PRODUCES command.c - -$BUILTIN command -$FUNCTION command_builtin -$SHORT_DOC command [-pVv] [command [arg ...]] -Runs COMMAND with ARGS ignoring shell functions. If you have a shell -function called `ls', and you wish to call the command `ls', you can -say "command ls". If the -p option is given, a default value is used -for PATH that is guaranteed to find all of the standard utilities. If -the -V or -v option is given, a string is printed describing COMMAND. -The -V option produces a more verbose description. -$END - -#if defined (HAVE_STRING_H) -# include <string.h> -#else /* !HAVE_STRING_H */ -# include <strings.h> -#endif /* !HAVE_STRING_H */ - -#include "../shell.h" -#include "../nt_types.h" -#include "bashgetopt.h" - -static void restore_path (); -static char *get_standard_path (); - -/* Run the commands mentioned in LIST without paying attention to shell - functions. */ -int -command_builtin (list) - WORD_LIST *list; -{ - int result, verbose = 0, use_standard_path = 0, opt; - char *old_path; - - reset_internal_getopt (); - while ((opt = internal_getopt (list, "pvV")) != -1) - { - switch (opt) - { - case 'p': - use_standard_path = 1; - break; - case 'V': - verbose = 2; - break; - case 'v': - verbose = 4; - break; - - default: - report_bad_option (); - builtin_error ("usage: command [-pvV] [command [arg...]]"); - return (EX_USAGE); - } - } - list = loptend; - - if (!list) - return (EXECUTION_SUCCESS); - - if (verbose) - { - int found, any_found = 0; - - while (list) - { - - found = describe_command (list->word->word, verbose, 0); - - if (!found) - builtin_error ("%s: not found", list->word->word); - - any_found += found; - list = list->next; - } - return (any_found ? EXECUTION_SUCCESS : EXECUTION_FAILURE); - } - - begin_unwind_frame ("command_builtin"); - - /* We don't want this to be reparsed (consider command echo 'foo &'), so - just make a simple_command structure and call execute_command with it. */ - { - COMMAND *command; - - if (use_standard_path) - { - char *standard_path; - - old_path = get_string_value ("PATH"); - if (old_path) - old_path = savestring (old_path); - else - old_path = savestring (""); - add_unwind_protect ((Function *)restore_path, old_path); - - standard_path = get_standard_path (); - bind_variable ("PATH", standard_path); - free (standard_path); - } - command = make_bare_simple_command (); - command->value.Simple->words = (WORD_LIST *)copy_word_list (list); - command->value.Simple->redirects = (REDIRECT *)NULL; - command->flags |= (CMD_NO_FUNCTIONS | CMD_INHIBIT_EXPANSION); - command->value.Simple->flags |= (CMD_NO_FUNCTIONS | CMD_INHIBIT_EXPANSION); - /* If we're in a subshell, see if we can get away without forking - again, since we've already forked to run this builtin. */ - if (thr_me->subshell_environment) - { - command->flags |= CMD_NO_FORK; - command->value.Simple->flags |= CMD_NO_FORK; - } - add_unwind_protect ((char *)dispose_command, command); - result = execute_command (command); - } - - run_unwind_frame ("command_builtin"); - - return (result); -} - -/* Restore the value of the $PATH variable after replacing it when - executing `command -p'. */ -static void -restore_path (var) - char *var; -{ - bind_variable ("PATH", var); - free (var); -} - -/* Return a value for PATH that is guaranteed to find all of the standard - utilities. This uses Posix.2 configuration variables, if present. It - uses a value defined in config.h as a last resort. */ -static char * -get_standard_path () -{ -#if defined (_CS_PATH) && !defined (hpux_7) && !defined (NetBSD) - char *p; - size_t len; - - len = (size_t)confstr (_CS_PATH, (char *)NULL, (size_t)0); - p = xmalloc ((int)len + 2); - *p = '\0'; - confstr (_CS_PATH, p, len); - return (p); -#else /* !_CSPATH || hpux_7 || NetBSD */ -# if defined (CS_PATH) - return (savestring (CS_PATH)); -# else - return (savestring (STANDARD_UTILS_PATH)); -# endif /* !CS_PATH */ -#endif /* !_CS_PATH || hpux_7 */ -} +This file is command.def, from which is created command.c. +It implements the builtin "command" in Bash. + +Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. + +This file is part of GNU Bash, the Bourne Again SHell. + +Bash is free software; you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation; either version 1, or (at your option) any later +version. + +Bash is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License along +with Bash; see the file COPYING. If not, write to the Free Software +Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + +$PRODUCES command.c + +$BUILTIN command +$FUNCTION command_builtin +$SHORT_DOC command [-pVv] [command [arg ...]] +Runs COMMAND with ARGS ignoring shell functions. If you have a shell +function called `ls', and you wish to call the command `ls', you can +say "command ls". If the -p option is given, a default value is used +for PATH that is guaranteed to find all of the standard utilities. If +the -V or -v option is given, a string is printed describing COMMAND. +The -V option produces a more verbose description. +$END + +#if defined (HAVE_STRING_H) +# include <string.h> +#else /* !HAVE_STRING_H */ +# include <strings.h> +#endif /* !HAVE_STRING_H */ + +#include "../shell.h" +#include "../nt_types.h" +#include "bashgetopt.h" + +static void restore_path (); +static char *get_standard_path (); + +/* Run the commands mentioned in LIST without paying attention to shell + functions. */ +int +command_builtin (list) + WORD_LIST *list; +{ + int result, verbose = 0, use_standard_path = 0, opt; + char *old_path; + + reset_internal_getopt (); + while ((opt = internal_getopt (list, "pvV")) != -1) + { + switch (opt) + { + case 'p': + use_standard_path = 1; + break; + case 'V': + verbose = 2; + break; + case 'v': + verbose = 4; + break; + + default: + report_bad_option (); + builtin_error ("usage: command [-pvV] [command [arg...]]"); + return (EX_USAGE); + } + } + list = loptend; + + if (!list) + return (EXECUTION_SUCCESS); + + if (verbose) + { + int found, any_found = 0; + + while (list) + { + + found = describe_command (list->word->word, verbose, 0); + + if (!found) + builtin_error ("%s: not found", list->word->word); + + any_found += found; + list = list->next; + } + return (any_found ? EXECUTION_SUCCESS : EXECUTION_FAILURE); + } + + begin_unwind_frame ("command_builtin"); + + /* We don't want this to be reparsed (consider command echo 'foo &'), so + just make a simple_command structure and call execute_command with it. */ + { + COMMAND *command; + + if (use_standard_path) + { + char *standard_path; + + old_path = get_string_value ("PATH"); + if (old_path) + old_path = savestring (old_path); + else + old_path = savestring (""); + add_unwind_protect ((Function *)restore_path, old_path); + + standard_path = get_standard_path (); + bind_variable ("PATH", standard_path); + free (standard_path); + } + command = make_bare_simple_command (); + command->value.Simple->words = (WORD_LIST *)copy_word_list (list); + command->value.Simple->redirects = (REDIRECT *)NULL; + command->flags |= (CMD_NO_FUNCTIONS | CMD_INHIBIT_EXPANSION); + command->value.Simple->flags |= (CMD_NO_FUNCTIONS | CMD_INHIBIT_EXPANSION); + /* If we're in a subshell, see if we can get away without forking + again, since we've already forked to run this builtin. */ + if (thr_me->subshell_environment) + { + command->flags |= CMD_NO_FORK; + command->value.Simple->flags |= CMD_NO_FORK; + } + add_unwind_protect ((char *)dispose_command, command); + result = execute_command (command); + } + + run_unwind_frame ("command_builtin"); + + return (result); +} + +/* Restore the value of the $PATH variable after replacing it when + executing `command -p'. */ +static void +restore_path (var) + char *var; +{ + bind_variable ("PATH", var); + free (var); +} + +/* Return a value for PATH that is guaranteed to find all of the standard + utilities. This uses Posix.2 configuration variables, if present. It + uses a value defined in config.h as a last resort. */ +static char * +get_standard_path () +{ +#if defined (_CS_PATH) && !defined (hpux_7) && !defined (NetBSD) + char *p; + size_t len; + + len = (size_t)confstr (_CS_PATH, (char *)NULL, (size_t)0); + p = xmalloc ((int)len + 2); + *p = '\0'; + confstr (_CS_PATH, p, len); + return (p); +#else /* !_CSPATH || hpux_7 || NetBSD */ +# if defined (CS_PATH) + return (savestring (CS_PATH)); +# else + return (savestring (STANDARD_UTILS_PATH)); +# endif /* !CS_PATH */ +#endif /* !_CS_PATH || hpux_7 */ +} Index: common.c =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/common.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- common.c 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ common.c 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,835 +1,835 @@ -/* Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. - - This file is part of GNU Bash, the Bourne Again SHell. - - Bash is free software; you can redistribute it and/or modify it under - the terms of the GNU General Public License as published by the Free - Software Foundation; either version 1, or (at your option) any later - version. - - Bash is distributed in the hope that it will be useful, but WITHOUT ANY - WARRANTY; without even the implied warranty of MERCHANTABILITY or [...1639 lines suppressed...] + { + case '"': + case '$': + case '`': +#if defined (__NT_VC__) + case '\n': +#endif /* __NT_VC__ */ + case '\\': + result[j++] = '\\'; + default: + result[j++] = c; + break; + } + } + + result[j++] = '"'; + result[j] = '\0'; + + return (result); +} Index: common.h =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/common.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- common.h 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ common.h 9 Mar 2002 04:20:36 -0000 1.2 @@ -1,69 +1,69 @@ -/* common.h -- extern declarations for functions defined in common.c. */ - -/* Copyright (C) 1993 Free Software Foundation, Inc. - - This file is part of GNU Bash, the Bourne Again SHell. - - Bash is free software; you can redistribute it and/or modify it under - the terms of the GNU General Public License as published by the Free - Software Foundation; either version 2, or (at your option) any later - version. - - Bash is distributed in the hope that it will be useful, but WITHOUT ANY - WARRANTY; without even the implied warranty of MERCHANTABILITY or - FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - for more details. - - You should have received a copy of the GNU General Public License along - with Bash; see the file COPYING. If not, write to the Free Software - Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ - -#if !defined (__COMMON_H) -# define __COMMON_H - -#define ISOPTION(s, c) (s[0] == '-' && !s[2] && s[1] == c) - -extern void builtin_error (); -extern void bad_option (); - -extern int get_numeric_arg (); - -extern void remember_args (); - -extern void no_args (); - -extern int read_octal (); - -extern char *find_hashed_filename (); -extern void remove_hashed_filename (); -extern void remember_filename (); - -extern void push_context (), pop_context (); -extern void push_dollar_vars (), pop_dollar_vars (); -extern void dispose_saved_dollar_vars (); -extern int dollar_vars_changed (); -extern void set_dollar_vars_unchanged (), set_dollar_vars_changed (); - -/* Keeps track of the current working directory. */ -__declspec (thread) extern char *the_current_working_directory; -extern char *get_working_directory (); -extern void set_working_directory (); - -#if defined (JOB_CONTROL) -extern int get_job_spec (); -#endif - -extern int parse_and_execute (); -extern void parse_and_execute_cleanup (); - -extern void initialize_shell_builtins (); - -/* It's OK to declare a function as returning a Function * without - providing a definition of what a `Function' is. */ -extern Function *find_shell_builtin (); -extern Function *builtin_address (); - -extern char *single_quote (); -extern char *double_quote (); - -#endif /* !__COMMON_H */ +/* common.h -- extern declarations for functions defined in common.c. */ + +/* Copyright (C) 1993 Free Software Foundation, Inc. + + This file is part of GNU Bash, the Bourne Again SHell. + + Bash is free soft... [truncated message content] |
From: Enrico B. <enr...@us...> - 2002-03-09 04:17:17
|
Update of /cvsroot/winbash/winbash/builtins In directory usw-pr-cvs1:/tmp/cvs-serv29292/builtins Modified Files: Makefile Log Message: Fixed more cr/lf problems. Let's see if the wincvs client allows me to remove the lf this time.... Index: Makefile =================================================================== RCS file: /cvsroot/winbash/winbash/builtins/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- Makefile 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ Makefile 9 Mar 2002 04:17:14 -0000 1.2 @@ -1,259 +1,260 @@ -# -# This Makefile for building builtins.lib is in -*- text -*- for Emacs. -# - -CC=cl.exe -nologo -MAKE_LIB_COMMAND=lib.exe -nologo $^ -out:$@ -MKBUILTINS = mkbuiltins.exe -SHELL = /bin/sh -RM = rm -f -CP = cp - -CPPDEFS = -DWIN32 -D_WINDOWS -D__NT_VC__ -DHAVE_STRING_H -CPPFLAGS += -I. -CPPFLAGS += -I../lib -CPPFLAGS += -I../dum_inc -CPPFLAGS += -I../ -CPPFLAGS += $(CPPDEFS) -CFLAGS = -MT - -ifdef RELEASE -CFLAGS += -O2 -else -CFLAGS += -Od -Zi -Fdbuiltins.pdb -CPPFLAGS += -D_DEBUG -endif - -srcdir = . -VPATH = .:$(srcdir) - -.SUFFIXES: -.SUFFIXES: .def .c .obj -# How to make a .obj file from a .def file. -.def.obj: - $(RM) $@ - ./$(MKBUILTINS) $(DIRECTDEFINE) $< - $(CC) -c $(CPPFLAGS) $(CPPDEFS) $(CFLAGS) $*.c -# $(RM) $*.c - -# How to make a .c file from a .def file. -.def.c: - $(RM) $@ - ./$(MKBUILTINS) $(DIRECTDEFINE) $< - -.c.obj: - $(RM) $@ - $(CC) -c $(CPPFLAGS) $(CFLAGS) $< - -DEFS = $(srcdir)/alias.def $(srcdir)/bind.def $(srcdir)/break.def \ - $(srcdir)/builtin.def $(srcdir)/cd.def $(srcdir)/colon.def \ - $(srcdir)/command.def $(srcdir)/declare.def $(srcdir)/echo.def \ - $(srcdir)/enable.def $(srcdir)/eval.def $(srcdir)/getopts.def \ - $(srcdir)/exec.def $(srcdir)/exit.def $(srcdir)/fc.def \ - $(srcdir)/fg_bg.def $(srcdir)/hash.def $(srcdir)/help.def \ - $(srcdir)/history.def $(srcdir)/jobs.def $(srcdir)/kill.def \ - $(srcdir)/let.def $(srcdir)/read.def $(srcdir)/return.def \ - $(srcdir)/set.def $(srcdir)/setattr.def $(srcdir)/shift.def \ - $(srcdir)/source.def $(srcdir)/suspend.def $(srcdir)/test.def \ - $(srcdir)/times.def $(srcdir)/trap.def $(srcdir)/type.def \ - $(srcdir)/ulimit.def $(srcdir)/umask.def $(srcdir)/wait.def \ - $(srcdir)/inlib.def - -STATIC_SOURCE = common.c getopt.c bashgetopt.c getopt.h - -OFILES = builtins.obj getopt.obj bashgetopt.obj common.obj $(DEFS:%.def=%.obj) - -CREATED_FILES = builtext.h builtins.c $(MKBUILTINS) $(DEFS:%.def=%.c) - -all: builtins.lib - - -builtins.lib : $(OFILES) - $(MAKE_LIB_COMMAND) - -builtext.h builtins.c: $(MKBUILTINS) $(DEFS) - $(RM) builtext.h builtins.c - ./$(MKBUILTINS) -externfile builtext.h -structfile builtins.c \ - -noproduction $(DIRECTDEFINE) $(DEFS) - -$(MKBUILTINS): $(srcdir)/mkbuiltins.c ../config.h - $(CC) $(CPPFLAGS) $(CPPDEFS) $(CFLAGS) -o $(MKBUILTINS) $(srcdir)/mkbuiltins.c - -ulimit.obj: ulimit.def pipesize.h - - -documentation: builtins.texi - -$(OFILES): $(MKBUILTINS) ../config.h - -builtins.texi: $(MKBUILTINS) - ./$(MKBUILTINS) -documentonly $(DEFS) - -clean: - $(RM) $(OFILES) $(CREATED_FILES) mkbuiltins.obj mkbuiltins.pdb mkbuiltins.ilk builtins.lib builtins.pdb - -alias.obj: alias.def -bind.obj: bind.def -break.obj: break.def -builtin.obj: builtin.def -cd.obj: cd.def -colon.obj: colon.def -command.obj: command.def -declare.obj: declare.def -echo.obj: echo.def -enable.obj: enable.def -eval.obj: eval.def -exec.obj: exec.def -exit.obj: exit.def -fc.obj: fc.def -fg_bg.obj: fg_bg.def -hash.obj: hash.def -help.obj: help.def -history.obj: history.def -inlib.obj: inlib.def -jobs.obj: jobs.def -kill.obj: kill.def -let.obj: let.def -read.obj: read.def -return.obj: return.def -set.obj: set.def -setattr.obj: setattr.def -shift.obj: shift.def -source.obj: source.def -suspend.obj: suspend.def -test.obj: test.def -times.obj: times.def -trap.obj: trap.def -type.obj: type.def -umask.obj: umask.def -wait.obj: wait.def -getopts.obj: getopts.def -reserved.obj: reserved.def - -common.obj: ../shell.h ../command.h ../config.h ../memalloc.h ../general.h -common.obj: ../variables.h ../input.h hashcom.h ../bashhist.h -common.obj: ../quit.h ../unwind_prot.h ../maxpath.h ../jobs.h ../builtins.h -common.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -common.obj: ../execute_cmd.h ../error.h -alias.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -alias.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -alias.obj: ../shell.h ../unwind_prot.h ../variables.h common.h ../maxpath.h -bind.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -bind.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -bind.obj: ../maxpath.h -bind.obj: ../shell.h ../unwind_prot.h ../variables.h bashgetopt.h -break.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -break.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -break.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -builtin.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -builtin.obj: ../quit.h common.h ../maxpath.h -builtin.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -builtin.obj: ../shell.h ../unwind_prot.h ../variables.h -cd.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -cd.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -cd.obj: ../shell.h ../unwind_prot.h ../variables.h common.h ../maxpath.h -command.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -command.obj: ../quit.h bashgetopt.h ../maxpath.h -command.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -command.obj: ../shell.h ../unwind_prot.h ../variables.h -declare.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -declare.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -declare.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -echo.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -echo.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -echo.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -enable.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -enable.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -enable.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -eval.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -eval.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -eval.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -exec.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -exec.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -exec.obj: ../shell.h ../unwind_prot.h ../variables.h common.h ../execute_cmd.h -exec.obj: ../maxpath.h ../flags.h -exit.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -exit.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -exit.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -fc.obj: ../builtins.h ../command.h bashgetopt.h ../bashhist.h -fc.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -fc.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -fc.obj: ../flags.h ../unwind_prot.h ../variables.h ../shell.h ../maxpath.h -fg_bg.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -fg_bg.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -fg_bg.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -getopts.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -getopts.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -getopts.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -hash.obj: ../builtins.h ../command.h ../quit.h ../execute_cmd.h -hash.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -hash.obj: ../shell.h ../unwind_prot.h ../variables.h common.h ../maxpath.h -help.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -help.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -help.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -history.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -history.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -history.obj: ../filecntl.h ../shell.h ../unwind_prot.h ../variables.h -history.obj: ../bashhist.h ../maxpath.h -inlib.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -inlib.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -inlib.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -jobs.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -jobs.obj: ../quit.h bashgetopt.h ../maxpath.h -jobs.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -jobs.obj: ../shell.h ../unwind_prot.h ../variables.h -kill.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -kill.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -kill.obj: ../shell.h ../trap.h ../unwind_prot.h ../variables.h ../maxpath.h -let.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -let.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -let.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -read.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -read.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -read.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -return.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -return.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -return.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -set.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -set.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -set.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -setattr.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -setattr.obj: ../quit.h common.h bashgetopt.h ../maxpath.h -setattr.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -setattr.obj: ../shell.h ../unwind_prot.h ../variables.h -shift.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -shift.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -shift.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -source.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -source.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -source.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -suspend.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -suspend.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -suspend.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -test.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -test.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -test.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -times.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -times.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -times.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -trap.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -trap.obj: ../quit.h common.h ../maxpath.h -trap.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -trap.obj: ../shell.h ../unwind_prot.h ../variables.h ../execute_cmd.h -type.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -type.obj: ../quit.h common.h ../maxpath.h -type.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -type.obj: ../shell.h ../unwind_prot.h ../variables.h -ulimit.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -ulimit.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -ulimit.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -umask.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -umask.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -umask.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -wait.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h -wait.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h -wait.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h -bashgetopt.obj: ../bashansi.h ../ansi_stdlib.h -mkbuiltins.obj: ../bashansi.h ../ansi_stdlib.h -fc.obj: ../bashansi.h ../ansi_stdlib.h -bind.obj: ../lib/readline/chardefs.h ../lib/readline/readline.h ../lib/readline/keymaps.h +# +# This Makefile for building builtins.lib is in -*- text -*- for Emacs. +# +# + +CC=cl.exe -nologo +MAKE_LIB_COMMAND=lib.exe -nologo $^ -out:$@ +MKBUILTINS = mkbuiltins.exe +SHELL = /bin/sh +RM = rm -f +CP = cp + +CPPDEFS = -DWIN32 -D_WINDOWS -D__NT_VC__ -DHAVE_STRING_H +CPPFLAGS += -I. +CPPFLAGS += -I../lib +CPPFLAGS += -I../dum_inc +CPPFLAGS += -I../ +CPPFLAGS += $(CPPDEFS) +CFLAGS = -MT + +ifdef RELEASE +CFLAGS += -O2 +else +CFLAGS += -Od -Zi -Fdbuiltins.pdb +CPPFLAGS += -D_DEBUG +endif + +srcdir = . +VPATH = .:$(srcdir) + +.SUFFIXES: +.SUFFIXES: .def .c .obj +# How to make a .obj file from a .def file. +.def.obj: + $(RM) $@ + ./$(MKBUILTINS) $(DIRECTDEFINE) $< + $(CC) -c $(CPPFLAGS) $(CPPDEFS) $(CFLAGS) $*.c +# $(RM) $*.c + +# How to make a .c file from a .def file. +.def.c: + $(RM) $@ + ./$(MKBUILTINS) $(DIRECTDEFINE) $< + +.c.obj: + $(RM) $@ + $(CC) -c $(CPPFLAGS) $(CFLAGS) $< + +DEFS = $(srcdir)/alias.def $(srcdir)/bind.def $(srcdir)/break.def \ + $(srcdir)/builtin.def $(srcdir)/cd.def $(srcdir)/colon.def \ + $(srcdir)/command.def $(srcdir)/declare.def $(srcdir)/echo.def \ + $(srcdir)/enable.def $(srcdir)/eval.def $(srcdir)/getopts.def \ + $(srcdir)/exec.def $(srcdir)/exit.def $(srcdir)/fc.def \ + $(srcdir)/fg_bg.def $(srcdir)/hash.def $(srcdir)/help.def \ + $(srcdir)/history.def $(srcdir)/jobs.def $(srcdir)/kill.def \ + $(srcdir)/let.def $(srcdir)/read.def $(srcdir)/return.def \ + $(srcdir)/set.def $(srcdir)/setattr.def $(srcdir)/shift.def \ + $(srcdir)/source.def $(srcdir)/suspend.def $(srcdir)/test.def \ + $(srcdir)/times.def $(srcdir)/trap.def $(srcdir)/type.def \ + $(srcdir)/ulimit.def $(srcdir)/umask.def $(srcdir)/wait.def \ + $(srcdir)/inlib.def + +STATIC_SOURCE = common.c getopt.c bashgetopt.c getopt.h + +OFILES = builtins.obj getopt.obj bashgetopt.obj common.obj $(DEFS:%.def=%.obj) + +CREATED_FILES = builtext.h builtins.c $(MKBUILTINS) $(DEFS:%.def=%.c) + +all: builtins.lib + + +builtins.lib : $(OFILES) + $(MAKE_LIB_COMMAND) + +builtext.h builtins.c: $(MKBUILTINS) $(DEFS) + $(RM) builtext.h builtins.c + ./$(MKBUILTINS) -externfile builtext.h -structfile builtins.c \ + -noproduction $(DIRECTDEFINE) $(DEFS) + +$(MKBUILTINS): $(srcdir)/mkbuiltins.c ../config.h + $(CC) $(CPPFLAGS) $(CPPDEFS) $(CFLAGS) -o $(MKBUILTINS) $(srcdir)/mkbuiltins.c + +ulimit.obj: ulimit.def pipesize.h + + +documentation: builtins.texi + +$(OFILES): $(MKBUILTINS) ../config.h + +builtins.texi: $(MKBUILTINS) + ./$(MKBUILTINS) -documentonly $(DEFS) + +clean: + $(RM) $(OFILES) $(CREATED_FILES) mkbuiltins.obj mkbuiltins.pdb mkbuiltins.ilk builtins.lib builtins.pdb + +alias.obj: alias.def +bind.obj: bind.def +break.obj: break.def +builtin.obj: builtin.def +cd.obj: cd.def +colon.obj: colon.def +command.obj: command.def +declare.obj: declare.def +echo.obj: echo.def +enable.obj: enable.def +eval.obj: eval.def +exec.obj: exec.def +exit.obj: exit.def +fc.obj: fc.def +fg_bg.obj: fg_bg.def +hash.obj: hash.def +help.obj: help.def +history.obj: history.def +inlib.obj: inlib.def +jobs.obj: jobs.def +kill.obj: kill.def +let.obj: let.def +read.obj: read.def +return.obj: return.def +set.obj: set.def +setattr.obj: setattr.def +shift.obj: shift.def +source.obj: source.def +suspend.obj: suspend.def +test.obj: test.def +times.obj: times.def +trap.obj: trap.def +type.obj: type.def +umask.obj: umask.def +wait.obj: wait.def +getopts.obj: getopts.def +reserved.obj: reserved.def + +common.obj: ../shell.h ../command.h ../config.h ../memalloc.h ../general.h +common.obj: ../variables.h ../input.h hashcom.h ../bashhist.h +common.obj: ../quit.h ../unwind_prot.h ../maxpath.h ../jobs.h ../builtins.h +common.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +common.obj: ../execute_cmd.h ../error.h +alias.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +alias.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +alias.obj: ../shell.h ../unwind_prot.h ../variables.h common.h ../maxpath.h +bind.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +bind.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +bind.obj: ../maxpath.h +bind.obj: ../shell.h ../unwind_prot.h ../variables.h bashgetopt.h +break.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +break.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +break.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +builtin.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +builtin.obj: ../quit.h common.h ../maxpath.h +builtin.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +builtin.obj: ../shell.h ../unwind_prot.h ../variables.h +cd.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +cd.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +cd.obj: ../shell.h ../unwind_prot.h ../variables.h common.h ../maxpath.h +command.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +command.obj: ../quit.h bashgetopt.h ../maxpath.h +command.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +command.obj: ../shell.h ../unwind_prot.h ../variables.h +declare.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +declare.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +declare.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +echo.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +echo.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +echo.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +enable.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +enable.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +enable.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +eval.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +eval.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +eval.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +exec.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +exec.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +exec.obj: ../shell.h ../unwind_prot.h ../variables.h common.h ../execute_cmd.h +exec.obj: ../maxpath.h ../flags.h +exit.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +exit.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +exit.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +fc.obj: ../builtins.h ../command.h bashgetopt.h ../bashhist.h +fc.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +fc.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +fc.obj: ../flags.h ../unwind_prot.h ../variables.h ../shell.h ../maxpath.h +fg_bg.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +fg_bg.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +fg_bg.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +getopts.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +getopts.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +getopts.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +hash.obj: ../builtins.h ../command.h ../quit.h ../execute_cmd.h +hash.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +hash.obj: ../shell.h ../unwind_prot.h ../variables.h common.h ../maxpath.h +help.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +help.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +help.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +history.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +history.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +history.obj: ../filecntl.h ../shell.h ../unwind_prot.h ../variables.h +history.obj: ../bashhist.h ../maxpath.h +inlib.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +inlib.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +inlib.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +jobs.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +jobs.obj: ../quit.h bashgetopt.h ../maxpath.h +jobs.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +jobs.obj: ../shell.h ../unwind_prot.h ../variables.h +kill.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +kill.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +kill.obj: ../shell.h ../trap.h ../unwind_prot.h ../variables.h ../maxpath.h +let.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +let.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +let.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +read.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +read.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +read.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +return.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +return.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +return.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +set.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +set.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +set.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +setattr.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +setattr.obj: ../quit.h common.h bashgetopt.h ../maxpath.h +setattr.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +setattr.obj: ../shell.h ../unwind_prot.h ../variables.h +shift.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +shift.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +shift.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +source.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +source.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +source.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +suspend.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +suspend.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +suspend.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +test.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +test.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +test.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +times.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +times.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +times.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +trap.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +trap.obj: ../quit.h common.h ../maxpath.h +trap.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +trap.obj: ../shell.h ../unwind_prot.h ../variables.h ../execute_cmd.h +type.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +type.obj: ../quit.h common.h ../maxpath.h +type.obj: ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +type.obj: ../shell.h ../unwind_prot.h ../variables.h +ulimit.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +ulimit.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +ulimit.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +umask.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +umask.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +umask.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +wait.obj: ../command.h ../config.h ../memalloc.h ../error.h ../general.h +wait.obj: ../quit.h ../dispose_cmd.h ../make_cmd.h ../subst.h ../externs.h +wait.obj: ../shell.h ../unwind_prot.h ../variables.h ../maxpath.h +bashgetopt.obj: ../bashansi.h ../ansi_stdlib.h +mkbuiltins.obj: ../bashansi.h ../ansi_stdlib.h +fc.obj: ../bashansi.h ../ansi_stdlib.h +bind.obj: ../lib/readline/chardefs.h ../lib/readline/readline.h ../lib/readline/keymaps.h |
From: Enrico B. <enr...@us...> - 2002-03-09 04:17:17
|
Update of /cvsroot/winbash/winbash In directory usw-pr-cvs1:/tmp/cvs-serv29292 Modified Files: Makefile Log Message: Fixed more cr/lf problems. Let's see if the wincvs client allows me to remove the lf this time.... Index: Makefile =================================================================== RCS file: /cvsroot/winbash/winbash/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- Makefile 9 Mar 2002 03:49:40 -0000 1.2 +++ Makefile 9 Mar 2002 04:17:14 -0000 1.3 @@ -3,6 +3,7 @@ # # by default creates a debuggable version of bash.exe (sh.exe) # type 'make RELEASE=1' if you do not want debugging info in the exe +# HERE=$(shell pwd) DEFS = -nologo -DMAINTAINER="\"no...@wi...\"" |
From: Enrico B. <enr...@us...> - 2002-03-09 03:49:43
|
Update of /cvsroot/winbash/winbash In directory usw-pr-cvs1:/tmp/cvs-serv25229 Modified Files: Makefile Log Message: Fixed cr/lf problem.... Index: Makefile =================================================================== RCS file: /cvsroot/winbash/winbash/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- Makefile 9 Mar 2002 03:39:12 -0000 1.1.1.1 +++ Makefile 9 Mar 2002 03:49:40 -0000 1.2 @@ -1,342 +1,342 @@ -# -# This Makefile for building bash.exe is in -*- text -*- for Emacs. -# -# by default creates a debuggable version of bash.exe (sh.exe) -# type 'make RELEASE=1' if you do not want debugging info in the exe -HERE=$(shell pwd) - -DEFS = -nologo -DMAINTAINER="\"no...@wi...\"" -DEFS += -DHOSTTYPE="i386" -DOSTYPE="NT" -DWIN32 -D_CONSOLE -DEFS += -DProgram=bash -DINITIALIZE_SIGLIST -DHAVE_VFPRINTF -DHAVE_UNISTD_H -DEFS += -DHAVE_STDLIB_H -DHAVE_LIMITS_H -DHAVE_RESOURCE -DHAVE_SYS_PARAM -DEFS += -DHAVE_DIRENT_H -DVOID_SIGHANDLER -DBROKEN_SIGSUSPEND -DEFS += -DHAVE_GETHOSTNAME -DMKFIFO_MISSING -DNO_DEV_TTY_JOB_CONTROL -DEFS += -DNO_SBRK_DECL -DPGRP_PIPE -DTERMIOS_MISSING -DHAVE_DUP2 -DEFS += -DHAVE_STRERROR -DHAVE_DIRENT -DHAVE_STRING_H -DHAVE_VARARGS_H -DEFS += -DHAVE_STRCHR -DSHELL -DEFS += -DMSDOS -DHAVE_ALLOCA -DHAVE_ALLOCA_H -DEFS += -D__NT_VC__ -DCONIO -CPPFLAGS += -I. -CPPFLAGS += -I./lib -CPPFLAGS += -I./dum_inc -CPPFLAGS += $(DEFS) -CFLAGS = -MT -W2 - -LDFLAGS += -nologo -incremental:no -subsystem:console -machine:IX86 - - -ifdef RELEASE -CFLAGS += -O2 -else -CFLAGS += -Zi -Od -Fdbash.pdb -LDFLAGS += -debug -pdb:bash.pdb -CPPFLAGS += -D_DEBUG -endif - -VPATH := . -VPATH := $(VPATH):./dum_inc -VPATH := $(VPATH):./lib/readline -VPATH := $(VPATH):./lib/glob - -%.obj: %.c - $(RM) $@ - cl.exe -c $(CPPFLAGS) $(CFLAGS) /Fo$@ $< - -BUILTIN_SRCS = \ - builtins/mkbuiltins.c \ - builtins/common.c \ - builtins/getopt.c \ - builtins/bashgetopt.c \ - builtins/getopt.h \ - builtins/psize.c \ - builtins/alias.def \ - builtins/bind.def \ - builtins/break.def \ - builtins/builtin.def \ - builtins/cd.def \ - builtins/colon.def \ - builtins/command.def \ - builtins/declare.def \ - builtins/echo.def \ - builtins/enable.def \ - builtins/eval.def \ - builtins/getopts.def \ - builtins/exec.def \ - builtins/exit.def \ - builtins/fc.def \ - builtins/fg_bg.def \ - builtins/hash.def \ - builtins/help.def \ - builtins/history.def \ - builtins/jobs.def \ - builtins/kill.def \ - builtins/let.def \ - builtins/read.def \ - builtins/return.def \ - builtins/set.def \ - builtins/setattr.def \ - builtins/shift.def \ - builtins/source.def \ - builtins/suspend.def \ - builtins/test.def \ - builtins/times.def \ - builtins/trap.def \ - builtins/type.def \ - builtins/ulimit.def \ - builtins/umask.def \ - builtins/wait.def \ - builtins/reserved.def \ - builtins/inlib.def - -DUM-INC-SRCS = \ - dum_inc/bash_dum.c \ - dum_inc/bcopy.c \ - dum_inc/bzero.c \ - dum_inc/dirent.c \ - dum_inc/signal.c \ - dum_inc/unistd.c - - -LIB_GLOB_SRCS = \ - lib/glob/fnmatch.c \ - lib/glob/glob.c - -LIB_READLINE_SRCS = \ - lib/readline/bind.c \ - lib/readline/complete.c \ - lib/readline/display.c \ - lib/readline/funmap.c \ - lib/readline/history.c \ - lib/readline/isearch.c \ - lib/readline/keymaps.c \ - lib/readline/parens.c \ - lib/readline/readline.c \ - lib/readline/rltty.c \ - lib/readline/search.c \ - lib/readline/signals.c \ - lib/readline/tilde.c \ - lib/readline/vi_mode.c - -WINBASH_SRCS = \ - y.tab.c \ - alias.c \ - bashhist.c \ - bashline.c \ - bracecomp.c \ - braces.c \ - copy_cmd.c \ - dispose_cmd.c \ - error.c \ - execute_cmd.c \ - expr.c \ - flags.c \ - general.c \ - getcwd.c \ - hash.c \ - input.c \ - mailcheck.c \ - make_cmd.c \ - nojobs.c \ - nt_execute_cmd.c \ - nt_io.c \ - nt_jmp.c \ - nt_vc.c \ - print_cmd.c \ - shell.c \ - siglist.c \ - stringlib.c \ - subst.c \ - test.c \ - trap.c \ - unwind_prot.c \ - variables.c \ - version.c \ - w32err.c - -BASH-SRCS = \ - $(DUM-INC-SRCS) \ - $(LIB_READLINE_SRCS) \ - $(LIB_GLOB_SRCS) \ - $(WINBASH_SRCS) - -BASH-OBJS = $(BASH-SRCS:%.c=%.obj) - -LDLIBS += builtins/builtins.lib -LDLIBS += user32.lib -LDLIBS += Mpr.lib Winmm.lib -#-------------------------------------------------------------------------- -# Define all your symbols before here -#-------------------------------------------------------------------------- - -all : bash.exe sh.exe - -bash.exe : builtins/builtins.lib $(BASH-OBJS) - link.exe $(LDFLAGS) -out:$@ $^ $(LDLIBS) - -sh.exe : bash.exe - cp $^ $@ - -builtins/builtins.lib: $(BUILTIN_DEFS) - cd builtins ; $(MAKE) - -clean: - $(RM) $(BASH-OBJS) y.tab.c y.tab.h bash.exe sh.exe bash.pdb - cd builtins ; $(MAKE) clean - -y.tab.c: parse.y - cd bison && $(HERE)/bison/bison.exe -d -o ../$@ ../$< - -y.tab.h: y.tab.c - -alias.obj: alias.h ansi_stdlib.h bashansi.h command.h config.h \ - general.h hash.h memalloc.h stdc.h - -bashhist.obj: ansi_stdlib.h bashansi.h command.h config.h \ - dispose_cmd.h error.h externs.h filecntl.h flags.h general.h hash.h \ - make_cmd.h maxpath.h memalloc.h nt_types.h posixstat.h quit.h \ - shell.h stdc.h subst.h unwind_prot.h variables.h - -bashline.obj: alias.h ansi_stdlib.h bashansi.h bashhist.h \ - bashtypes.h builtins.h command.h config.h dispose_cmd.h error.h \ - execute_cmd.h externs.h general.h hash.h make_cmd.h maxpath.h \ - memalloc.h posixstat.h quit.h shell.h stdc.h subst.h unwind_prot.h \ - variables.h - -bracecomp.obj: command.h config.h dispose_cmd.h error.h \ - externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h \ - shell.h stdc.h subst.h unwind_prot.h variables.h - -braces.obj: command.h config.h dispose_cmd.h error.h externs.h \ - general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h shell.h \ - stdc.h subst.h unwind_prot.h variables.h - -copy_cmd.obj: command.h config.h dispose_cmd.h error.h \ - externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h \ - shell.h stdc.h subst.h unwind_prot.h variables.h - -dispose_cmd.obj: command.h config.h dispose_cmd.h error.h \ - externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h \ - shell.h stdc.h subst.h unwind_prot.h variables.h - -endian.obj: ansi_stdlib.h bashansi.h - -error.obj: ansi_stdlib.h bashansi.h command.h error.h flags.h \ - general.h hash.h nt_types.h stdc.h variables.h - -execute_cmd.obj: bashtypes.h command.h config.h dispose_cmd.h \ - error.h execute_cmd.h externs.h filecntl.h flags.h general.h hash.h \ - input.h jobs.h make_cmd.h maxpath.h memalloc.h nt_types.h posixstat.h \ - quit.h shell.h siglist.h stdc.h subst.h sysdefs.h unwind_prot.h \ - variables.h y.tab.h - -expr.obj: ansi_stdlib.h bashansi.h command.h config.h \ - dispose_cmd.h error.h externs.h general.h hash.h make_cmd.h maxpath.h \ - memalloc.h quit.h shell.h stdc.h subst.h unwind_prot.h variables.h - -flags.obj: command.h config.h dispose_cmd.h error.h externs.h \ - flags.h general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h \ - shell.h stdc.h subst.h unwind_prot.h variables.h - -general.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ - config.h dispose_cmd.h error.h externs.h filecntl.h general.h hash.h \ - make_cmd.h maxpath.h memalloc.h quit.h shell.h stdc.h subst.h \ - unwind_prot.h variables.h - -getcwd.obj: ansi_stdlib.h bashtypes.h config.h maxpath.h \ - memalloc.h posixstat.h - -hash.obj: ansi_stdlib.h command.h config.h dispose_cmd.h \ - error.h externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h \ - quit.h shell.h stdc.h subst.h unwind_prot.h variables.h - -input.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ - config.h filecntl.h general.h hash.h input.h memalloc.h nt_types.h \ - posixstat.h stdc.h variables.h - -jobs.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ - config.h dispose_cmd.h error.h externs.h filecntl.h general.h hash.h \ - input.h jobs.h make_cmd.h maxpath.h memalloc.h quit.h shell.h \ - siglist.h stdc.h subst.h trap.h unwind_prot.h variables.h - -mailcheck.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ - config.h dispose_cmd.h error.h execute_cmd.h externs.h general.h \ - hash.h make_cmd.h maxpath.h memalloc.h posixstat.h quit.h shell.h \ - stdc.h subst.h unwind_prot.h variables.h - -make_cmd.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ - config.h error.h externs.h filecntl.h flags.h general.h input.h \ - jobs.h make_cmd.h memalloc.h quit.h siglist.h stdc.h subst.h - -nojobs.obj: bashtypes.h command.h config.h dispose_cmd.h \ - error.h execute_cmd.h externs.h filecntl.h general.h hash.h input.h \ - jobs.h make_cmd.h maxpath.h memalloc.h nt_types.h quit.h shell.h \ - siglist.h stdc.h subst.h unwind_prot.h variables.h - -nt_execute_cmd.obj: bashtypes.h command.h config.h \ - dispose_cmd.h error.h execute_cmd.h externs.h filecntl.h flags.h \ - general.h hash.h input.h jobs.h make_cmd.h maxpath.h memalloc.h \ - nt_types.h posixstat.h quit.h shell.h siglist.h stdc.h subst.h \ - sysdefs.h unwind_prot.h variables.h w32err.h y.tab.h - -nt_io.obj: command.h general.h hash.h nt_types.h stdc.h \ - variables.h - -nt_jmp.obj: config.h memalloc.h nt_jmp.h unwind_prot.h - -nt_vc.obj: command.h config.h general.h hash.h memalloc.h \ - nt_types.h stdc.h variables.h - -print_cmd.obj: command.h config.h dispose_cmd.h error.h \ - externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h \ - nt_types.h quit.h shell.h stdc.h subst.h unwind_prot.h variables.h \ - y.tab.h - -shell.obj: ansi_stdlib.h bashansi.h bashhist.h bashtypes.h \ - command.h config.h dispose_cmd.h error.h execute_cmd.h externs.h \ - filecntl.h flags.h general.h hash.h input.h jobs.h make_cmd.h \ - maxpath.h memalloc.h nt_types.h posixstat.h quit.h shell.h siglist.h \ - stdc.h subst.h unwind_prot.h variables.h - -siglist.obj: siglist.h stdc.h trap.h - -signames.obj: ansi_stdlib.h - -subst.obj: ansi_stdlib.h bashansi.h bashhist.h bashtypes.h \ - command.h config.h dispose_cmd.h error.h execute_cmd.h externs.h \ - filecntl.h flags.h general.h hash.h jobs.h make_cmd.h maxpath.h \ - memalloc.h nt_types.h posixstat.h quit.h shell.h siglist.h stdc.h \ - subst.h unwind_prot.h variables.h - -test.obj: bashtypes.h command.h config.h dispose_cmd.h error.h \ - externs.h filecntl.h general.h hash.h make_cmd.h maxpath.h \ - memalloc.h nt_types.h posixstat.h quit.h shell.h stdc.h subst.h \ - unwind_prot.h variables.h - -trap.obj: bashtypes.h command.h config.h dispose_cmd.h error.h \ - externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h nt_types.h \ - quit.h shell.h signames.h stdc.h subst.h trap.h unwind_prot.h \ - variables.h - -unwind_prot.obj: bashtypes.h command.h config.h general.h \ - memalloc.h quit.h stdc.h unwind_prot.h - -variables.obj: ansi_stdlib.h bashansi.h bashhist.h bashtypes.h \ - command.h config.h dispose_cmd.h error.h execute_cmd.h externs.h \ - flags.h general.h hash.h make_cmd.h maxpath.h memalloc.h nt_types.h \ - posixstat.h quit.h shell.h stdc.h subst.h unwind_prot.h variables.h - -version.obj: version.h - -w32err.obj: w32err.h - -y.tab.obj: alias.h ansi_stdlib.h bashansi.h bashhist.h \ - bashtypes.h command.h config.h dispose_cmd.h error.h externs.h \ - flags.h general.h hash.h input.h jobs.h make_cmd.h maxpath.h \ - memalloc.h quit.h shell.h siglist.h stdc.h subst.h unwind_prot.h \ - variables.h - -y.tab.obj: alias.h ansi_stdlib.h bashansi.h bashhist.h \ - bashtypes.h command.h config.h dispose_cmd.h error.h externs.h \ - flags.h general.h hash.h input.h jobs.h make_cmd.h maxpath.h \ - memalloc.h nt_types.h quit.h shell.h siglist.h stdc.h subst.h \ - unwind_prot.h variables.h +# +# This Makefile for building bash.exe is in -*- text -*- for Emacs. +# +# by default creates a debuggable version of bash.exe (sh.exe) +# type 'make RELEASE=1' if you do not want debugging info in the exe +HERE=$(shell pwd) + +DEFS = -nologo -DMAINTAINER="\"no...@wi...\"" +DEFS += -DHOSTTYPE="i386" -DOSTYPE="NT" -DWIN32 -D_CONSOLE +DEFS += -DProgram=bash -DINITIALIZE_SIGLIST -DHAVE_VFPRINTF -DHAVE_UNISTD_H +DEFS += -DHAVE_STDLIB_H -DHAVE_LIMITS_H -DHAVE_RESOURCE -DHAVE_SYS_PARAM +DEFS += -DHAVE_DIRENT_H -DVOID_SIGHANDLER -DBROKEN_SIGSUSPEND +DEFS += -DHAVE_GETHOSTNAME -DMKFIFO_MISSING -DNO_DEV_TTY_JOB_CONTROL +DEFS += -DNO_SBRK_DECL -DPGRP_PIPE -DTERMIOS_MISSING -DHAVE_DUP2 +DEFS += -DHAVE_STRERROR -DHAVE_DIRENT -DHAVE_STRING_H -DHAVE_VARARGS_H +DEFS += -DHAVE_STRCHR -DSHELL +DEFS += -DMSDOS -DHAVE_ALLOCA -DHAVE_ALLOCA_H +DEFS += -D__NT_VC__ -DCONIO +CPPFLAGS += -I. +CPPFLAGS += -I./lib +CPPFLAGS += -I./dum_inc +CPPFLAGS += $(DEFS) +CFLAGS = -MT -W2 + +LDFLAGS += -nologo -incremental:no -subsystem:console -machine:IX86 + + +ifdef RELEASE +CFLAGS += -O2 +else +CFLAGS += -Zi -Od -Fdbash.pdb +LDFLAGS += -debug -pdb:bash.pdb +CPPFLAGS += -D_DEBUG +endif + +VPATH := . +VPATH := $(VPATH):./dum_inc +VPATH := $(VPATH):./lib/readline +VPATH := $(VPATH):./lib/glob + +%.obj: %.c + $(RM) $@ + cl.exe -c $(CPPFLAGS) $(CFLAGS) /Fo$@ $< + +BUILTIN_SRCS = \ + builtins/mkbuiltins.c \ + builtins/common.c \ + builtins/getopt.c \ + builtins/bashgetopt.c \ + builtins/getopt.h \ + builtins/psize.c \ + builtins/alias.def \ + builtins/bind.def \ + builtins/break.def \ + builtins/builtin.def \ + builtins/cd.def \ + builtins/colon.def \ + builtins/command.def \ + builtins/declare.def \ + builtins/echo.def \ + builtins/enable.def \ + builtins/eval.def \ + builtins/getopts.def \ + builtins/exec.def \ + builtins/exit.def \ + builtins/fc.def \ + builtins/fg_bg.def \ + builtins/hash.def \ + builtins/help.def \ + builtins/history.def \ + builtins/jobs.def \ + builtins/kill.def \ + builtins/let.def \ + builtins/read.def \ + builtins/return.def \ + builtins/set.def \ + builtins/setattr.def \ + builtins/shift.def \ + builtins/source.def \ + builtins/suspend.def \ + builtins/test.def \ + builtins/times.def \ + builtins/trap.def \ + builtins/type.def \ + builtins/ulimit.def \ + builtins/umask.def \ + builtins/wait.def \ + builtins/reserved.def \ + builtins/inlib.def + +DUM-INC-SRCS = \ + dum_inc/bash_dum.c \ + dum_inc/bcopy.c \ + dum_inc/bzero.c \ + dum_inc/dirent.c \ + dum_inc/signal.c \ + dum_inc/unistd.c + + +LIB_GLOB_SRCS = \ + lib/glob/fnmatch.c \ + lib/glob/glob.c + +LIB_READLINE_SRCS = \ + lib/readline/bind.c \ + lib/readline/complete.c \ + lib/readline/display.c \ + lib/readline/funmap.c \ + lib/readline/history.c \ + lib/readline/isearch.c \ + lib/readline/keymaps.c \ + lib/readline/parens.c \ + lib/readline/readline.c \ + lib/readline/rltty.c \ + lib/readline/search.c \ + lib/readline/signals.c \ + lib/readline/tilde.c \ + lib/readline/vi_mode.c + +WINBASH_SRCS = \ + y.tab.c \ + alias.c \ + bashhist.c \ + bashline.c \ + bracecomp.c \ + braces.c \ + copy_cmd.c \ + dispose_cmd.c \ + error.c \ + execute_cmd.c \ + expr.c \ + flags.c \ + general.c \ + getcwd.c \ + hash.c \ + input.c \ + mailcheck.c \ + make_cmd.c \ + nojobs.c \ + nt_execute_cmd.c \ + nt_io.c \ + nt_jmp.c \ + nt_vc.c \ + print_cmd.c \ + shell.c \ + siglist.c \ + stringlib.c \ + subst.c \ + test.c \ + trap.c \ + unwind_prot.c \ + variables.c \ + version.c \ + w32err.c + +BASH-SRCS = \ + $(DUM-INC-SRCS) \ + $(LIB_READLINE_SRCS) \ + $(LIB_GLOB_SRCS) \ + $(WINBASH_SRCS) + +BASH-OBJS = $(BASH-SRCS:%.c=%.obj) + +LDLIBS += builtins/builtins.lib +LDLIBS += user32.lib +LDLIBS += Mpr.lib Winmm.lib +#-------------------------------------------------------------------------- +# Define all your symbols before here +#-------------------------------------------------------------------------- + +all : bash.exe sh.exe + +bash.exe : builtins/builtins.lib $(BASH-OBJS) + link.exe $(LDFLAGS) -out:$@ $^ $(LDLIBS) + +sh.exe : bash.exe + cp $^ $@ + +builtins/builtins.lib: $(BUILTIN_DEFS) + cd builtins ; $(MAKE) + +clean: + $(RM) $(BASH-OBJS) y.tab.c y.tab.h bash.exe sh.exe bash.pdb + cd builtins ; $(MAKE) clean + +y.tab.c: parse.y + cd bison && $(HERE)/bison/bison.exe -d -o ../$@ ../$< + +y.tab.h: y.tab.c + +alias.obj: alias.h ansi_stdlib.h bashansi.h command.h config.h \ + general.h hash.h memalloc.h stdc.h + +bashhist.obj: ansi_stdlib.h bashansi.h command.h config.h \ + dispose_cmd.h error.h externs.h filecntl.h flags.h general.h hash.h \ + make_cmd.h maxpath.h memalloc.h nt_types.h posixstat.h quit.h \ + shell.h stdc.h subst.h unwind_prot.h variables.h + +bashline.obj: alias.h ansi_stdlib.h bashansi.h bashhist.h \ + bashtypes.h builtins.h command.h config.h dispose_cmd.h error.h \ + execute_cmd.h externs.h general.h hash.h make_cmd.h maxpath.h \ + memalloc.h posixstat.h quit.h shell.h stdc.h subst.h unwind_prot.h \ + variables.h + +bracecomp.obj: command.h config.h dispose_cmd.h error.h \ + externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h \ + shell.h stdc.h subst.h unwind_prot.h variables.h + +braces.obj: command.h config.h dispose_cmd.h error.h externs.h \ + general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h shell.h \ + stdc.h subst.h unwind_prot.h variables.h + +copy_cmd.obj: command.h config.h dispose_cmd.h error.h \ + externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h \ + shell.h stdc.h subst.h unwind_prot.h variables.h + +dispose_cmd.obj: command.h config.h dispose_cmd.h error.h \ + externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h \ + shell.h stdc.h subst.h unwind_prot.h variables.h + +endian.obj: ansi_stdlib.h bashansi.h + +error.obj: ansi_stdlib.h bashansi.h command.h error.h flags.h \ + general.h hash.h nt_types.h stdc.h variables.h + +execute_cmd.obj: bashtypes.h command.h config.h dispose_cmd.h \ + error.h execute_cmd.h externs.h filecntl.h flags.h general.h hash.h \ + input.h jobs.h make_cmd.h maxpath.h memalloc.h nt_types.h posixstat.h \ + quit.h shell.h siglist.h stdc.h subst.h sysdefs.h unwind_prot.h \ + variables.h y.tab.h + +expr.obj: ansi_stdlib.h bashansi.h command.h config.h \ + dispose_cmd.h error.h externs.h general.h hash.h make_cmd.h maxpath.h \ + memalloc.h quit.h shell.h stdc.h subst.h unwind_prot.h variables.h + +flags.obj: command.h config.h dispose_cmd.h error.h externs.h \ + flags.h general.h hash.h make_cmd.h maxpath.h memalloc.h quit.h \ + shell.h stdc.h subst.h unwind_prot.h variables.h + +general.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ + config.h dispose_cmd.h error.h externs.h filecntl.h general.h hash.h \ + make_cmd.h maxpath.h memalloc.h quit.h shell.h stdc.h subst.h \ + unwind_prot.h variables.h + +getcwd.obj: ansi_stdlib.h bashtypes.h config.h maxpath.h \ + memalloc.h posixstat.h + +hash.obj: ansi_stdlib.h command.h config.h dispose_cmd.h \ + error.h externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h \ + quit.h shell.h stdc.h subst.h unwind_prot.h variables.h + +input.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ + config.h filecntl.h general.h hash.h input.h memalloc.h nt_types.h \ + posixstat.h stdc.h variables.h + +jobs.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ + config.h dispose_cmd.h error.h externs.h filecntl.h general.h hash.h \ + input.h jobs.h make_cmd.h maxpath.h memalloc.h quit.h shell.h \ + siglist.h stdc.h subst.h trap.h unwind_prot.h variables.h + +mailcheck.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ + config.h dispose_cmd.h error.h execute_cmd.h externs.h general.h \ + hash.h make_cmd.h maxpath.h memalloc.h posixstat.h quit.h shell.h \ + stdc.h subst.h unwind_prot.h variables.h + +make_cmd.obj: ansi_stdlib.h bashansi.h bashtypes.h command.h \ + config.h error.h externs.h filecntl.h flags.h general.h input.h \ + jobs.h make_cmd.h memalloc.h quit.h siglist.h stdc.h subst.h + +nojobs.obj: bashtypes.h command.h config.h dispose_cmd.h \ + error.h execute_cmd.h externs.h filecntl.h general.h hash.h input.h \ + jobs.h make_cmd.h maxpath.h memalloc.h nt_types.h quit.h shell.h \ + siglist.h stdc.h subst.h unwind_prot.h variables.h + +nt_execute_cmd.obj: bashtypes.h command.h config.h \ + dispose_cmd.h error.h execute_cmd.h externs.h filecntl.h flags.h \ + general.h hash.h input.h jobs.h make_cmd.h maxpath.h memalloc.h \ + nt_types.h posixstat.h quit.h shell.h siglist.h stdc.h subst.h \ + sysdefs.h unwind_prot.h variables.h w32err.h y.tab.h + +nt_io.obj: command.h general.h hash.h nt_types.h stdc.h \ + variables.h + +nt_jmp.obj: config.h memalloc.h nt_jmp.h unwind_prot.h + +nt_vc.obj: command.h config.h general.h hash.h memalloc.h \ + nt_types.h stdc.h variables.h + +print_cmd.obj: command.h config.h dispose_cmd.h error.h \ + externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h \ + nt_types.h quit.h shell.h stdc.h subst.h unwind_prot.h variables.h \ + y.tab.h + +shell.obj: ansi_stdlib.h bashansi.h bashhist.h bashtypes.h \ + command.h config.h dispose_cmd.h error.h execute_cmd.h externs.h \ + filecntl.h flags.h general.h hash.h input.h jobs.h make_cmd.h \ + maxpath.h memalloc.h nt_types.h posixstat.h quit.h shell.h siglist.h \ + stdc.h subst.h unwind_prot.h variables.h + +siglist.obj: siglist.h stdc.h trap.h + +signames.obj: ansi_stdlib.h + +subst.obj: ansi_stdlib.h bashansi.h bashhist.h bashtypes.h \ + command.h config.h dispose_cmd.h error.h execute_cmd.h externs.h \ + filecntl.h flags.h general.h hash.h jobs.h make_cmd.h maxpath.h \ + memalloc.h nt_types.h posixstat.h quit.h shell.h siglist.h stdc.h \ + subst.h unwind_prot.h variables.h + +test.obj: bashtypes.h command.h config.h dispose_cmd.h error.h \ + externs.h filecntl.h general.h hash.h make_cmd.h maxpath.h \ + memalloc.h nt_types.h posixstat.h quit.h shell.h stdc.h subst.h \ + unwind_prot.h variables.h + +trap.obj: bashtypes.h command.h config.h dispose_cmd.h error.h \ + externs.h general.h hash.h make_cmd.h maxpath.h memalloc.h nt_types.h \ + quit.h shell.h signames.h stdc.h subst.h trap.h unwind_prot.h \ + variables.h + +unwind_prot.obj: bashtypes.h command.h config.h general.h \ + memalloc.h quit.h stdc.h unwind_prot.h + +variables.obj: ansi_stdlib.h bashansi.h bashhist.h bashtypes.h \ + command.h config.h dispose_cmd.h error.h execute_cmd.h externs.h \ + flags.h general.h hash.h make_cmd.h maxpath.h memalloc.h nt_types.h \ + posixstat.h quit.h shell.h stdc.h subst.h unwind_prot.h variables.h + +version.obj: version.h + +w32err.obj: w32err.h + +y.tab.obj: alias.h ansi_stdlib.h bashansi.h bashhist.h \ + bashtypes.h command.h config.h dispose_cmd.h error.h externs.h \ + flags.h general.h hash.h input.h jobs.h make_cmd.h maxpath.h \ + memalloc.h quit.h shell.h siglist.h stdc.h subst.h unwind_prot.h \ + variables.h + +y.tab.obj: alias.h ansi_stdlib.h bashansi.h bashhist.h \ + bashtypes.h command.h config.h dispose_cmd.h error.h externs.h \ + flags.h general.h hash.h input.h jobs.h make_cmd.h maxpath.h \ + memalloc.h nt_types.h quit.h shell.h siglist.h stdc.h subst.h \ + unwind_prot.h variables.h |
From: Enrico B. <enr...@us...> - 2002-03-09 03:40:52
|
Update of /cvsroot/winbash/winbash/bison In directory usw-pr-cvs1:/tmp/cvs-serv22724 Added Files: bison.exe Log Message: Initial checkin. --- NEW FILE: bison.exe --- MZ $ ¡B è¡i ÿ ÄB èh ÿ ÄB è;g ¡B èX\ é,þÿÿ¡4¢B Mü¿IhìB b ÿÿÿ}ø ÿÿÿ}ø{ _^[ÉÃUììSVWE+PìB ¡LìB ;XíB ;XíB ;XíB Eü xêB I ¡B èÂä I ¡B èxã I ¡B ègâ I ¡B èá I ¡B èà ¡B èúÞ I ¡B è1Ü I ¡B èÛ = ¡B èMÚ I ¡B èûÖ I ¡B èrÐ I ¡B èUÅ I ¡B èSÄ I ¡B èû I ¡B è¼Á Z ¡B èQ¬ ¡B è¬ ¡B èrª ¡B è© ¡B èk¨ ¡B è(§ © ÿÿÄ¡ìêB ÿÿÄ¡XìB ÿÿÄé }ìs © r © Eÿ è·W Àt&:au% ätÁè:Au Àt:auÁ äuÒÀ3ÀÃÀÑà@ÃÀ÷ Àtà÷ ÀtÊ:auÉ ätÁÁëÌÌÌÌÌÌÌÌÌÌÌÌL$÷Á @ èÃD °A ½Àýÿÿ ÜùÿÿPEPèoD éÍÿÿÿE°PÿC éÈÿÿÿéeÿÿÿÇEø A j : ÿEøé ÿEøé% ÿEøé) ÿÿÄEìé SQ» èÝB % Àtªâø2ÀóªÂ^_ÉÃÌÌÌÌÌÌÌÌÌÌÌÌUìì( ØüÿÿPèZÿÿÄØüÿÿPEPè6ùÿÿÄ¡xßB éÈÿÿÿEôÁàEüé ûÿÿĸÿÿÿÿé Òt@ëó3ÀÃÌÌÌÌÌÌÌÌUììSVW¡8îB ÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌ [--debug] [--defines] [--fixed-output-files] [--no-lines] [--verbose] [--version] [--help] [--yacc] [--file-prefix=prefix] [--name-prefix=prefix] [--output=outfile] grammar-file #include "%s" extern int yyerror; extern int yycost; extern char * yymsg; extern YYSTYPE yyval; yyguard(n, yyvsp, yylsp) register int n; register YYSTYPE *yyvsp; register YYLTYPE *yylsp; { yyerror = 0; yycost = 0; yymsg = 0; switch (n) { #include "%s" extern YYSTYPE yyval; extern int yychar;yyaction(n, yyvsp, yylsp) register int n; register YYSTYPE *yyvsp; register YYLTYPE *yylsp; { switch (n) { switch (yyn) { } } } } } #define YYDEBUG %d #endif #ifndef __STDC__ #define const #endif #endif #define YYTRANSLATE(x) ((unsigned)(x) <= %d ? yytranslate[x] : %d) static const char yytranslate[] = { 0 static const short yytranslate[] = { 0 }; #define YYTRANSLATE(x) (x) #if YYDEBUG != 0 static const short yyprhs[] = { 0 }; static const short yyrhs[] = {%6d }; #endif static const short yystos[] = { 0 }; #if YYDEBUG != 0 static const short yyrline[] = { 0 }; static const char * const yytname[] = { "%s" }; #endif static const short yyr1[] = { 0 }; static const short yyr2[] = { 0 }; #define YYFINAL %d static const short yydefact[] = {%6d }; static const short yydefgoto[] = {%6d }; static const short yypact[] = {%6d }; static const short yypgoto[] = {%6d }; #define YYLAST %d static const short yytable[] = {%6d }; static const short yycheck[] = {%6d }; state %d Grammar Terminals, with rules where they appear Nonterminals, with rules where they appear /* A Bison parser, made from %s #ifndef YYLTYPE typedef struct yyltype { int timestamp; int first_line; int first_column; int last_line; int last_column; char *text; } yyltype; #define YYLTYPE yyltype #endif #ifndef YYLTYPE typedef struct yyltype { int timestamp; int first_line; int first_column; int last_line; int last_column; char *text; } yyltype; #define YYLTYPE yyltype #endif #line %d "%s" case %d: break;} case %d: break;} #define YYSTYPE int #endif #define YYSTYPE int #endif extern YYSTYPE %slval; extern YYSTYPE yylval; Terminals which are not used: Useless rules: --------- ----- ----------------- Program: %s%s%s%s%s%s%s%s%s%s%s (Press Retry to debug the application) Module: File: Line: For information on how your program can cause an assertion failure, see the Visual C++ documentation on asserts. - not enough space for lowio initialization - not enough space for stdio initialization - pure virtual function call - not enough space for _onexit/atexit table - unable to open console device - unexpected heap error - unexpected multithread lock error - not enough space for thread data abnormal program termination - not enough space for environment - not enough space for arguments - floating point not loaded Program: failure, see the Visual C++ documentation on asserts >!>g>>Í>Ü>ñ>O?_?s?ª?»? 77,797G7z77ª7Î7ð78S8z88Ô8C9v9ò9d::À:º<Ì<Ù<÷<=X=j=t=y===¦=¸=>>_>e>t>z>>>©>²> 77%747@7O7[7j7v777 7±7¿7Ç7Ö7è7ô7W8f8r8w888¤8¬8»8Í8Ù8<9K9W9f9r9999¨9w:}::§:±:»:Æ:Ë:þ:;';-;E;T;c;r;; ;;;;£;;Ý;ä;è;ì;ð;ô;ø;ü; =9=t==Í=í=ö=>I>U>b>>>>µ>Å>Ï>á>î>ü>??? ?2???H?R?r?~???ª?·?Å?Õ?ß? >$>,>;>E>Q>t>~>>>>ª>¶>Ü>â>ç>õ>þ>?'?5?=?L?V?b?|????©?Ì?Ö?Û?î?ó? ??^?f?u???±?Ï?ì? 999)9;9G9999¡9³9¿9Ú9ß9::/:E:K:Q:V:m::¸:Ê:Û:ã:ò:;;O;T;p;u;;¨;®;´;¹;Ø;ê;ò;<<<1<W<|<<<§<¶<È<Ô<î<===$=1=9=L=U=a======¢=¦=ª=®=²=¶=º=R>Z>i>{>>¥>ª>á>é>ø> ??F?g?z?? ?? ?¦?¬?±?¿?Ç?Ö?à?ì? 77+777Y7a7i7x777Ñ7Ú7ã7ë7ú7883888o8t88£8©8¯8´8Ë8ñ89(999A9P9b9n99²9Î9Ó9ì9::::6:H:P:_:q:}::µ:Ú:ì:ý:;;&;2;H;\;a;p;~;;;¦;¯;»;å;ì;ð;ô;ø;ü; ==(=0=?=Q=]=s=x=== =¥=³=Ë=Ø=P>j>x>>>«>±>·>÷>?+?L??£?Á?Ü?â? 666/656E6}66¿6Ñ6ñ67 7/7;7P7d7v77®7¿7Ó7ü788+898B8G8U8f8o8888©8²8¸8Ä8Ó8à8ì8ò8÷8 999*9:9L9h9q9v99¿9×9ï9:C:t:}::«:´:; ;%;8;=;P;U;h;m;; ;;«;Ë;Û;<G<^<<§<»<Í<÷<¨=Î= 222¥2Ú2å2U3¢3ß3ä34 41464Z4_444Ä4È4Ì4Ð4Ô4à4U5d5k55Â5ù536W6¦6×67/7K7\7Ê7ê7ý8j9u9¤9©9Í9::²:½:ÿ:;·;!<&<W<»<û<-=S=£=Ã=Þ=>x>¨>>?A?|?©?û? ???%?j???Ò?ÿ? 0000"0(0.040:0@0F0L0R0o0}01181A12272D2Z2y22²2ß2é23P3¨3¸3¾3Ä3 |
From: Enrico B. <enr...@us...> - 2002-03-09 03:39:17
|
Update of /cvsroot/winbash/winbash In directory usw-pr-cvs1:/tmp/cvs-serv22306 Log Message: Initial checkin. Status: Vendor Tag: motive Release Tags: v-1-14-2 N winbash/.build N winbash/.distribution N winbash/.machine N winbash/.patchlevel N winbash/alias.c N winbash/alias.h N winbash/ansi_stdlib.h N winbash/bashansi.h N winbash/bashhist.c N winbash/bashhist.h N winbash/bashline.c N winbash/bashtypes.h N winbash/bracecomp.c N winbash/braces.c N winbash/builtins.h N winbash/command.h N winbash/config.h N winbash/config.h.mini N winbash/configure N winbash/COPYING N winbash/copy_cmd.c N winbash/cpp-Makefile N winbash/debug.reg N winbash/dispose_cmd.c N winbash/dispose_cmd.h N winbash/endian.c N winbash/error.c N winbash/error.h N winbash/execute_cmd.c N winbash/execute_cmd.h N winbash/expr.c N winbash/externs.h N winbash/filecntl.h N winbash/flags.c N winbash/flags.h N winbash/general.c N winbash/general.h N winbash/getcwd.c N winbash/hash.c N winbash/hash.h N winbash/input.c N winbash/input.h N winbash/INSTALL N winbash/jobs.c N winbash/jobs.h N winbash/machines.h N winbash/mailcheck.c N winbash/Makefile N winbash/make_cmd.c N winbash/make_cmd.h N winbash/MANIFEST N winbash/maxpath.h N winbash/memalloc.h N winbash/NEWS N winbash/newversion.c N winbash/nojobs.c N winbash/nt_execute_cmd.c N winbash/nt_io.c N winbash/nt_jmp.c N winbash/nt_jmp.h N winbash/nt_types.h N winbash/nt_vc.c N winbash/parse.y N winbash/parser.h N winbash/posixstat.h N winbash/print_cmd.c N winbash/quit.h N winbash/README N winbash/RELEASE N winbash/shell.c N winbash/shell.h N winbash/siglist.c N winbash/siglist.h N winbash/signames.c N winbash/signames.h N winbash/stdc.h N winbash/stringlib.c N winbash/subst.c N winbash/subst.h N winbash/sysdefs.h N winbash/test.c N winbash/trap.c N winbash/trap.h N winbash/unwind_prot.c N winbash/unwind_prot.h N winbash/variables.c N winbash/variables.h N winbash/version.c N winbash/version.h N winbash/vprint.c N winbash/w32err.c N winbash/w32err.h N winbash/builtins/alias.def N winbash/builtins/bashgetopt.c N winbash/builtins/bashgetopt.h N winbash/builtins/bind.def N winbash/builtins/break.def N winbash/builtins/builtin.def N winbash/builtins/cd.def N winbash/builtins/colon.def N winbash/builtins/command.def N winbash/builtins/common.c N winbash/builtins/common.h N winbash/builtins/declare.def N winbash/builtins/echo.def N winbash/builtins/enable.def N winbash/builtins/eval.def N winbash/builtins/exec.def N winbash/builtins/exit.def N winbash/builtins/fc.def N winbash/builtins/fg_bg.def N winbash/builtins/getopt.c N winbash/builtins/getopt.h N winbash/builtins/getopts.def N winbash/builtins/hash.def N winbash/builtins/hashcom.h N winbash/builtins/help.def N winbash/builtins/history.def N winbash/builtins/inlib.def N winbash/builtins/jobs.def N winbash/builtins/kill.def N winbash/builtins/let.def N winbash/builtins/Makefile N winbash/builtins/mkbuiltins.c N winbash/builtins/pipesize.h N winbash/builtins/psize.c N winbash/builtins/psize.sh N winbash/builtins/read.def N winbash/builtins/reserved.def N winbash/builtins/return.def N winbash/builtins/send_files N winbash/builtins/set.def N winbash/builtins/setattr.def N winbash/builtins/shift.def N winbash/builtins/source.def N winbash/builtins/suspend.def N winbash/builtins/test.def N winbash/builtins/times.def N winbash/builtins/trap.def N winbash/builtins/type.def N winbash/builtins/ulimit.def N winbash/builtins/umask.def N winbash/builtins/wait.def N winbash/CWRU/README N winbash/documentation/article.ms N winbash/documentation/article.ps N winbash/documentation/article.txt N winbash/documentation/bash.1 N winbash/documentation/bash.ps N winbash/documentation/bash.txt N winbash/documentation/builtins.1 N winbash/documentation/builtins.ps N winbash/documentation/builtins.txt N winbash/documentation/features.dvi N winbash/documentation/features.info N winbash/documentation/features.ps N winbash/documentation/features.texi N winbash/documentation/Makefile N winbash/documentation/readline.3 N winbash/documentation/readline.ps N winbash/documentation/readline.txt N winbash/documentation/README N winbash/documentation/texinfo.tex N winbash/documentation/html/bash.1.html N winbash/documentation/html/bashbug.1.html N winbash/documentation/html/bashref_1.html N winbash/documentation/html/bashref_10.html N winbash/documentation/html/bashref_100.html N winbash/documentation/html/bashref_101.html N winbash/documentation/html/bashref_102.html N winbash/documentation/html/bashref_103.html N winbash/documentation/html/bashref_104.html N winbash/documentation/html/bashref_105.html N winbash/documentation/html/bashref_106.html N winbash/documentation/html/bashref_107.html N winbash/documentation/html/bashref_108.html N winbash/documentation/html/bashref_109.html N winbash/documentation/html/bashref_11.html N winbash/documentation/html/bashref_110.html N winbash/documentation/html/bashref_111.html N winbash/documentation/html/bashref_112.html N winbash/documentation/html/bashref_113.html N winbash/documentation/html/bashref_114.html N winbash/documentation/html/bashref_12.html N winbash/documentation/html/bashref_13.html N winbash/documentation/html/bashref_14.html N winbash/documentation/html/bashref_15.html N winbash/documentation/html/bashref_16.html N winbash/documentation/html/bashref_17.html N winbash/documentation/html/bashref_18.html N winbash/documentation/html/bashref_19.html N winbash/documentation/html/bashref_2.html N winbash/documentation/html/bashref_20.html N winbash/documentation/html/bashref_21.html N winbash/documentation/html/bashref_22.html N winbash/documentation/html/bashref_23.html N winbash/documentation/html/bashref_24.html N winbash/documentation/html/bashref_25.html N winbash/documentation/html/bashref_26.html N winbash/documentation/html/bashref_27.html N winbash/documentation/html/bashref_28.html N winbash/documentation/html/bashref_29.html N winbash/documentation/html/bashref_3.html N winbash/documentation/html/bashref_30.html N winbash/documentation/html/bashref_31.html N winbash/documentation/html/bashref_32.html N winbash/documentation/html/bashref_33.html N winbash/documentation/html/bashref_34.html N winbash/documentation/html/bashref_35.html N winbash/documentation/html/bashref_36.html N winbash/documentation/html/bashref_37.html N winbash/documentation/html/bashref_38.html N winbash/documentation/html/bashref_39.html N winbash/documentation/html/bashref_4.html N winbash/documentation/html/bashref_40.html N winbash/documentation/html/bashref_41.html N winbash/documentation/html/bashref_42.html N winbash/documentation/html/bashref_43.html N winbash/documentation/html/bashref_44.html N winbash/documentation/html/bashref_45.html N winbash/documentation/html/bashref_46.html N winbash/documentation/html/bashref_47.html N winbash/documentation/html/bashref_48.html N winbash/documentation/html/bashref_49.html N winbash/documentation/html/bashref_5.html N winbash/documentation/html/bashref_50.html N winbash/documentation/html/bashref_51.html N winbash/documentation/html/bashref_52.html N winbash/documentation/html/bashref_53.html N winbash/documentation/html/bashref_54.html N winbash/documentation/html/bashref_55.html N winbash/documentation/html/bashref_56.html N winbash/documentation/html/bashref_57.html N winbash/documentation/html/bashref_58.html N winbash/documentation/html/bashref_59.html N winbash/documentation/html/bashref_6.html N winbash/documentation/html/bashref_60.html N winbash/documentation/html/bashref_61.html N winbash/documentation/html/bashref_62.html N winbash/documentation/html/bashref_63.html N winbash/documentation/html/bashref_64.html N winbash/documentation/html/bashref_65.html N winbash/documentation/html/bashref_66.html N winbash/documentation/html/bashref_67.html N winbash/documentation/html/bashref_68.html N winbash/documentation/html/bashref_69.html N winbash/documentation/html/bashref_7.html N winbash/documentation/html/bashref_70.html N winbash/documentation/html/bashref_71.html N winbash/documentation/html/bashref_72.html N winbash/documentation/html/bashref_73.html N winbash/documentation/html/bashref_74.html N winbash/documentation/html/bashref_75.html N winbash/documentation/html/bashref_76.html N winbash/documentation/html/bashref_77.html N winbash/documentation/html/bashref_78.html N winbash/documentation/html/bashref_79.html N winbash/documentation/html/bashref_8.html N winbash/documentation/html/bashref_80.html N winbash/documentation/html/bashref_81.html N winbash/documentation/html/bashref_82.html N winbash/documentation/html/bashref_83.html N winbash/documentation/html/bashref_84.html N winbash/documentation/html/bashref_85.html N winbash/documentation/html/bashref_86.html N winbash/documentation/html/bashref_87.html N winbash/documentation/html/bashref_88.html N winbash/documentation/html/bashref_89.html N winbash/documentation/html/bashref_9.html N winbash/documentation/html/bashref_90.html N winbash/documentation/html/bashref_91.html N winbash/documentation/html/bashref_92.html N winbash/documentation/html/bashref_93.html N winbash/documentation/html/bashref_94.html N winbash/documentation/html/bashref_95.html N winbash/documentation/html/bashref_96.html N winbash/documentation/html/bashref_97.html N winbash/documentation/html/bashref_98.html N winbash/documentation/html/bashref_99.html N winbash/documentation/html/bashref_toc.html N winbash/documentation/html/builtins.1.html N winbash/documentation/html/index.html N winbash/documentation/html/readline.3.html N winbash/documentation/html/termcap_1.html N winbash/documentation/html/termcap_10.html N winbash/documentation/html/termcap_11.html N winbash/documentation/html/termcap_12.html N winbash/documentation/html/termcap_13.html N winbash/documentation/html/termcap_14.html N winbash/documentation/html/termcap_15.html N winbash/documentation/html/termcap_16.html N winbash/documentation/html/termcap_17.html N winbash/documentation/html/termcap_18.html N winbash/documentation/html/termcap_19.html N winbash/documentation/html/termcap_2.html N winbash/documentation/html/termcap_20.html N winbash/documentation/html/termcap_21.html N winbash/documentation/html/termcap_22.html N winbash/documentation/html/termcap_23.html N winbash/documentation/html/termcap_24.html N winbash/documentation/html/termcap_25.html N winbash/documentation/html/termcap_26.html N winbash/documentation/html/termcap_27.html N winbash/documentation/html/termcap_28.html N winbash/documentation/html/termcap_29.html N winbash/documentation/html/termcap_3.html N winbash/documentation/html/termcap_30.html N winbash/documentation/html/termcap_31.html N winbash/documentation/html/termcap_32.html N winbash/documentation/html/termcap_33.html N winbash/documentation/html/termcap_34.html N winbash/documentation/html/termcap_35.html N winbash/documentation/html/termcap_36.html N winbash/documentation/html/termcap_37.html N winbash/documentation/html/termcap_38.html N winbash/documentation/html/termcap_39.html N winbash/documentation/html/termcap_4.html N winbash/documentation/html/termcap_40.html N winbash/documentation/html/termcap_41.html N winbash/documentation/html/termcap_42.html N winbash/documentation/html/termcap_43.html N winbash/documentation/html/termcap_44.html N winbash/documentation/html/termcap_45.html N winbash/documentation/html/termcap_46.html N winbash/documentation/html/termcap_47.html N winbash/documentation/html/termcap_5.html N winbash/documentation/html/termcap_6.html N winbash/documentation/html/termcap_7.html N winbash/documentation/html/termcap_8.html N winbash/documentation/html/termcap_9.html N winbash/documentation/html/termcap_toc.html N winbash/dum_inc/alloca.h N winbash/dum_inc/bash_dum.c N winbash/dum_inc/bash_endian.h N winbash/dum_inc/bcopy.c N winbash/dum_inc/bzero.c N winbash/dum_inc/dir.h N winbash/dum_inc/dirent.c N winbash/dum_inc/dirent.h N winbash/dum_inc/dtypes.h N winbash/dum_inc/fab.h N winbash/dum_inc/grp.h N winbash/dum_inc/nam.h N winbash/dum_inc/ndir.h N winbash/dum_inc/pwd.h N winbash/dum_inc/rmsdef.h N winbash/dum_inc/sgtty.h N winbash/dum_inc/signal.c N winbash/dum_inc/strings.h N winbash/dum_inc/system.h N winbash/dum_inc/termcap.h N winbash/dum_inc/termio.h N winbash/dum_inc/termios.h N winbash/dum_inc/unistd.c N winbash/dum_inc/unistd.h N winbash/dum_inc/sys/dir.h N winbash/dum_inc/sys/file.h N winbash/dum_inc/sys/ioctl.h N winbash/dum_inc/sys/ndir.h N winbash/dum_inc/sys/param.h N winbash/dum_inc/sys/pc.h N winbash/dum_inc/sys/pte.h N winbash/dum_inc/sys/ptem.h N winbash/dum_inc/sys/resource.h N winbash/dum_inc/sys/socket.h N winbash/dum_inc/sys/stream.h N winbash/dum_inc/sys/time.h N winbash/dum_inc/sys/times.h N winbash/dum_inc/sys/ttold.h N winbash/dum_inc/sys/utsname.h N winbash/dum_inc/sys/wait.h N winbash/examples/alias-conv.sh N winbash/examples/suncmd.termcap N winbash/lib/glob/ChangeLog N winbash/lib/glob/fnmatch.c N winbash/lib/glob/fnmatch.h N winbash/lib/glob/glob.c N winbash/lib/glob/Makefile N winbash/lib/glob/ndir.h N winbash/lib/readline/ansi_stdlib.h N winbash/lib/readline/bind.c N winbash/lib/readline/ChangeLog N winbash/lib/readline/chardefs.h N winbash/lib/readline/complete.c N winbash/lib/readline/COPYING N winbash/lib/readline/display.c N winbash/lib/readline/emacs_keymap.c N winbash/lib/readline/funmap.c N winbash/lib/readline/history.c N winbash/lib/readline/history.h N winbash/lib/readline/isearch.c N winbash/lib/readline/keymaps.c N winbash/lib/readline/keymaps.h N winbash/lib/readline/Makefile N winbash/lib/readline/memalloc.h N winbash/lib/readline/parens.c N winbash/lib/readline/posixstat.h N winbash/lib/readline/readline.c N winbash/lib/readline/readline.h N winbash/lib/readline/README N winbash/lib/readline/rlconf.h N winbash/lib/readline/rldefs.h N winbash/lib/readline/rltty.c N winbash/lib/readline/search.c N winbash/lib/readline/signals.c N winbash/lib/readline/STANDALONE N winbash/lib/readline/tilde.c N winbash/lib/readline/tilde.h N winbash/lib/readline/vi_keymap.c N winbash/lib/readline/vi_mode.c N winbash/lib/readline/xmalloc.c N winbash/lib/tilde/ChangeLog N winbash/lib/tilde/Makefile N winbash/lib/tilde/memalloc.h N winbash/lib/tilde/tilde.c N winbash/lib/tilde/tilde.h N winbash/portbash/libc.sh N winbash/portbash/mkdesc.sh N winbash/portbash/pgrp.c N winbash/portbash/README N winbash/portbash/signals.sh N winbash/portbash/stdio.sh N winbash/portbash/strings.sh N winbash/portbash/syscalls.sh N winbash/support/bash.xbm N winbash/support/bashbug.sh N winbash/support/cat-s N winbash/support/clone-bash N winbash/support/cppmagic N winbash/support/FAQ N winbash/support/fixlinks N winbash/support/getcppsyms.c N winbash/support/inpath N winbash/support/install.sh N winbash/support/mkdirs N winbash/support/mklinks N winbash/support/mkmachtype N winbash/support/mksysdefs N winbash/support/PORTING N winbash/support/printenv N winbash/support/recho.c N winbash/support/srcdir N winbash/support/SYMLINKS N winbash/tests/dollar-at.sh N winbash/tests/dollar-star.sh N winbash/tests/dollar.right N winbash/tests/exp-tests N winbash/tests/exp.right N winbash/tests/getopts.sh N winbash/tests/glob-test N winbash/tests/glob.right N winbash/tests/ifs-test-1.sh N winbash/tests/ifs-test-2.sh N winbash/tests/ifs-test-3.sh N winbash/tests/ifs.1.right N winbash/tests/ifs.2.right N winbash/tests/ifs.3.right N winbash/tests/input-line.sh N winbash/tests/input-line.sub N winbash/tests/input.right N winbash/tests/minus-e N winbash/tests/minus-e.right N winbash/tests/new-exp.right N winbash/tests/new-exp.tests N winbash/tests/prec.right N winbash/tests/precedence N winbash/tests/README N winbash/tests/run-all N winbash/tests/run-dollars N winbash/tests/run-exp-tests N winbash/tests/run-glob-test N winbash/tests/run-ifs-tests N winbash/tests/run-input-test N winbash/tests/run-minus-e N winbash/tests/run-new-exp N winbash/tests/run-precedence N winbash/tests/run-set-e-test N winbash/tests/run-strip N winbash/tests/run-varenv N winbash/tests/set-e-test N winbash/tests/set-e.right N winbash/tests/strip.right N winbash/tests/strip.tests N winbash/tests/tilde-tests N winbash/tests/tilde.right N winbash/tests/varenv.right N winbash/tests/varenv.sh N winbash/tests/x N winbash/tests/xx N winbash/bison/bison.hairy N winbash/bison/bison.simple No conflicts created by this import ***** Bogus filespec: - Imported sources |
From: kevin s. <xk...@us...> - 2002-03-06 22:37:33
|
Update of /cvsroot/winbash/bash-1.14.2/builtins In directory usw-pr-cvs1:/tmp/cvs-serv5345/builtins Modified Files: reserved.def Log Message: removed duplicate definition of select command docs - must have gotten messed up in the reverse patching process Index: reserved.def =================================================================== RCS file: /cvsroot/winbash/bash-1.14.2/builtins/reserved.def,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** reserved.def 6 Mar 2002 03:26:12 -0000 1.1.1.1 --- reserved.def 6 Mar 2002 22:37:30 -0000 1.2 *************** *** 44,62 **** $END - $BUILTIN select - $SHORT_DOC select NAME [in WORDS ... ;] do COMMANDS; done - The WORDS are expanded, generating a list of words. The - set of expanded words is printed on the standard error, each - preceded by a number. If `in WORDS' is not present, `in "$@"' - is assumed. The PS3 prompt is then displayed and a line read - from the standard input. If the line consists of the number - corresponding to one of the displayed words, then NAME is set - to that word. If the line is empty, WORDS and the prompt are - redisplayed. If EOF is read, the command completes. Any other - value read causes NAME to be set to null. The line read is saved - in the variable REPLY. COMMANDS are executed after each selection - until a break or return command is executed. - $END - $BUILTIN case $SHORT_DOC case WORD in [PATTERN [| PATTERN]...) COMMANDS ;;]... esac --- 44,47 ---- |