autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Patch for AS_MKDIR_P to properly support DOS paths


From: Tim Van Holder
Subject: Patch for AS_MKDIR_P to properly support DOS paths
Date: Wed, 17 Jan 2001 20:24:29 +0100

The diff below patches AS_MKDIR_P to properly support DOS-style
paths. This entails
 a) using \ as well as / as dirsep (IFS)
 b) not trying to mkdir a drivespec

2001-01-17  Tim Van Holder  <address@hidden>

        * m4sh.m4 (AS_MKDIR_P): Properly support DOS-style paths.

diff -u -r --new-file --show-function-line='^[A-Za-z_]' 
autoconf-2.49b.gnu/m4sh.m4 autoconf-2.49b/m4sh.m4
--- autoconf-2.49b.gnu/m4sh.m4  Wed Dec  6 10:04:48 2000
+++ autoconf-2.49b/m4sh.m4      Sun Dec 31 17:38:32 2000
@@ -307,9 +307,15 @@ m4_define([AS_MKDIR_P],
   *)                      ac_incr_dir=.;;
 esac
 ac_dummy=$1
-for ac_mkdir_dir in `IFS=/; set X $ac_dummy; shift; echo "address@hidden"`; do
-  ac_incr_dir=$ac_incr_dir/$ac_mkdir_dir
-  test -d $ac_incr_dir || mkdir $ac_incr_dir
+for ac_mkdir_dir in `IFS='\\/'; set X $ac_dummy; shift; echo 
"address@hidden"`; do
+  case $ac_mkdir_dir in
+    # Skip DOS drivespec
+    ?:) ac_incr_dir=$ac_mkdir_dir ;;
+    *)
+      ac_incr_dir=$ac_incr_dir/$ac_mkdir_dir
+      test -d $ac_incr_dir || mkdir $ac_incr_dir
+    ;;
+  esac
 done; }
 ])# AS_MKDIR_P
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]