old-SuperVM/libvm/Makefile
2016-07-02 17:21:06 +02:00

35 lines
490 B
Makefile

CC = gcc
CFLAGS=-O3
all: svmln expdump emulator svmas
.PHONY: as clean run
svmln: svmln.c
$(CC) -g -o bin/$@ $^ $(CFLAGS)
expdump: expdump.c mnemonics.c disassembler.c
$(CC) -g -o bin/$@ $^ $(CFLAGS)
emulator: emulator.c vm.c
$(CC) -g -o bin/$@ $^ -lSDL $(CFLAGS)
svmas:
$(MAKE) -C as
test: exp
./exp -o test.exp $(ARGS)
hexdump -C test.exp
run: test.exp
./bin/emulator -dV $^
%.exp: %.bin
./bin/explink -o $@ -c $^
%.bin: %.asm
./bin/as -o $@ -L $^
clean:
rm *.bin