-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 [cross-posted to autoconf, thread starts at http://lists.gnu.org/archive/html/bug-texinfo/2005-01/msg00016.html] According to Eli Zaretskii on 1/18/2005 1:18 PM: >>Date: Tue, 18 Jan 2005 06:29:08 -0700 >>From: Eric Blake <ebb9@xxxxxxx> >>Cc: dave@xxxxxxxxxxxxxxxxxxxx, cygwin@xxxxxxxxxx >> >>Instead of using $COMSPEC for determining the path >>separator, you should use autoconf's approach (look at any recent >>configure script generated by autoconf 2.59 for this snippet): >> >>if test "${PATH_SEPARATOR+set}" != set; then >> echo "#! /bin/sh" >conf$$.sh >> echo "exit 0" >>conf$$.sh >> chmod +x conf$$.sh >> if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then >> PATH_SEPARATOR=';' >> else >> PATH_SEPARATOR=: >> fi >> rm -f conf$$.sh >>fi > > > If this is what Autoconf 2.59 really does (i.e., no typos etc. in this > snippet), then Autoconf 2.59 is broken, at least for DJGPP, because it > will always produce PATH_SEPARATOR=:. This is because it invalidates > PATH, and therefore defeats the DJGPP magic that looks for sh.exe > along PATH if /bin/sh.exe does not exist. (And /bin/sh.exe does not > exists on almost every DJGPP installation.) If this is true about DJGPP, then autoconf needs to revisit how PATH_SEPARATOR is calculated. > > Instead of such complicated jumps through the hoops, I'd suggest to > keep the original test, but augment it with something specific to > Cygwin. Is there some environment variable, like OSTYPE or something, > whose value shows that a Cygwin Bash is being run? If there is such a > variable, we could look at it in addition to COMSPEC. There is always the uname utility, although I'm not sure it is the best approach: case `uname` in CYGWIN*) path_sep=: ;; esac >>Additionally, according to autoconf, `test -x' is not portable. > > But needed for DJGPP/MinGW, where "test -f tex" does not find tex.exe, > but "test -x tex" does. > > So if this is changed to not use "test -x", the non-Posix systems will > still need "test -x" (which is okay for those systems, since the > ported Bash supports "test -x"). CVS Autoconf also tackled this issue, see http://lists.gnu.org/archive/html/autoconf-patches/2004-12/msg00057.html > > >>Your best bet may be to make texi2dvi a generated file from >>texi2dvi.in, and let autoconf determine @PATH_SEPARATOR@ and even >>the location of tex up front at configure time > > > Again, doing the latter (i.e. determining the location of TeX at > configure time) might be okay on Posix systems, but not on > DJGPP/MinGW, since it is _very_ customary on those systems to download > pre-compiled binaries, and thus configure-time settings are usually > invalid. (Actually, I think Cygwin users will not like your > suggestion either, since AFAIK they, too, tend to download binaries.) > But on cygwin downloads, they tend to be to a normalized path (ie the cygwin installation point is normalized to /, all pre-compiled cygwin binaries are put in /bin, and /usr/bin is mounted to /bin), so even if the tex executable is downloaded to something as outrageous as 'q:\my hairy\windows\path\cygwin\bin', the precompiled binary still sees it at /usr/bin because of the PATH normalization going on. - -- Life is short - so eat dessert first! Eric Blake ebb9@xxxxxxx -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (Cygwin) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFB7lRJ84KuGfSFAYARApVkAJ9V5cXc+tq9E/ePBMeclrXYFBXHBQCgwuoF j2/HYvYy48SqMN+4v6MaA5c= =BK5I -----END PGP SIGNATURE----- _______________________________________________ Autoconf mailing list Autoconf@xxxxxxx http://lists.gnu.org/mailman/listinfo/autoconf