From 9d716def9d23954262c7c87a77ddfb64f47d35c5 Mon Sep 17 00:00:00 2001 From: Tim 'mithro' Ansell Date: Thu, 15 Dec 2016 16:33:08 +0100 Subject: [PATCH] Make the csv directory if it doesn't exist. --- litex/soc/integration/builder.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/litex/soc/integration/builder.py b/litex/soc/integration/builder.py index 06bdbb58..866a4fcd 100644 --- a/litex/soc/integration/builder.py +++ b/litex/soc/integration/builder.py @@ -95,6 +95,8 @@ class Builder: csr_regions = self.soc.get_csr_regions() constants = self.soc.get_constants() + csr_dir = os.path.dirname(self.csr_csv) + os.makedirs(csr_dir, exist_ok=True) with open(self.csr_csv, "w") as f: f.write(cpu_interface.get_csr_csv(csr_regions, constants, memory_regions)) -- 2.30.2