annotate m4/double-slash-root.m4 @ 423:079d43b6967b 3.0-beta2 3.0-beta2

Added missing file
author lost@l-w.ca
date Sun, 19 Sep 2010 01:44:47 -0600
parents 3c2e1f24cc7d
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
421
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
1 # double-slash-root.m4 serial 4 -*- Autoconf -*-
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
2 dnl Copyright (C) 2006, 2008-2010 Free Software Foundation, Inc.
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
3 dnl This file is free software; the Free Software Foundation
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
4 dnl gives unlimited permission to copy and/or distribute it,
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
5 dnl with or without modifications, as long as this notice is preserved.
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
6
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
7 AC_DEFUN([gl_DOUBLE_SLASH_ROOT],
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
8 [
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
9 AC_REQUIRE([AC_CANONICAL_HOST])
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
10 AC_CACHE_CHECK([whether // is distinct from /], [gl_cv_double_slash_root],
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
11 [ if test x"$cross_compiling" = xyes ; then
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
12 # When cross-compiling, there is no way to tell whether // is special
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
13 # short of a list of hosts. However, the only known hosts to date
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
14 # that have a distinct // are Apollo DomainOS (too old to port to),
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
15 # Cygwin, and z/OS. If anyone knows of another system for which // has
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
16 # special semantics and is distinct from /, please report it to
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
17 # <bug-gnulib@gnu.org>.
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
18 case $host in
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
19 *-cygwin | i370-ibm-openedition)
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
20 gl_cv_double_slash_root=yes ;;
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
21 *)
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
22 # Be optimistic and assume that / and // are the same when we
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
23 # don't know.
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
24 gl_cv_double_slash_root='unknown, assuming no' ;;
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
25 esac
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
26 else
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
27 set x `ls -di / // 2>/dev/null`
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
28 if test "$[2]" = "$[4]" && wc //dev/null >/dev/null 2>&1; then
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
29 gl_cv_double_slash_root=no
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
30 else
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
31 gl_cv_double_slash_root=yes
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
32 fi
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
33 fi])
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
34 if test "$gl_cv_double_slash_root" = yes; then
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
35 AC_DEFINE([DOUBLE_SLASH_IS_DISTINCT_ROOT], [1],
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
36 [Define to 1 if // is a file system root distinct from /.])
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
37 fi
3c2e1f24cc7d Added generated files for release
lost@l-w.ca
parents:
diff changeset
38 ])