Commit 573ef26e authored by Tristan Gingold's avatar Tristan Gingold

Improve coverage of libero.

parent 4ebfaf4f
...@@ -59,5 +59,5 @@ class SourceFileSet(set): ...@@ -59,5 +59,5 @@ class SourceFileSet(set):
def sort(self): def sort(self):
"""Return a sorted list of the fileset. This is useful to have always """Return a sorted list of the fileset. This is useful to have always
the same output""" the same output"""
return sorted(self, key=(lambda x: x.file_path)) return sorted(self, key=(lambda x: x.path))
...@@ -94,7 +94,7 @@ class ToolLibero(MakefileSyn): ...@@ -94,7 +94,7 @@ class ToolLibero(MakefileSyn):
compilation_constraints = [] compilation_constraints = []
ret = [] ret = []
# First stage: linking files # First stage: linking files
for file_aux in self.fileset: for file_aux in self.fileset.sort():
if isinstance(file_aux, SDCFile): if isinstance(file_aux, SDCFile):
synthesis_constraints.append(file_aux) synthesis_constraints.append(file_aux)
compilation_constraints.append(file_aux) compilation_constraints.append(file_aux)
......
...@@ -34,9 +34,13 @@ SOURCES_VHDLFile := \ ...@@ -34,9 +34,13 @@ SOURCES_VHDLFile := \
SOURCES_SDCFile := \ SOURCES_SDCFile := \
syn.sdc syn.sdc
SOURCES_PDCFile := \
comp.pdc
files.tcl: files.tcl:
@$(foreach sourcefile, $(SOURCES_VHDLFile), echo "create_links -hdl_source $(sourcefile)" >> $@ &) @$(foreach sourcefile, $(SOURCES_VHDLFile), echo "create_links -hdl_source $(sourcefile)" >> $@ &)
@$(foreach sourcefile, $(SOURCES_SDCFile), echo "create_links -sdc $(sourcefile)" >> $@ &) @$(foreach sourcefile, $(SOURCES_SDCFile), echo "create_links -sdc $(sourcefile)" >> $@ &)
@$(foreach sourcefile, $(SOURCES_PDCFile), echo "create_links -pdc $(sourcefile)" >> $@ &)
SYN_PRE_PROJECT_CMD := SYN_PRE_PROJECT_CMD :=
SYN_POST_PROJECT_CMD := SYN_POST_PROJECT_CMD :=
...@@ -48,7 +52,7 @@ project.tcl: ...@@ -48,7 +52,7 @@ project.tcl:
echo $(TCL_CREATE) >> $@ echo $(TCL_CREATE) >> $@
echo source files.tcl >> $@ echo source files.tcl >> $@
echo organize_tool_files -tool {SYNTHESIZE} -file {syn.sdc} -module {$(TOP_MODULE)::work} -input_type {constraint} >> $@ echo organize_tool_files -tool {SYNTHESIZE} -file {syn.sdc} -module {$(TOP_MODULE)::work} -input_type {constraint} >> $@
echo organize_tool_files -tool {COMPILE} -file {syn.sdc} -module {$(TOP_MODULE)::work} -input_type {constraint} >> $@ echo organize_tool_files -tool {COMPILE} -file {comp.pdc} -file {syn.sdc} -module {$(TOP_MODULE)::work} -input_type {constraint} >> $@
echo set_root -module {$(TOP_MODULE)::work} >> $@ echo set_root -module {$(TOP_MODULE)::work} >> $@
echo $(TCL_SAVE) >> $@ echo $(TCL_SAVE) >> $@
echo $(TCL_CLOSE) >> $@ echo $(TCL_CLOSE) >> $@
......
...@@ -8,7 +8,4 @@ syn_project="gate" ...@@ -8,7 +8,4 @@ syn_project="gate"
top_module = "gate" top_module = "gate"
# Not reliable. files = [ "../files/gate.vhdl", "syn.sdc", "comp.pdc" ]
#files = [ "../files/gate.vhdl", "syn.sdc", "comp.pdc" ]
files = [ "../files/gate.vhdl", "syn.sdc" ]
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment