X-Git-Url: https://git.danieliu.xyz/?a=blobdiff_plain;f=makefile;h=18c299ff636dcfe6d8d8d99f3c3eaba095ccb46b;hb=89732d399de9007aaf2894b0c637e8cfb9ed47ac;hp=d83be28702ff5e43df3ae749d8c30b652f78ff7a;hpb=4c9d6b68e0b493e23969b79e96457b68cfed8895;p=sped.git diff --git a/makefile b/makefile index d83be28..18c299f 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 + $(CC) $(CFLAGS) -o $@ $^ clean: rm sped *.o