23 lines
348 B
Makefile
23 lines
348 B
Makefile
CC = cc
|
|
RM = rm -f
|
|
TARGETS = bin/blang
|
|
|
|
all: $(TARGETS)
|
|
|
|
clean:
|
|
$(RM) $(TARGETS)
|
|
|
|
build:
|
|
mkdir -p build
|
|
|
|
build/blang.o: build src/blang.c src/blang.h
|
|
$(CC) -c -o $@ src/blang.c
|
|
|
|
build/ops.o: build src/blang.h src/ops.c src/ops.h
|
|
$(CC) -c -o $@ src/ops.c
|
|
|
|
bin/blang: build/blang.o build/ops.o
|
|
$(CC) $(CFLAGS) -o $@ build/*.o
|
|
|
|
.PHONY: all clean
|