File: Makefile

package info (click to toggle)
supertransball2 1.5-12
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,352 kB
  • sloc: cpp: 5,665; makefile: 41
file content (35 lines) | stat: -rw-r--r-- 1,242 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
TARGET=supertransball2
OBJS := \
	auxiliar.o           configuration.o     encoder.o \
	enemies.o            fonts.o       	 game.o \
	main.o               maps.o              replays.o \
	state_changepack.o   state_chooseship.o  state_endsequence.o \
	state_game.o         state_gameover.o    state_instructions.o \
	state_interphase.o   state_keyredefinition.o \
	state_levelfinished.o state_logo.o       state_mainmenu.o \
	state_replay.o       state_replaymanager.o \
	state_typetext.o     tiles.o             transball.o \

all: $(TARGET)


%.o: %.cpp
	$(CXX) -c -g3 -O3 $< -o $@ $(CPPFLAGS) $(CFLAGS) `sdl-config --cflags` -I/usr/local/include/SDL

# dynamically linked binary:
$(TARGET): $(OBJS)
	$(CXX) $^ -o $@ $(LDFLAGS) `sdl-config --libs` -lSDL_image -lSDL_mixer -lSGE -I/usr/local/include/SDL
	mv ./$(TARGET) ..

clean:
	rm -f ../$(TARGET)
	rm -f *.o

install:
	install -m 755 ../$(TARGET) $(DESTDIR)/usr/games

install-data:
	install -m 644 ../demos/* $(DESTDIR)/usr/share/games/supertransball2/demos/
	install -m 644 ../sound/* $(DESTDIR)/usr/share/games/supertransball2/sound/
	cp -r ../maps/* $(DESTDIR)/usr/share/games/supertransball2/maps/
	install -m 644 ../graphics/* $(DESTDIR)/usr/share/games/supertransball2/graphics/