Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com From: "linda w \(cyg\)" To: Subject: FW: >/dev/stderr broken in /bin/sh?, makewhatis unhappy, & apropos confused, or just me? Date: Mon, 10 Mar 2003 01:34:29 -0800 Message-ID: <002301c2e6e8$3fda0890$1403a8c0@sc.tlinx.org> X-Priority: 3 (Normal) X-MSMail-Priority: Normal Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 > -----Original Message----- > From: Igor Pechtchanski [mailto:pechtcha AT cs DOT nyu DOT edu] > A couple of points to note: > 1) In Cygwin, /bin/sh != bash. /bin/sh == ash, and it doesn't support > bash'isms like /dev/stderr. Use >&2 and >&1 in /bin/sh. ----- "Bash"ism? From Oreillynet: Some UNIX systems, and utilities such as gawk, support special filenames like /dev/stdin, /dev/stdout, and /dev/stderr. You can use these just as you'd use other files. I just happened to look and it is on my SuSE system as well -- I didn't know bash had special handling for it till just now...learn something new every day! Oh, you'll like this one: "Learn Linux in 15 minutes a week!": http://www.2000trainers.com/article.aspx?articleID=144&page=2 Says /dev/std{in|err|out} are standard on linux systems. Maybe Cygwin should be renamed "CyNUX": "Cygwin is Not Unix or Linux"? :-) I guess the author of 'makewhatis' didn't know this either. Perhaps it's on enough systems. > 2) While it's acceptable to have a space in your home directory name or > the value of $TMP/$TEMP, some scripts cannot handle it (because they're > missing proper quoting). My guess is that 'makewhatis' is one such... ---- "Acceptable"? Gee...thanks. Considering Windows comes that way ... > Don't know about the apropos bit... > Igor --- So I take it that it doesn't give bogus output on your system... it's probably some file munged on my system somewhere...I'm alwayws messing something up ... always using things in ways they were never "intended" to be used... Thanks for the heads up on bash....a simple fix for makewhatis for it's use of /dev/stdX might be to make the first line #!/bin/bash instead of #!/bin/sh. Linda > > On Sun, 9 Mar 2003, linda w (cyg) wrote: > > > I normally use bash and this works in bash: > > > > echo "hello stderr" >/dev/stderr > > echo "hello stdout" >/dev/stdout > > > > But in /bin/sh: > > > > $ echo hello stderr >/dev/stderr > > cannot create /dev/stderr: directory nonexistent > > $ echo hello stdout >/dev/stdout > > cannot create /dev/stdout: directory nonexistent > > $ > > > > --- > > I'm guessing this isn't supposed to work this way? > > > > "makewhatis -v" doesn't like seem to like it: > > law> makewhatis -v > > /usr/sbin/makewhatis: cannot create /dev/stderr: directory > nonexistent > > > > I invoked the -v when a simple "makewhatis" yielded > > "cd: can't cd to /cygdrive/c/Documents" > > > > Apropos is a little confused about one of it's lines. > > Does anyone else get garbage on this: > > > > apropos options|wc -l|grep "^SYN" > > > > "wc" gives this: > > law> apropos options|grep "^SYN"|wc > > 1 2332 13924 > > > > That's one heck of a long line. Do I just have some junk somewhere? > > > > I could attach it, but I don't want to unnecessarily send all that > > junk out if it's easily reproducible. > > > > linda > > -- > > -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/