about summary refs log tree commit diff
path: root/scripts/NixManifest.pm.in
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2011-04-11T08·06+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2011-04-11T08·06+0000
commitb1882c3ef75afdaa7b0926cd146aa2857ba0d40a (patch)
tree3e1e32c229a6525ff09c241fb4898fd3dbcf28d6 /scripts/NixManifest.pm.in
parent5591fcc5292616e99d9d2478ffeb4f1b51f1899e (diff)
* Create $manifestDir if it doesn't exist.
Diffstat (limited to 'scripts/NixManifest.pm.in')
-rw-r--r--scripts/NixManifest.pm.in3
1 files changed, 3 insertions, 0 deletions
diff --git a/scripts/NixManifest.pm.in b/scripts/NixManifest.pm.in
index 998c23ef131e..4dda69710d7f 100644
--- a/scripts/NixManifest.pm.in
+++ b/scripts/NixManifest.pm.in
@@ -2,6 +2,7 @@ use strict;
 use DBI;
 use Cwd;
 use File::stat;
+use File::Path;
 
 
 sub addPatch {
@@ -198,6 +199,8 @@ sub writeManifest {
 sub updateManifestDB {
     my $manifestDir = ($ENV{"NIX_MANIFESTS_DIR"} or "@localstatedir@/nix/manifests");
 
+    mkpath($manifestDir);
+    
     my $dbPath = "$manifestDir/cache.sqlite";
 
     # Open/create the database.