eobish
annotate Makefile @ 8:c0e8bbf96849
merged
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Mon, 19 Jan 2015 15:49:36 +0200 |
parents | cdbcae5b3b98 |
children |
rev | line source |
---|---|
nuclear@0 | 1 csrc = $(wildcard src/*.c) |
nuclear@0 | 2 ccsrc = $(wildcard src/*.cc) |
nuclear@0 | 3 obj = $(csrc:.c=.o) $(ccsrc:.cc=.o) |
nuclear@0 | 4 bin = eobish |
nuclear@0 | 5 |
nuclear@2 | 6 warn = -pedantic -Wall |
nuclear@2 | 7 opt = -O0 |
nuclear@2 | 8 dbg = -g |
nuclear@2 | 9 def = -DFBLIB_SDL |
nuclear@2 | 10 |
nuclear@6 | 11 ifeq ($(shell uname -s), Darwin) |
nuclear@6 | 12 def += -Dmain=SDL_main |
nuclear@6 | 13 endif |
nuclear@6 | 14 |
nuclear@2 | 15 CFLAGS = $(warn) $(opt) $(dbg) $(def) `pkg-config --cflags sdl` |
nuclear@0 | 16 CXXFLAGS = $(CFLAGS) |
nuclear@0 | 17 LDFLAGS = `pkg-config --libs sdl` |
nuclear@0 | 18 |
nuclear@0 | 19 $(bin): $(obj) |
nuclear@0 | 20 $(CXX) -o $@ $(obj) $(LDFLAGS) |
nuclear@0 | 21 |
nuclear@0 | 22 .PHONY: clean |
nuclear@0 | 23 clean: |
nuclear@0 | 24 rm -f $(obj) $(bin) |
nuclear@0 | 25 |
nuclear@0 | 26 .PHONY: data |
nuclear@0 | 27 data: |
nuclear@0 | 28 $(MAKE) -C orig_data |