зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1462489 - Re-generate the build backend when a build backend output is missing. r=mshal
MozReview-Commit-ID: CDO3bTGB4tj --HG-- extra : rebase_source : dfbd0e6bc3fa9bcdbd96de38e85e38dc945275bc
This commit is contained in:
Родитель
adac97a0fe
Коммит
1b8f9ac1a6
|
@ -993,6 +993,19 @@ class BuildDriver(MozbuildObject):
|
|||
return False
|
||||
|
||||
def backend_out_of_date(backend_file):
|
||||
if not os.path.isfile(backend_file):
|
||||
return True
|
||||
|
||||
# Check if any of our output files have been removed since
|
||||
# we last built the backend, re-generate the backend if
|
||||
# so.
|
||||
outputs = []
|
||||
with open(backend_file, 'r') as fh:
|
||||
outputs = fh.read().splitlines()
|
||||
for output in outputs:
|
||||
if not os.path.isfile(mozpath.join(self.topobjdir, output)):
|
||||
return True
|
||||
|
||||
dep_file = '%s.in' % backend_file
|
||||
return build_out_of_date(backend_file, dep_file)
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче