From: Borsenkow Andrej <Andrej.Borsenkow@mow.siemens.ru>
To: "'Eric Norum'" <eric.norum@usask.ca>, zsh-workers@sunsite.dk
Subject: RE: zsh breaks configure scripts
Date: Mon, 4 Mar 2002 18:19:31 +0300 [thread overview]
Message-ID: <007e01c1c38f$fc0c9ff0$21c9ca95@mow.siemens.ru> (raw)
In-Reply-To: <5CD7CBD8-2F7F-11D6-9666-00039366A118@usask.ca>
>
> Apple uses zsh as /bin/sh on Mac OS X. Unfortunately zsh has a
> `feature' that breaks many autoconf configure scripts. The scripts
> contain lines like:
> if test "`CDPATH=:; cd $srcdir && pwd`" != "`pwd`" && .......
>
> The problem is that the zsh cd command insists on printing the
directory!
>
> The offending code is in cd_new_pwd() in Src/builtins.c around line
1047:
> if (unset(PUSHDSILENT) && func != BIN_CD && isset(INTERACTIVE))
> printdirstack();
> else if (doprintdir) {
> fprintdir(pwd, stdout);
> putchar('\n');
> }
>
> I suggest that the fprintdir/putchar be called only in interactive
> shells:
> if (unset(PUSHDSILENT) && func != BIN_CD && isset(INTERACTIVE))
> printdirstack();
> else if (doprintdir && isset(INTERACTIVE)) {
> fprintdir(pwd, stdout);
> putchar('\n');
> }
>
Looking at different shells here:
sh does not print anything at all
ksh and bash do not print anything is we cd relative to empty CDPATH
element (the best I can explain it):
bor@itsrm2% ksh
$ cd
$ CDPATH=:; cd tmp
$ cd
$ CDPATH=.:/tmp; cd tmp
/home/bor/tmp
$ cd
$ CDPATH=:/tmp;cd tmp
$ cd
$ CDPATH=/tmp:; cd tmp
$ exit
May be we should just follow the suite?
-andrej
next prev parent reply other threads:[~2002-03-04 15:19 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-03-04 14:51 Eric Norum
2002-03-04 14:58 ` [Fink-devel] " Peter O'Gorman
2002-03-04 17:19 ` Bart Schaefer
2002-03-04 15:19 ` Borsenkow Andrej [this message]
2002-03-04 15:26 ` Peter Stephenson
2002-03-04 15:42 ` Alexandre Duret-Lutz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='007e01c1c38f$fc0c9ff0$21c9ca95@mow.siemens.ru' \
--to=andrej.borsenkow@mow.siemens.ru \
--cc=eric.norum@usask.ca \
--cc=zsh-workers@sunsite.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).