From: enjoy-digital Date: Sun, 28 Oct 2018 13:59:03 +0000 (+0100) Subject: Merge branch 'master' into xilinx+yosys X-Git-Tag: 24jan2021_ls180~1555^2 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b200ce9983c6efafcb992b9f93961bce5f5a6c39;p=litex.git Merge branch 'master' into xilinx+yosys --- b200ce9983c6efafcb992b9f93961bce5f5a6c39 diff --cc litex/build/xilinx/vivado.py index f0c2aecf,10a795bd..974958c9 --- a/litex/build/xilinx/vivado.py +++ b/litex/build/xilinx/vivado.py @@@ -106,17 -106,15 +106,17 @@@ class XilinxVivadoToolchain self.clocks = dict() self.false_paths = set() - def _build_batch(self, platform, sources, edifs, ips, build_name): + def _build_batch(self, platform, sources, edifs, ips, build_name, synth_mode="vivado"): tcl = [] tcl.append("create_project -force -name {} -part {}".format(build_name, platform.device)) + tcl.append("set_property XPM_LIBRARIES {XPM_CDC XPM_MEMORY} [current_project]") - for filename, language, library in sources: - filename_tcl = "{" + filename + "}" - tcl.append("add_files " + filename_tcl) - tcl.append("set_property library {} [get_files {}]" - .format(library, filename_tcl)) + if synth_mode == "vivado": + # "-include_dirs {}" crashes Vivado 2016.4 + for filename, language, library in sources: + filename_tcl = "{" + filename + "}" + tcl.append("add_files " + filename_tcl) + tcl.append("set_property library {} [get_files {}]" + .format(library, filename_tcl)) - for filename in edifs: filename_tcl = "{" + filename + "}" tcl.append("read_edif " + filename_tcl)