Makefile for small HLT programs created.
[u/mrichter/AliRoot.git] / HLT / programs / Makefile
CommitLineData
585caa43 1#$Id$
2###############################
3# Makefile for HLT programs. #
4# #
5# Author: Constantin Loizides #
6###############################
7
8ifndef USEPACKAGE
9#USEPACKAGE = ROOT
10USEPACKAGE = ALIROOT
11endif
12
13#used if USEPACKAGE=anything else
14DEFSTR = -Dno_root
15
16CXX = g++
17LD = g++
18CXXFLAGS = -O2 -Wall
19LDFLAGS = -O2
20
21ifndef TOPDIR
22TOPDIR = $(HOME)/level3code
23endif
24ifndef LIBDIR
25LIBDIR = $(LEVEL3)/lib_$(USERNAME)
26endif
27
28ROOTCFLAGS := $(shell root-config --cflags)
29ROOTLIBS := $(shell root-config --libs)
30ROOTGLIBS := $(shell root-config --glibs)
31
32ifeq ($(USEPACKAGE),ROOT)
33DEFSTR = -Duse_root
34INCLUDES = -I$(ROOTSYS)/include
35RLIBS = $(ROOTLIBS) -lMinuit -lEG
36endif
37
38ifeq ($(USEPACKAGE),ALIROOT)
39DEFSTR = -Duse_aliroot
40ALICELIBS = -L$(ALICE_ROOT)/lib -lCONTAINERS -lTPC -lSTEER
41#ALICELIBS := $(shell aliroot-config --libs)
42INCLUDES = -I$(ROOTSYS)/include -I$(ALICE_ROOT)/include/ -I$(ALICE_ROOT)/TPC -I$(ALICE_ROOT)/CONTAINERS -I$(ALICE_ROOT)/STEER
43RLIBS = $(ROOTLIBS) -lMinuit -lEG
44endif
45
46#Save the particle id's
47#DEFSTR += -Ddo_mc
48
49#Use logging classes
50#DEFSTR += -Duse_logging
51
52ifdef MLUCDIR
53INCLUDES += -I$(MLUCDIR)/include
54MLUCLIBS = -L$(MLUCDIR)/lib/linux-i386 -lMLUC
55else
56INCLUDES += -I/prog/alice/level3/kip/MLUC/include
57MLUCLIBS += -L/prog/alice/level3/kip/MLUC/lib/linux-i386 -lMLUC
58endif
59
60INCLUDES += -I$(TOPDIR)/hough -I$(TOPDIR)/src -I$(TOPDIR)/comp -I$(TOPDIR)/misc
61LIBS = -L$(LIBDIR) -lAliL3 -lAliL3Hough -lAliL3Comp -lAliL3Misc $(MLUCLIBS) $(ALICELIBS) $(RLIBS)
62
63CXXFLAGS = -O2 -Wall -ggdb $(INCLUDES)
64LDFLAGS = -O2 $(LIBS)
65
66
67PRGS = runit
68
69
70
71all : $(PRGS)
72
73runit : runit.o $(OBJS)
74 $(LD) runit.o $(LDFLAGS) $(OBJS) -o runit
75
76
77all : $(OBJDIR) $(PRGS)
78
79%.o : %.cxx
80 $(CXX) $(CXXFLAGS) $(DEFSTR) -c $(INCLUDES) -o $@ $<
81
82
83clean :
84 rm -f *.o $(PRGS)
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115