Use makedirs instead of mkdir. Closes #247.

This commit is contained in:
Jussi Pakkanen 2015-08-27 20:29:20 +03:00
parent f32db9afa2
commit e29e4358e6
4 changed files with 6 additions and 1 deletions

View File

@ -1540,7 +1540,7 @@ class Interpreter():
self.visited_subdirs[subdir] = True
self.subdir = subdir
try:
os.mkdir(os.path.join(self.environment.build_dir, subdir))
os.makedirs(os.path.join(self.environment.build_dir, subdir))
except FileExistsError:
pass
buildfilename = os.path.join(self.subdir, environment.build_filename)

View File

@ -0,0 +1,3 @@
project('foo', 'c')
subdir('subdir1/subdir2')

View File

@ -0,0 +1 @@
error('This should not be called.')

View File

@ -0,0 +1 @@
message('I\'m in subdir subdir.')