build/lattice/diamond: remove use of tools.mkdir_noerror
authorFlorent Kermarrec <florent@enjoy-digital.fr>
Thu, 16 Feb 2017 10:48:22 +0000 (11:48 +0100)
committerFlorent Kermarrec <florent@enjoy-digital.fr>
Thu, 16 Feb 2017 10:48:22 +0000 (11:48 +0100)
litex/build/lattice/diamond.py

index 68d1db449158eb5827a80bc274a4abeccbf22232..52ff58c14de8fa5839a4b429c38f0f1aea3ad571 100644 (file)
@@ -77,7 +77,7 @@ def _run_diamond(build_name, source, ver=None):
 class LatticeDiamondToolchain:
     def build(self, platform, fragment, build_dir="build", build_name="top",
               toolchain_path="/opt/Diamond", run=True, **kwargs):
-        tools.mkdir_noerror(build_dir)
+        os.makedirs(build_dir, exist_ok=True)
         cwd = os.getcwd()
         os.chdir(build_dir)