sdlbomber/Makefile
Stefan Bühler d2e51f7389 Add datadir
2009-08-07 14:51:23 +02:00

30 lines
866 B
Makefile

#DBG = -g
CC = gcc
WARNFLAGS = -Wall -Wmissing-declarations -Wdeclaration-after-statement -Wcast-align -Winline -Wsign-compare -Wnested-externs -Wpointer-arith -Wformat-security
override CFLAGS += -D_REENTRANT -O2 $(shell sdl-config --cflags) $(DBG) $(WARNFLAGS)
.PHONY: all clean install
all: bomber
bomber: bomber.o gfx.o sound.o announce.o
gcc -o bomber bomber.o gfx.o sound.o announce.o $(shell sdl-config --libs) -lavahi-common -lavahi-client $(DBG)
matcher: matcher.c
bomber.o: bomber.c bomber.h gfx.h announce.h
gfx.o: gfx.c gfx.h bomber.h
sound.o: sound.c
announce.o: announce.c announce.h
clean:
rm -f *.o matcher bomber
install: bomber
echo "Installing into $(DESTDIR)"
mkdir -p "$(DESTDIR)/usr/bin/" "$(DESTDIR)/usr/share/sdlbomber/"
install -m 0755 bomber "$(DESTDIR)/usr/bin/"
install -m 0644 data/*.pcx "$(DESTDIR)/usr/share/sdlbomber/"