genlink: Rewrite genlink script from awk to python

This removes the dependency on awk and should fix #732
python was already a dependency, for the irq generation
This commit is contained in:
George Jiglau
2017-11-21 02:11:51 +00:00
committed by Karl Palsson
parent c7d46c4fbb
commit 396701808d
8 changed files with 151 additions and 113 deletions

View File

@@ -19,4 +19,4 @@
$(LDSCRIPT): $(OPENCM3_DIR)/ld/linker.ld.S $(OPENCM3_DIR)/ld/devices.data
@printf " GENLNK $(DEVICE)\n"
$(Q)$(CPP) $(ARCH_FLAGS) $(shell gawk -v PAT="$(DEVICE)" -v MODE="DEFS" -f $(OPENCM3_DIR)/scripts/genlink.awk $(OPENCM3_DIR)/ld/devices.data 2>/dev/null) -P -E $< > $@
$(Q)$(CPP) $(ARCH_FLAGS) $(shell $(OPENCM3_DIR)/scripts/genlink.py $(DEVICES_DATA) $(DEVICE) DEFS) -P -E $< > $@