summaryrefslogtreecommitdiff
path: root/lib/ylwrap
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>1998-07-17 22:00:24 +0000
committerTom Tromey <tromey@redhat.com>1998-07-17 22:00:24 +0000
commit5a349bbaf59ba128e2ed1bef45e99c2a05df3852 (patch)
treea7fe5a8a3d3c74c29e4b19b6ccb9afadb5181afd /lib/ylwrap
parent111a0b97dada1741561e471846ea7757309b6dc5 (diff)
downloadautomake-5a349bbaf59ba128e2ed1bef45e99c2a05df3852.tar.gz
recognize DOS paths as absolute
Diffstat (limited to 'lib/ylwrap')
-rwxr-xr-xlib/ylwrap10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/ylwrap b/lib/ylwrap
index 93bfecd7b..13fc38d75 100755
--- a/lib/ylwrap
+++ b/lib/ylwrap
@@ -1,6 +1,6 @@
#! /bin/sh
# ylwrap - wrapper for lex/yacc invocations.
-# Copyright (C) 1996, 1997 Free Software Foundation, Inc.
+# Copyright (C) 1996, 1997, 1998 Free Software Foundation, Inc.
# Written by Tom Tromey <tromey@cygnus.com>.
#
# This program is free software; you can redistribute it and/or modify
@@ -31,7 +31,7 @@ prog="$1"
shift
# Make any relative path in $prog absolute.
case "$prog" in
- /*) ;;
+ /* | [A-Za-z]:\\*) ;;
*/*) prog="`pwd`/$prog" ;;
esac
@@ -39,7 +39,7 @@ esac
input="$1"
shift
case "$input" in
- /*)
+ /* | [A-Za-z]:\\*)
# Absolute path; do nothing.
;;
*)
@@ -75,7 +75,7 @@ mkdir $dirname || exit 1
cd $dirname
case "$input" in
- /*)
+ /* | [A-Za-z]:\\*)
# Absolute path; do nothing.
;;
*)
@@ -95,7 +95,7 @@ if test $status -eq 0; then
# If $2 is an absolute path name, then just use that,
# otherwise prepend `../'.
case "$2" in
- /*) target="$2";;
+ /* | [A-Za-z]:\\*) target="$2";;
*) target="../$2";;
esac
mv "$1" "$target" || status=$?