Don't delete the output dirs in prepare

In some builds, this script is invoked several times in a single
target. The removal of the dist dirs leads to the output of the
first invocation to be deleted at the beginning of the second
invocation.

Test: atest mainline_modules_sdks_test
Change-Id: I39620b849ae8029719dc6cf150dae5092a093ea9
Merged-In: I39620b849ae8029719dc6cf150dae5092a093ea9
This commit is contained in:
Anton Hansson
2022-09-09 17:53:07 +00:00
parent d64ca6c104
commit 648be3371c

View File

@@ -1124,9 +1124,7 @@ class SdkDistProducer:
"bundled-mainline-sdks") "bundled-mainline-sdks")
def prepare(self): def prepare(self):
# Clear the sdk dist directories. pass
shutil.rmtree(self.mainline_sdks_dir, ignore_errors=True)
shutil.rmtree(self.bundled_mainline_sdks_dir, ignore_errors=True)
def produce_dist(self, modules, build_releases): def produce_dist(self, modules, build_releases):
# Prepare the dist directory for the sdks. # Prepare the dist directory for the sdks.