2
0
mirror of https://gitlab.com/ita1024/waf.git synced 2024-11-22 18:07:12 +01:00

Missing configuration files should raise an instance of WafError

This commit is contained in:
Thomas Nagy 2016-02-08 22:41:12 +01:00
parent 6d6222bc18
commit f7ed95d60e
No known key found for this signature in database
GPG Key ID: 67A565EDFDF90E64

View File

@ -223,10 +223,8 @@ class BuildContext(Context.Context):
self.all_envs[name] = env
for f in env[CFG_FILES]:
newnode = self.root.find_resource(f)
try:
Utils.h_file(newnode.abspath())
except (IOError, OSError, AttributeError):
raise ValueError('Missing configuration file %r, reconfigure the project' % f)
if not newnode or not newnode.exists():
raise Errors.WafError('Missing configuration file %r, reconfigure the project!' % f)
def init_dirs(self):
"""