3 CFLAGS = -Wall -pedantic
4 CFLAGS += -I../inc_priv -I../inc_pub
5 CFLAGS += `pkg-config --cflags lua sdl`
7 CFLAGS += '-DAE_SEARCH_PATH_SHARE="/usr//share/aesthe"'
8 #CFLAGS += -DDEBUG_FLAG
10 LDFLAGS = -lm -lGL -lGLU
11 LDFLAGS += `pkg-config --libs lua5.1 sdl`
14 OBJS = ae_common.o ae_algebra.o ae_list.o ae_kernel.o ae_render.o ae_engine.o ae_console.o ae_image.o ae_texture.o ae_eximport.o ae_net.o ae_main.o
18 #all: usage build valgrind
21 ######################### Usage #########################
22 # make all - builds aesthe #
23 # make clean - cleans *.o and binary #
24 # make run - runs Aesthe #
25 # make runexamples - runs Aesthe with examples #
26 #########################################################
27 # To build Aesthe you need have installed: #
28 # 1. liblua version 5.1 (development package) #
29 # 2. SDL (development package) #
30 # 3. pkg-config installed and properly configured #
31 #########################################################
34 # --- Build targets: ---
39 $(CC) $(LDFLAGS) -o $(PROJECT) $(OBJS) $(LDLIBS)
44 $(CC) -c $(CFLAGS) $< -o $@
47 rm -f $(PROJECT) $(OBJS)
50 # --- Run targets: ---
56 cd ..; bin/$(PROJECT) -d1024x768 -sexample/examples
59 cd ..; ltrace bin/$(PROJECT) 2>&1 | grep gl
62 #cd ..; valgrind --tool=massif bin/$(PROJECT) 2>&1
63 cd ..; valgrind --tool=memcheck bin/$(PROJECT) 2>&1
66 # --- Other targets: ---
69 cd ..; bin/$(PROJECT) -sdoc 2>/dev/null > doc/help.dpp
73 cd ..; mkdir -p archive
74 cd ..; tar c '--exclude=*.svn*' inc_priv inc_pub src image script model/example doc win32/Makefile win32/*.bat win32/LICENSE* Makefile README LICENSE | gzip > archive/$(PROJECT)_`date '+%Y-%m-%d_%H-%M-%S'`.tgz
76 VERSION=`grep VERSION ../inc_priv/ae_common.h | sed -e 's/^[^"]*"\(.*\)\".*/\1/' | tr '.' '-'`
78 tar c -C ../.. '--exclude=*.svn*' aesthe/inc_priv aesthe/inc_pub aesthe/src aesthe/image aesthe/script aesthe/model/example aesthe/doc aesthe/win32/Makefile aesthe/Makefile aesthe/README aesthe/LICENSE | gzip > ../$(PROJECT)_$(VERSION)_unix_source.tgz