X-Git-Url: https://git.danieliu.xyz/?a=blobdiff_plain;f=makefile;h=e77e68612188192afc7a3f569e2910a437bec51c;hb=6cf67300c03d92a9cc0c5888b33cdb21a852eb69;hp=d83be28702ff5e43df3ae749d8c30b652f78ff7a;hpb=4c9d6b68e0b493e23969b79e96457b68cfed8895;p=sped.git diff --git a/makefile b/makefile index d83be28..e77e686 100644 --- a/makefile +++ b/makefile @@ -1,13 +1,17 @@ +CC=gcc +CFLAGS=-m32 -no-pie +ASM=nasm +ASMFLAGS=-f elf32 -g .PHONY: clean make: sped -sped.o: sped.asm - nasm -f elf32 $^ -o $@ +%.o: %.asm + $(ASM) $(ASMFLAGS) -o $@ $^ -sped: sped.o - ld -m elf_i386 $^ -o $@ +sped: sped.o fileutils.o repl.o utils.o + $(CC) $(CFLAGS) -o $@ $^ clean: rm sped *.o