libcatwalk/Makefile

25 lines
462 B
Makefile

CC = gcc
FLAGS = -Wall -fpic
LFLAGS = -s
all: bin/libcatwalk.so
bin/libcatwalk.so: obj/directions.o obj/grid.o obj/indicators.o obj/route.o
-@mkdir -p $(@D)
$(CC) -shared -o $@ $(FLAGS) $^ $(LFLAGS)
obj/%.o: src/%.c
-@mkdir -p $(@D)
$(CC) -o $@ -c $(FLAGS) $<
obj/directions.o: src/directions.c
obj/grid.o: src/grid.c
obj/indicators.o: src/indicators.c
obj/route.o: src/route.c
.PHONY: clean mrproper
clean:
rm -rf obj
mrproper: clean
rm -rf bin