integration/builder/soc: Add get_build_name method (Useful now that builder is no longer called automatically without --build).
This commit is contained in:
parent
e451a87617
commit
aa8932dd4f
|
@ -369,7 +369,7 @@ class Builder:
|
|||
"sram" : self.soc.platform.bitstream_ext,
|
||||
"flash" : ".bin" # FIXME.
|
||||
}[mode]
|
||||
return os.path.join(self.gateware_dir, self.soc.build_name + ext)
|
||||
return os.path.join(self.gateware_dir, self.soc.get_build_name() + ext)
|
||||
|
||||
# Builder Arguments --------------------------------------------------------------------------------
|
||||
|
||||
|
|
|
@ -1197,6 +1197,9 @@ class SoC(Module):
|
|||
self.logger.info(colorer("-"*80, color="bright"))
|
||||
|
||||
# SoC build ------------------------------------------------------------------------------------
|
||||
def get_build_name(self):
|
||||
return getattr(self, "build_name", self.platform.name)
|
||||
|
||||
def build(self, *args, **kwargs):
|
||||
self.build_name = kwargs.pop("build_name", self.platform.name)
|
||||
if self.build_name[0].isdigit():
|
||||
|
|
Loading…
Reference in New Issue