Added fVersion field to differentiate the old and new config version.
[u/mrichter/AliRoot.git] / HLT / hough / Makefile
CommitLineData
e998e586 1#$Id$
2###########################
3# Makefile for HLT code. #
4# #
5# Author: Anders Vestbo #
6###########################
4de874d1 7
71e6af6c 8ifndef USEPACKAGE
b5a207b4 9#USEPACKAGE = ROOT
10USEPACKAGE = ALIROOT
71e6af6c 11endif
b5a207b4 12
71e6af6c 13#used if USEPACKAGE=anything else
e2e0cb81 14DEFSTR = -Dno_root
15
c05bc6c5 16CXX = g++
17LD = g++
18CXXFLAGS = -O2 -Wall -fPIC
19LDFLAGS = -O2
20SOFLAGS = -shared
4de874d1 21
71e6af6c 22ifndef TOPDIR
c05bc6c5 23TOPDIR = $(HOME)/level3code
71e6af6c 24endif
25ifndef LIBDIR
e998e586 26LIBDIR = $(LEVEL3)/lib_$(USERNAME)
71e6af6c 27endif
28OBJDIR = lib
4de874d1 29
b5a207b4 30ifeq ($(USEPACKAGE),ROOT)
31INCLUDES = -I$(ROOTSYS)/include -I$(TOPDIR)/hough -I$(TOPDIR)/src -I$(TOPDIR)/comp
e2e0cb81 32DEFSTR = -Duse_root
b5a207b4 33endif
34
35ifeq ($(USEPACKAGE),ALIROOT)
36INCLUDES = -I$(ROOTSYS)/include -I$(TOPDIR)/hough -I$(TOPDIR)/src -I$(TOPDIR)/comp -I$(ALICE_ROOT)/include/ -I$(ALICE_ROOT)/TPC -I$(ALICE_ROOT)/CONTAINERS -I$(ALICE_ROOT)/STEER
e2e0cb81 37DEFSTR = -Duse_aliroot -Duse_root
b5a207b4 38endif
39
e2e0cb81 40#Save the particle id's
41#DEFSTR += -Ddo_mc
42
71e6af6c 43#Use logging classes
b419a833 44ifndef NOLOGGING
71e6af6c 45DEFSTR += -Duse_logging
b419a833 46endif
71e6af6c 47
48ifdef MLUCDIR
49INCLUDES += -I$(MLUCDIR)/include
50else
51INCLUDES += -I/prog/alice/level3/kip/MLUC/include
52endif
53
c05bc6c5 54SRCS = AliL3HoughTransformer.cxx AliL3Hough.cxx AliL3HoughTrack.cxx\
55 AliL3HoughMaxFinder.cxx AliL3HoughEval.cxx AliL3HoughMerger.cxx \
56 AliL3Histogram.cxx AliL3Histogram1D.cxx \
c3ebc415 57 AliL3HoughIntMerger.cxx AliL3HoughGlobalMerger.cxx
4de874d1 58
c05bc6c5 59DICT = AliL3HoughCint.cxx
60DICTH = AliL3HoughCint.h
61DICTO = $(OBJDIR)/AliL3HoughCint.o
4de874d1 62
c3ebc415 63ifeq ($(USEPACKAGE),ROOT)
c05bc6c5 64HDRS = $(SRCS:.cxx=.h) AliL3HoughLinkDef.h
c05bc6c5 65OBJS = $(patsubst %.cxx,$(OBJDIR)/%.o,$(SRCS)) $(DICTO)
c3ebc415 66endif
67
68ifeq ($(USEPACKAGE),ALIROOT)
69HDRS = $(SRCS:.cxx=.h) GetGoodParticles.h AliL3HoughLinkDef.h
70OBJS = $(patsubst %.cxx,$(OBJDIR)/%.o,$(SRCS)) $(OBJDIR)/GetGoodParticles.o $(DICTO)
71endif
9f33a1db 72
e998e586 73LEVELSO = $(LIBDIR)/libAliL3Hough.so
4de874d1 74
cc4d912a 75all : $(OBJDIR) $(LIBDIR) $(LEVELSO)
4de874d1 76
c05bc6c5 77$(LEVELSO) : $(OBJS)
78 $(LD) $(SOFLAGS) $(LDFLAGS) $^ -o $@
4de874d1 79
c05bc6c5 80$(DICT) : $(HDRS)
81 @echo "Generating dictionary..."
b5a207b4 82 @rootcint -f $(DICT) -c $(INCLUDES) $(HDRS)
4de874d1 83
4de874d1 84
c05bc6c5 85$(OBJDIR)/%.o : %.cxx
e2e0cb81 86 $(CXX) $(CXXFLAGS) $(DEFSTR) -c $(INCLUDES) -o $@ $<
4de874d1 87
c05bc6c5 88$(OBJDIR) :
89 test ! -e $(OBJDIR) && mkdir -p $(OBJDIR)
cc4d912a 90$(LIBDIR) :
91 test ! -e $(LIBDIR) && mkdir -p $(LIBDIR)
4de874d1 92
c05bc6c5 93clean :
94 rm -f $(OBJDIR)/*.o
e998e586 95 rm -f $(LIBDIR)/libAliL3Hough.so
96 rm $(DICT) $(DICTH)
97
98so:
99 rm -f $(LIBDIR)/libAliL3Hough.so