Makefile 517 Bytes
Newer Older
Cedric Roux's avatar
Cedric Roux committed
1
CC=gcc
2
CFLAGS=-Wall -g -pthread -DT_TRACER
3

4
#CFLAGS += -O3 -ffast-math -fomit-frame-pointer
Cedric Roux's avatar
Cedric Roux committed
5

6
LIBS=-lX11 -lm
Cedric Roux's avatar
Cedric Roux committed
7
8
9
10
11
12

#comment those two lines to NOT use shared memory
CFLAGS += -DT_USE_SHARED_MEMORY
LIBS += -lrt

PROG=tracer
Cedric Roux's avatar
Cedric Roux committed
13
OBJS=main.o plot.o database.o forward.o gui.o
Cedric Roux's avatar
Cedric Roux committed
14

Cedric Roux's avatar
Cedric Roux committed
15
16
$(PROG): gui/gui.a $(OBJS)
	$(CC) $(CFLAGS) -o $(PROG) $(OBJS) gui/gui.a $(LIBS)
Cedric Roux's avatar
Cedric Roux committed
17
18

.PHONY: gui/gui.a
Cedric Roux's avatar
Cedric Roux committed
19

20
21
22
gui/gui.a:
	cd gui && make

Cedric Roux's avatar
Cedric Roux committed
23
24
25
26
27
28
29
%.o: %.c
	$(CC) $(CFLAGS) -c -o $@ $<

main.o: ../T_IDs.h ../T_defs.h

clean:
	rm -f *.o $(PROG) core
30
	cd gui && make clean