This repository has been archived on 2024-01-18. You can view files and clone it, but cannot push or open issues or pull requests.
compilation/flap/questions/retrolixToX86_64/Makefile
2024-01-01 10:48:42 +01:00

26 lines
541 B
Makefile

FLAP = ../../_build/default/src/flap.exe
TARGET = retrolix
main:
@echo make interpret
@echo make compilo
build:
@cd ../.. && dune build --display=quiet
interpret: build
@for f in $(wildcard *.$(TARGET)); do \
printf "%s: " $$f; \
./$(FLAP) -s $(TARGET) -d true -r true $$f; \
printf "\n"; \
done
compilo: build
@for f in $(wildcard *.$(TARGET)); do \
printf "%s: " $$f; \
./$(FLAP) -t x86-64 $$f && \
gcc -no-pie -o $${f%.*}.elf $${f%.*}.s runtime.c && \
./$${f%.*}.elf; \
rm $${f%.*}.s; \
printf "\n"; \
done