Remove redundant -arch flags

This commit is contained in:
Roman Venediktov 2024-07-04 10:49:15 +02:00
parent ad11588540
commit d13c559934
3 changed files with 4 additions and 17 deletions

View file

@ -3,13 +3,6 @@ TESTS=$(sort $(filter-out test111, $(basename $(wildcard test*.lama))))
LAMAC=../src/lamac 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) .PHONY: check $(TESTS)
@ -19,7 +12,7 @@ $(TESTS): %: %.lama
@echo "regression/$@" @echo "regression/$@"
@cat $@.input | LAMA=../runtime $(LAMAC) -i $< > $@.log && diff $@.log orig/$@.log @cat $@.input | LAMA=../runtime $(LAMAC) -i $< > $@.log && diff $@.log orig/$@.log
@cat $@.input | LAMA=../runtime $(LAMAC) -ds -s $< > $@.log && diff $@.log orig/$@.log @cat $@.input | LAMA=../runtime $(LAMAC) -ds -s $< > $@.log && diff $@.log orig/$@.log
@LAMA=../runtime $(LAMAC) $< && cat $@.input | $(ARCH) ./$@ > $@.log && diff $@.log orig/$@.log @LAMA=../runtime $(LAMAC) $< && cat $@.input | ./$@ > $@.log && diff $@.log orig/$@.log
ctest111: ctest111:
@echo "regression/test111" @echo "regression/test111"

View file

@ -1,11 +1,12 @@
UNAME_S := $(shell uname -s) UNAME_S := $(shell uname -s)
ifeq ($(UNAME_S),Linux) ifeq ($(UNAME_S),Linux)
CC=gcc
else ifeq ($(UNAME_S),Darwin) else ifeq ($(UNAME_S),Darwin)
CC=clang
ARCH = -arch x86_64 ARCH = -arch x86_64
endif endif
CC=clang
DISABLE_WARNINGS=-Wno-shift-negative-value DISABLE_WARNINGS=-Wno-shift-negative-value
COMMON_FLAGS=$(DISABLE_WARNINGS) -g -fstack-protector-all $(ARCH) --std=c11 COMMON_FLAGS=$(DISABLE_WARNINGS) -g -fstack-protector-all $(ARCH) --std=c11
PROD_FLAGS=$(COMMON_FLAGS) -DLAMA_ENV PROD_FLAGS=$(COMMON_FLAGS) -DLAMA_ENV

View file

@ -2,20 +2,13 @@ TESTS=$(sort $(filter-out test02 test30, $(basename $(wildcard test*.lama))))
LAMAC=../../src/lamac 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) .PHONY: check $(TESTS)
check: $(TESTS) check: $(TESTS)
$(TESTS): %: %.lama $(TESTS): %: %.lama
@echo "stdlib/regression/$@" @echo "stdlib/regression/$@"
@LAMA=../../runtime $(LAMAC) -I .. -ds -dp $< && $(ARCH) ./$@ > $@.log && diff $@.log orig/$@.log @LAMA=../../runtime $(LAMAC) -I .. -ds -dp $< && ./$@ > $@.log && diff $@.log orig/$@.log
clean: clean:
$(RM) test*.log *.s *~ $(TESTS) *.i $(RM) test*.log *.s *~ $(TESTS) *.i