X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=blobdiff_plain;f=Makefile;h=08cc64b76ef9ffb46deb940599884bc13ed961ec;hb=fd7b604752c0ba03c347bc2ef3ee5a8c0759bff8;hp=561ff5d34c98d5d15594e196e062fa26bb64b4a5;hpb=fd189b9a43026a0efa22f0f1546e2c2cabb913d4;p=vrlugburz diff --git a/Makefile b/Makefile index 561ff5d..08cc64b 100644 --- a/Makefile +++ b/Makefile @@ -1,17 +1,21 @@ src = $(wildcard src/*.c) obj = $(src:.c=.o) dep = $(src:.c=.d) -bin = lugburz +bin = game #opt = -O3 dbg = -g warn = -pedantic -Wall def = -DMINIGLUT_USE_LIBC +inc = -Ilibs -Ilibs/treestore -Ilibs/drawtext +libdir = -Llibs/treestore -Llibs/imago -Llibs/drawtext CFLAGS = $(warn) $(opt) $(dbg) $(def) $(inc) -fcommon -MMD -LDFLAGS = -lGL -lX11 -lm +LDFLAGS = $(libdir) -ldrawtext -limago -ltreestore $(libgl) -lm -$(bin): $(obj) +libgl = -lGL -lX11 -lXext + +$(bin): $(obj) libs $(CC) -o $@ $(obj) $(LDFLAGS) -include $(dep) @@ -23,3 +27,11 @@ clean: .PHONY: cleandep cleandep: rm -f $(dep) + +.PHONY: libs +libs: + $(MAKE) -C libs + +.PHONY: clean-libs +clean-libs: + $(MAKE) -C libs clean