annotate trix/Makefile @ 21:bef3b1af6326

trix - package for arch
author Przemyslaw <prymula76@outlook.com>
date Sun, 31 Mar 2024 22:14:33 +0200
parents 2787f5e749ae
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
prymula <prymula76@outlook.com>
parents:
diff changeset
1 APP_BIN=trix
prymula <prymula76@outlook.com>
parents:
diff changeset
2 OBJF = ./src/main.o \
prymula <prymula76@outlook.com>
parents:
diff changeset
3 ./src/menu.o \
prymula <prymula76@outlook.com>
parents:
diff changeset
4 ./src/game.o
prymula <prymula76@outlook.com>
parents:
diff changeset
5
prymula <prymula76@outlook.com>
parents:
diff changeset
6
prymula <prymula76@outlook.com>
parents:
diff changeset
7 LIBS=sdl2 SDL2_ttf SDL2_image
prymula <prymula76@outlook.com>
parents:
diff changeset
8
prymula <prymula76@outlook.com>
parents:
diff changeset
9 #CXXFLAGS += -I./ -I Sources
prymula <prymula76@outlook.com>
parents:
diff changeset
10
prymula <prymula76@outlook.com>
parents:
diff changeset
11 PACKAGES = $(LIBS)
prymula <prymula76@outlook.com>
parents:
diff changeset
12 # CXXFLAGS += `pkg-config --cflags $(PACKAGES)` -mthreads
prymula <prymula76@outlook.com>
parents:
diff changeset
13 CFLAGS += -g -Wall `pkg-config --cflags $(PACKAGES)` -DLINUX
prymula <prymula76@outlook.com>
parents:
diff changeset
14 #LDFLAGS += -ldl
prymula <prymula76@outlook.com>
parents:
diff changeset
15 PREFIX = /usr
prymula <prymula76@outlook.com>
parents:
diff changeset
16
prymula <prymula76@outlook.com>
parents:
diff changeset
17 all: $(APP_BIN)
prymula <prymula76@outlook.com>
parents:
diff changeset
18
prymula <prymula76@outlook.com>
parents:
diff changeset
19 $(APP_BIN): $(OBJF)
prymula <prymula76@outlook.com>
parents:
diff changeset
20 $(CC) $(CXXFLAGS) $(OBJF) -o $(APP_BIN) `pkg-config --libs $(PACKAGES)` -g $(EXTRA_LIBS)
prymula <prymula76@outlook.com>
parents:
diff changeset
21
prymula <prymula76@outlook.com>
parents:
diff changeset
22 clean:
prymula <prymula76@outlook.com>
parents:
diff changeset
23 rm -f $(OBJF) $(APP_BIN)
prymula <prymula76@outlook.com>
parents:
diff changeset
24
prymula <prymula76@outlook.com>
parents:
diff changeset
25 %.o : %.C
prymula <prymula76@outlook.com>
parents:
diff changeset
26 $(CC) $(CFLAGS) -c $< -o $@
prymula <prymula76@outlook.com>
parents:
diff changeset
27
prymula <prymula76@outlook.com>
parents:
diff changeset
28 install:
21
bef3b1af6326 trix - package for arch
Przemyslaw <prymula76@outlook.com>
parents: 0
diff changeset
29 install -d $(DESTDIR)$(PREFIX)/bin $(DESTDIR)$(PREFIX)/share/trix $(DESTDIR)$(PREFIX)/share/trix/img $(DESTDIR)$(PREFIX)/share/trix/img/bg
bef3b1af6326 trix - package for arch
Przemyslaw <prymula76@outlook.com>
parents: 0
diff changeset
30 install trix $(DESTDIR)$(PREFIX)/bin
bef3b1af6326 trix - package for arch
Przemyslaw <prymula76@outlook.com>
parents: 0
diff changeset
31 install ZapfHumanist.ttf $(DESTDIR)$(PREFIX)/share/trix
bef3b1af6326 trix - package for arch
Przemyslaw <prymula76@outlook.com>
parents: 0
diff changeset
32 install img/*.bmp $(DESTDIR)$(PREFIX)/share//trix/img
bef3b1af6326 trix - package for arch
Przemyslaw <prymula76@outlook.com>
parents: 0
diff changeset
33 install img/bg/*.txt $(DESTDIR)$(PREFIX)/share/trix/img/bg
bef3b1af6326 trix - package for arch
Przemyslaw <prymula76@outlook.com>
parents: 0
diff changeset
34 install img/bg/*.jpeg $(DESTDIR)$(PREFIX)/share/trix/img/bg
bef3b1af6326 trix - package for arch
Przemyslaw <prymula76@outlook.com>
parents: 0
diff changeset
35 install img/*.png $(DESTDIR)$(PREFIX)/share/trix/img
bef3b1af6326 trix - package for arch
Przemyslaw <prymula76@outlook.com>
parents: 0
diff changeset
36 install Trix.desktop $(DESTDIR)/usr/share/applications
0
prymula <prymula76@outlook.com>
parents:
diff changeset
37
prymula <prymula76@outlook.com>
parents:
diff changeset
38
prymula <prymula76@outlook.com>
parents:
diff changeset
39 uninstall:
prymula <prymula76@outlook.com>
parents:
diff changeset
40 rm $(PREFIX)/bin/trix
prymula <prymula76@outlook.com>
parents:
diff changeset
41 rm -r $(PREFIX)/share/trix
prymula <prymula76@outlook.com>
parents:
diff changeset
42 rm /usr/share/applications/Trix.desktop
prymula <prymula76@outlook.com>
parents:
diff changeset
43
prymula <prymula76@outlook.com>
parents:
diff changeset
44
prymula <prymula76@outlook.com>
parents:
diff changeset
45
prymula <prymula76@outlook.com>
parents:
diff changeset
46 # EOF #
prymula <prymula76@outlook.com>
parents:
diff changeset
47