summaryrefslogtreecommitdiffstats
path: root/contrib/awk/mkinstalldirs
diff options
context:
space:
mode:
authorsheldonh <sheldonh@FreeBSD.org>2000-08-15 10:02:07 +0000
committersheldonh <sheldonh@FreeBSD.org>2000-08-15 10:02:07 +0000
commit4e5281d00b8fa7447d70020d36660157e7e43626 (patch)
tree88d7fea3d791af620456e3cd42ff2bf1c4229af2 /contrib/awk/mkinstalldirs
parent946d89ae2629e07c7d4735eac8d1f5ac2263ce58 (diff)
downloadFreeBSD-src-4e5281d00b8fa7447d70020d36660157e7e43626.zip
FreeBSD-src-4e5281d00b8fa7447d70020d36660157e7e43626.tar.gz
Update vendor branch to gawk-3.0.6.
Diffstat (limited to 'contrib/awk/mkinstalldirs')
-rwxr-xr-xcontrib/awk/mkinstalldirs32
1 files changed, 32 insertions, 0 deletions
diff --git a/contrib/awk/mkinstalldirs b/contrib/awk/mkinstalldirs
new file mode 100755
index 0000000..0801ec2
--- /dev/null
+++ b/contrib/awk/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
OpenPOWER on IntegriCloud