Re: 2.99.1: new beta / almost release candidate
Jan Nieuwenhuizen <[email protected]>
| Newsgroups | gmane.comp.tex.tetex.beta |
|---|---|
| Organization | Jan at Appel |
| Message-ID | <[email protected]> |
Thomas Esser writes:
> Well, shortly after 2.99.0, we now see this 2.99.1 release. Besides
> the fact that I still want to try to rewrite texconfig, this can be
> considered something like a release candidate.
>
> I have cleaned up a lot and most things are in a state that I feel
> comfortable with.
I'm quite happy with this release, it [cross] builds out of the box
for Cygwin (except for the usual libtool handholding). The only thing
I've added is the UNC file name patch, see below.
A big thank you, also to Olaf.
Jan.
diff -purNXcygwin/.cvsignore ../tetex-src-beta-2.99.1.20041026/texk/kpathsea/c-pathch.h ./texk/kpathsea/c-pathch.h
--- ../tetex-src-beta-2.99.1.20041026/texk/kpathsea/c-pathch.h 2001-11-12 08:45:59 +0100
+++ ./texk/kpathsea/c-pathch.h 2004-10-28 16:22:23 +0200
@@ -74,6 +74,12 @@ Foundation, Inc., 59 Temple Place - Suit
#define IS_UNC_NAME(name) 0
#endif
+#ifdef WIN32
+# define DEVICE_SEP_LEN 1
+#else
+# define DEVICE_SEP_LEN 0
+#endif
+
/* What separates elements in environment variable path lists? */
#ifndef ENV_SEP
#ifdef VMS
diff -purNXcygwin/.cvsignore ../tetex-src-beta-2.99.1.20041026/texk/kpathsea/elt-dirs.c ./texk/kpathsea/elt-dirs.c
--- ../tetex-src-beta-2.99.1.20041026/texk/kpathsea/elt-dirs.c 2001-10-22 23:31:30 +0200
+++ ./texk/kpathsea/elt-dirs.c 2004-10-28 16:22:23 +0200
@@ -357,6 +357,7 @@ expand_elt P3C(str_llist_type *, str_lis
handle well filenames like c://dir/foo. So canonicalize the names.
The resulting name will always be shorter than the one passed, so no
problem.
+ - Similarly for Cygwin, re(mem)move multiple leading slashes.
- If possible, we merely skip multiple leading slashes to prevent
expanding from the root of a UNIX filesystem tree.
*/
@@ -375,15 +376,27 @@ kpse_normalize_path P1C(string, elt)
memmove(elt+3, elt+i, strlen(elt+i) + 1);
ret = 2;
} else if (IS_UNC_NAME(elt)) {
- for (ret = 2; elt[ret] && !IS_DIR_SEP(elt[ret]); ++ret)
+ for (ret = 1 + DEVICE_SEP_LEN; elt[ret] && !IS_DIR_SEP(elt[ret]); ++ret)
;
for (i = ret; elt[i] && IS_DIR_SEP(elt[i]); ++i)
;
- if (i > ret+1)
- memmove(elt+ret+1, elt+i, strlen(elt+i) + 1);
+ if (i > ret + DEVICE_SEP_LEN)
+ memmove(elt+ret+DEVICE_SEP_LEN, elt+i, strlen(elt+i) + 1);
} else {
+ char* p;
for (ret = 0; IS_DIR_SEP(elt[ret]); ++ret)
;
+#ifdef __CYGWIN__
+ /* Collapse UNC prefixes, unless evironment var KPSE_SEARCH_UNC
+ is set.
+
+ Names like //share/texmf-local and //texmf/web2c are UNC
+ paths, and trigger hostname lookups; which is not what a
+ casual user wants. */
+ p = getenv ("KPSE_SEARCH_UNC");
+ if (ret > 1 && !(p && strcasecmp (p, "no")))
+ memmove(elt, elt+ret-1, strlen(elt+ret) + 1);
+#endif
}
if (KPSE_DEBUG_P (KPSE_DEBUG_STAT))
--
Jan Nieuwenhuizen <[email protected]> | GNU LilyPond - The music typesetter
http://www.xs4all.nl/~jantien | http://www.lilypond.org