chiselwatt
chiselwatt copied to clipboard
improve building without docker
It's somewhat not-straightforward to build chiselwatt without
docker on Linux. For example, when setting Verilator=verilator we run into the following issues:
@$(VERILATOR) bash || trueevaluates toverilator bash || true$(VERILATOR) verilator -O3 --assert --cc Core.v --exe chiselwatt.cpp uart.c -o $@ #--traceevaluates toverilator verilator -O3 --assert --cc Core.v --exe chiselwatt.cpp uart.c -o $@ #--trace
After playing around, I believe the best way to get around this is to just have another makefile,
namely, local.mk.
dockerlator doesn't work on my Apple Silicon Mac since the upstream image is x86 only. Building with a local verilator, yosys, scala, and ecppack works just fine on Apple Silicon however...
Thanks @BracketMaster! I just approved a PR from @carlosedp to use fusesoc for building, I wonder if that helps you too?
Not really. The issue is that the makefile as currently provided doesn't allow for docker-free building of chiselwatt in verilator without the following changes:
Instead of having another Makefile (that would bring more maintenance), I think a better approach is having some variable passed to make (like LOCALBUILD=true make) and have the ifs in the current Makefile to build with local tools instead.
Also as Anton mentioned, FuseSoc uses by default the local tools and doesn't use the Makefile so it could work in your case. FuseSoc only uses containers if you pass an EDALIZE_LAUNCHER variable as a launch script that wraps the tools in Docker containers.
oh - does fusesoc invoke verilator simulations too?