Use -i/-m instead of -a/-e with GHDL
Currently, if multiple libraries or files depend on each other, they
must be analyzed in the correct order.
With -i/-m GHDL is able to automatically detect the correct build order.
@@ -60,9 +60,9 @@ GHDL_ARGS += $(EXTRA_ARGS)
analyse: $(VHDL_SOURCES) $(SIM_BUILD)
cd $(SIM_BUILD) && \
$(foreach SOURCES_VAR, $(filter VHDL_SOURCES_%, $(.VARIABLES)), \
- $(CMD) -a $(GHDL_ARGS) $(COMPILE_ARGS) --work=$(SOURCES_VAR:VHDL_SOURCES_%=%) $($(SOURCES_VAR)) && ) \
- $(CMD) -a $(GHDL_ARGS) $(COMPILE_ARGS) --work=$(RTL_LIBRARY) $(VHDL_SOURCES) && \
- $(CMD) -e $(GHDL_ARGS) $(COMPILE_ARGS) --work=$(RTL_LIBRARY) $(TOPLEVEL)
+ $(CMD) -i $(GHDL_ARGS) $(COMPILE_ARGS) --work=$(SOURCES_VAR:VHDL_SOURCES_%=%) $($(SOURCES_VAR)) && ) \
+ $(CMD) -i $(GHDL_ARGS) $(COMPILE_ARGS) --work=$(RTL_LIBRARY) $(VHDL_SOURCES) && \
+ $(CMD) -m $(GHDL_ARGS) $(COMPILE_ARGS) --work=$(RTL_LIBRARY) $(TOPLEVEL)
results.xml: analyse $(COCOTB_LIBS) $(COCOTB_VPI_LIB)
cd $(SIM_BUILD); \
