diff --git a/em_multistrap b/em_multistrap index b99028d..01fd5cc 100755 --- a/em_multistrap +++ b/em_multistrap @@ -160,9 +160,12 @@ $libdir = "var/lib/apt/"; # lists $etcdir = "etc/apt/"; # sources $dpkgdir = "var/lib/dpkg/"; # state -my $ret = mkdir ("$dir") if (not -d "$dir"); -die ("Unable to create directory '$dir'\n") - if ($ret == 0); +if (not -d "$dir") +{ + my $ret = mkdir ("$dir"); + die ("Unable to create directory '$dir' $!\n") + if ($ret == 0); +} $dir = `realpath $dir`; chomp ($dir); $dir .= ($dir =~ m:/$:) ? '' : "/";