7 COMMOBJ
= main.o util.o parse.o abi.o cfg.o mem.o ssa.o alias.o load.o \
8 copy.o fold.o live.o spill.o rega.o emit.o
9 AMD64OBJ
= amd64
/targ.o amd64
/sysv.o amd64
/isel.o amd64
/emit.o
10 ARM64OBJ
= arm64
/targ.o arm64
/abi.o arm64
/isel.o arm64
/emit.o
11 RV64OBJ
= rv64
/targ.o rv64
/abi.o rv64
/isel.o rv64
/emit.o
12 OBJ
= $(COMMOBJ
) $(AMD64OBJ
) $(ARM64OBJ
) $(RV64OBJ
)
16 CFLAGS
= $(CPPFLAGS
) -Wall
-Wextra
-std
=c99
-g
-Wpedantic
19 $(CC
) $(LDFLAGS
) $(OBJ
) -o
$@
22 $(CC
) $(CFLAGS
) -c
$< -o
$@
25 $(AMD64OBJ
): amd64
/all.h
26 $(ARM64OBJ
): arm64
/all.h
27 $(RV64OBJ
): rv64
/all.h
35 echo
"#define Deftgt T_arm64_apple";\
38 echo
"#define Deftgt T_amd64_apple";\
45 echo
"#define Deftgt T_arm64"; \
48 echo
"#define Deftgt T_rv64"; \
51 echo
"#define Deftgt T_amd64_sysv";\
58 mkdir
-p
"$(DESTDIR)$(BINDIR)"
59 install -m755 qbe
"$(DESTDIR)$(BINDIR)/qbe"
62 rm -f
"$(DESTDIR)$(BINDIR)/qbe"
74 TARGET
=arm64 tools
/test.sh
all
77 TARGET
=rv64 tools
/test.sh
all
83 @for F in
$(SRCALL
); \
87 if (length(\$$0) > $@) \
88 printf(\"$$F:%d: %s\\n\", NR, \$$0); \
92 .PHONY
: clean clean-gen
check check-arm64 src
80 install uninstall