interpreter: Print what subproject dir could not be found

Fixes #655
This commit is contained in:
Nirbheek Chauhan 2016-08-01 09:34:01 +05:30
parent 4f6be39d26
commit 58ad092ff3
1 changed files with 2 additions and 1 deletions

View File

@ -1387,7 +1387,8 @@ class Interpreter():
r = wrap.Resolver(os.path.join(self.build.environment.get_source_dir(), self.subproject_dir))
resolved = r.resolve(dirname)
if resolved is None:
raise InterpreterException('Subproject directory does not exist and can not be downloaded.')
msg = 'Subproject directory {!r} does not exist and can not be downloaded.'
raise InterpreterException(msg.format(os.path.join(self.subproject_dir, dirname)))
subdir = os.path.join(self.subproject_dir, resolved)
os.makedirs(os.path.join(self.build.environment.get_build_dir(), subdir), exist_ok=True)
self.global_args_frozen = True