build/sim/verilator: don't use --threads when $(THREADS) is unset
authorJean-François Nguyen <jf@lambdaconcept.com>
Fri, 2 Nov 2018 13:22:44 +0000 (14:22 +0100)
committerJean-François Nguyen <jf@lambdaconcept.com>
Fri, 2 Nov 2018 13:22:44 +0000 (14:22 +0100)
litex/build/sim/core/Makefile

index daba3ddac1b993e2ee2babecffd6b63375013593..4be325caca046e63d86689852097a677354273a0 100644 (file)
@@ -27,7 +27,7 @@ sim: mkdir $(OBJS_SIM)
        verilator -Wno-fatal -O3 --cc dut.v --top-module dut --exe \
                $(SRCS_SIM_CPP) $(OBJS_SIM) \
                --top-module dut \
-               --threads $(THREADS) \
+               $(if $(THREADS), --threads $(THREADS),) \
                -CFLAGS "$(CFLAGS) -I$(SRC_DIR)" \
                -LDFLAGS "$(LDFLAGS)" \
                -trace $(INC_DIR)