add flag for the number of leading jets excluded for random cones
[u/mrichter/AliRoot.git] / PWG4 / Makefile
1 PACKAGE = PWG4JetTasks
2
3 include Makefile.arch
4
5 ifndef PACKCXXFLAGS
6    PACKCXXFLAGS = $(CXXFLAGS)
7 endif
8
9 ALICEINC = -I.
10
11 ### define include dir for local case and par case
12 ifneq ($(STEERBase_INCLUDE),)
13   ALICEINC += -I../$(STEERBase_INCLUDE)
14 endif
15
16 ifneq ($(ESD_INCLUDE),)
17   ALICEINC += -I../$(ESD_INCLUDE)
18 endif
19
20 ifneq ($(AOD_INCLUDE),)
21   ALICEINC += -I../$(AOD_INCLUDE)
22 endif
23
24 ifneq ($(ANALYSIS_INCLUDE),)
25   ALICEINC += -I../$(ANALYSIS_INCLUDE)
26 endif
27
28 ifneq ($(ANALYSISalice_INCLUDE),)
29   ALICEINC += -I../$(ANALYSISalice_INCLUDE)
30 endif
31
32 ifneq ($(EventMixing_INCLUDE),)
33   ALICEINC += -I../$(EventMixing_INCLUDE)
34 endif
35
36 ifneq ($(JETAN_INCLUDE),)
37   ALICEINC += -I../$(JETAN_INCLUDE)
38 endif
39
40 ifneq ($(CORRFW_INCLUDE),)
41   ALICEINC += -I../$(CORRFW_INCLUDE)
42 endif
43
44 ifneq ($(PHOSUtils_INCLUDE),)
45   ALICEINC += -I../$(PHOSUtils_INCLUDE)
46   CXXFLAGS+=-D__PHOSUTIL__
47 endif
48
49 ifneq ($(EMCALUtils_INCLUDE),)
50   ALICEINC += -I../$(EMCALUtils_INCLUDE)
51   CXXFLAGS+=-D__EMCALUTIL__
52 endif
53
54 ifneq ($(PWG4PartCorrBase_INCLUDE),)
55   ALICEINC += -I../$(PWG4PartCorrBase_INCLUDE)
56 endif
57
58 ifneq ($(PWG4PartCorrDep_INCLUDE),)
59  ALICEINC += -I../$(PWG4PartCorrBase_INCLUDE) 
60  ALICEINC += -I../$(PWG4PartCorrDep_INCLUDE)
61 endif
62
63 ifneq ($(PWG4GammaConv_INCLUDE),)
64   ALICEINC += -I../$(PWG4GammaConv_INCLUDE)
65 endif
66
67 ifneq ($(PWG4JetTasks_INCLUDE),)
68   ALICEINC += -I../$(PWG4JetTasks_INCLUDE)
69 endif
70
71 ifneq ($(JETAN_INCLUDE),)
72   ALICEINC += -I../$(JETAN_INCLUDE)
73 endif
74
75 ifneq ($(PWG4JCORRAN_INCLUDE),)
76   ALICEINC += -I../$(PWG4JCORRAN_INCLUDE)
77 endif
78
79 # only if no par file was loaded before
80 #ifeq ($(ALICEINC),-I.)
81   ifneq ($(ALICE_ROOT),)
82     ALICEINC += -I$(ALICE_ROOT)/include
83     ALICEINC += -I$(ALICE_ROOT)/ANALYSIS
84     ALICEINC += -I$(ALICE_ROOT)/JETAN   # some extra includes
85     ALICEINC += -I$(ALICE_ROOT)/PHOS
86     ALICEINC += -I$(ALICE_ROOT)/EMCAL
87     ALICEINC += -I$(ALICE_ROOT)/PWG4/PartCorrBase
88   endif
89 #endif
90
91 CXXFLAGS += $(ALICEINC) -g
92
93 SRCS     = $(wildcard $(subst PWG4,,$(PACKAGE))/*.cxx)
94 HDRS     = $(SRCS:.cxx=.h)
95 DHDR     = $(PACKAGE)LinkDef.h
96
97 DHDR_PWG4 := $(DHDR)
98 HDRS_PWG4 := $(HDRS)
99 SRCS_PWG4 := $(SRCS) G__$(PACKAGE).cxx
100 OBJS_PWG4 := $(SRCS_PWG4:.cxx=.o)
101
102 PARFILE       = $(PACKAGE).par
103
104 lib$(PACKAGE).so: $(OBJS_PWG4)
105         @echo "Linking" $@ ...
106         @/bin/rm -f $@
107 ifeq ($(ARCH),macosx)
108         @$(LD) -bundle -undefined $(UNDEFOPT) $(LDFLAGS) $^ -o $@
109 else
110         @$(LD) $(SOFLAGS) $(LDFLAGS) $^ -o $@
111 endif
112         @chmod a+x $@
113         @echo "done"
114
115 %.o:    %.cxx %.h
116         $(CXX) $(PACKCXXFLAGS) -c $< -o $@
117
118 clean:
119         @rm -f $(OBJS) *.so G__$(PACKAGE).*
120
121 G__$(PACKAGE).cxx G__$(PACKAGE).h: $(HDRS) $(DHDR)
122         @echo "Generating dictionaries ..." $(ALICEINC)
123         rootcint -f $@ -c $(CINTFLAGS) $(ALICEINC) $^