X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=blobdiff_plain;f=Makefile;h=159a11908f7fb723bf7052f7460253d7bb862ec8;hb=024e6f9e1a39a9617a737448b60b3ea95d513203;hp=af6c7bf254046bcc8e8b8926a94b2394c22d03da;hpb=787ad7856f5074db4fe805b15bfca61553895de1;p=summerhack diff --git a/Makefile b/Makefile index af6c7bf..159a119 100644 --- a/Makefile +++ b/Makefile @@ -9,11 +9,13 @@ obj = $(src:.cpp=.o) $(csrc:.c=.o) opt = -O1 opt = -g -CXXFLAGS = -ansi -pedantic -Wall $(opt) -Isrc/3dengfx/src -MMD `sdl-config --cflags` -CFLAGS = -std=c89 -pedantic -Wall $(opt) -MMD `sdl-config --cflags` -libs = src/3dengfx/lib3dengfx.a `sdl-config --libs` -lGL -lvorbisfile -ljpeg -lpng -lz +incdir = -Isrc/3dengfx/src -Ilibs -Ilibs/png -Ilibs/jpeglib -Ilibs/ogg -Ilibs/vorbis +CXXFLAGS = -ansi -pedantic -Wall $(opt) $(incdir) -MMD `sdl-config --cflags` +CFLAGS = -std=c89 -pedantic -Wall $(opt) $(incdir) -MMD `sdl-config --cflags` +libs = -Llibs src/3dengfx/lib3dengfx.a `sdl-config --libs` -lGL -lvorbis -logg \ + -ljpeg -lpng -lz -l3ds -$(bin): $(obj) 3dengfx +$(bin): $(obj) 3dengfx libs $(CXX) -o $@ $(obj) $(libs) .PHONY: 3dengfx @@ -30,9 +32,17 @@ $(bin): $(obj) 3dengfx clean: $(RM) $(obj) $(bin) -.PHONY: cleanall -cleanall: clean 3dengfx-clean cleandep +.PHONY: clean-all +clean-all: clean 3dengfx-clean cleandep clean-libs .PHONY: cleandep cleandep: $(RM) $(obj:.o=.d) + +.PHONY: libs +libs: + $(MAKE) -C libs + +.PHONY: clean-libs +clean-libs: + $(MAKE) -C libs clean