diff options
author | Siep Kroonenberg <siepo@cybercomm.nl> | 2011-02-17 17:32:35 +0000 |
---|---|---|
committer | Siep Kroonenberg <siepo@cybercomm.nl> | 2011-02-17 17:32:35 +0000 |
commit | 539135f1864a2356d0eb3666e0f5b335680872a4 (patch) | |
tree | 3b214294c17073dfdfbdba13b72b6fa2d10a0a6e /Master/tlpkg/tlperl/lib/CORE/util.h | |
parent | 227723589c9564b9b2b7042dd27eb9aad56a560a (diff) |
New tlperl part XII
git-svn-id: svn://tug.org/texlive/trunk@21434 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/tlperl/lib/CORE/util.h')
-rw-r--r-- | Master/tlpkg/tlperl/lib/CORE/util.h | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/Master/tlpkg/tlperl/lib/CORE/util.h b/Master/tlpkg/tlperl/lib/CORE/util.h new file mode 100644 index 00000000000..6eab0556860 --- /dev/null +++ b/Master/tlpkg/tlperl/lib/CORE/util.h @@ -0,0 +1,49 @@ +/* util.h + * + * Copyright (C) 1991, 1992, 1993, 1999, 2001, 2002, 2003, 2004, 2005, + * 2007, by Larry Wall and others + * + * You may distribute under the terms of either the GNU General Public + * License or the Artistic License, as specified in the README file. + * + */ + +#ifdef VMS +# define PERL_FILE_IS_ABSOLUTE(f) \ + (*(f) == '/' \ + || (strchr(f,':') \ + || ((*(f) == '[' || *(f) == '<') \ + && (isALNUM((f)[1]) || strchr("$-_]>",(f)[1]))))) + +#else /* !VMS */ +# if defined(WIN32) || defined(__CYGWIN__) +# define PERL_FILE_IS_ABSOLUTE(f) \ + (*(f) == '/' || *(f) == '\\' /* UNC/rooted path */ \ + || ((f)[0] && (f)[1] == ':')) /* drive name */ +# else /* !WIN32 */ +# ifdef NETWARE +# define PERL_FILE_IS_ABSOLUTE(f) \ + (((f)[0] && (f)[1] == ':') /* drive name */ \ + || ((f)[0] == '\\' && (f)[1] == '\\') /* UNC path */ \ + || ((f)[3] == ':')) /* volume name, currently only sys */ +# else /* !NETWARE */ +# if defined(DOSISH) || defined(EPOC) || defined(__SYMBIAN32__) +# define PERL_FILE_IS_ABSOLUTE(f) \ + (*(f) == '/' \ + || ((f)[0] && (f)[1] == ':')) /* drive name */ +# else /* NEITHER DOSISH NOR EPOCISH NOR SYMBIANISH */ +# define PERL_FILE_IS_ABSOLUTE(f) (*(f) == '/') +# endif /* DOSISH */ +# endif /* NETWARE */ +# endif /* WIN32 */ +#endif /* VMS */ + +/* + * Local variables: + * c-indentation-style: bsd + * c-basic-offset: 4 + * indent-tabs-mode: t + * End: + * + * ex: set ts=8 sts=4 sw=4 noet: + */ |