Made compiler working on Linux too

This commit is contained in:
Roman Venediktov 2024-07-01 11:37:41 +02:00
parent 468caac0f2
commit 85b838ea2b
10 changed files with 188 additions and 128 deletions

View file

@ -2,13 +2,20 @@ TESTS=$(sort $(filter-out test02 test30, $(basename $(wildcard test*.lama))))
LAMAC=../../src/lamac
UNAME_S := $(shell uname -s)
ifeq ($(UNAME_S),Linux)
else ifeq ($(UNAME_S),Darwin)
ARCH = arch -x86_64
endif
.PHONY: check $(TESTS)
check: $(TESTS)
$(TESTS): %: %.lama
@echo "stdlib/regression/$@"
@LAMA=../../runtime $(LAMAC) -I .. -ds -dp $< && arch -X86_64 ./$@ > $@.log && diff $@.log orig/$@.log
@LAMA=../../runtime $(LAMAC) -I .. -ds -dp $< && $(ARCH) ./$@ > $@.log && diff $@.log orig/$@.log
clean:
$(RM) test*.log *.s *~ $(TESTS) *.i