diff options
author | 1994-06-30 19:09:44 +0000 | |
---|---|---|
committer | 1994-06-30 19:09:44 +0000 | |
commit | e6cfca0ed0c1a1145efa76fde523b9ce2a9b513f (patch) | |
tree | fcdc038298eb7c6b507fa9845513fe8eccd63091 /util | |
parent | 49977b891e8ca5bc5713868489a9c8b2c75d536e (diff) |
Initial revision
Diffstat (limited to 'util')
-rwxr-xr-x | util/autoconf/mkinstalldirs | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/util/autoconf/mkinstalldirs b/util/autoconf/mkinstalldirs new file mode 100755 index 0000000..91f6d04 --- /dev/null +++ b/util/autoconf/mkinstalldirs @@ -0,0 +1,32 @@ +#!/bin/sh +# mkinstalldirs --- make directory hierarchy +# Author: Noah Friedman <friedman@prep.ai.mit.edu> +# Created: 1993-05-16 +# Last modified: 1994-03-25 +# Public domain + +errstatus=0 + +for file in ${1+"$@"} ; do + set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` + shift + + pathcomp= + for d in ${1+"$@"} ; do + pathcomp="$pathcomp$d" + case "$pathcomp" in + -* ) pathcomp=./$pathcomp ;; + esac + + if test ! -d "$pathcomp"; then + echo "mkdir $pathcomp" 1>&2 + mkdir "$pathcomp" || errstatus=$? + fi + + pathcomp="$pathcomp/" + done +done + +exit $errstatus + +# mkinstalldirs ends here |