updated for vertex study
[u/mrichter/AliRoot.git] / PWGHF / Makefile
1 # $Id$
2
3 PACKAGE = PWGHF
4
5 include Makefile.arch
6
7 ALICEINC      = -I.
8
9 ### define include dir for local case and par case
10 ifneq ($(ESD_INCLUDE),)
11    ALICEINC += -I../$(ESD_INCLUDE)
12         ifneq ($(STEERBase_INCLUDE),)
13                 ALICEINC += -I../$(STEERBase_INCLUDE)
14         endif                           
15         ifneq ($(CDB_INCLUDE),)
16                 ALICEINC += -I../$(CDB_INCLUDE)
17         endif                           
18         ifneq ($(AOD_INCLUDE),)
19                 ALICEINC += -I../$(AOD_INCLUDE)
20         endif
21         ifneq ($(ANALYSIS_INCLUDE),)
22                 ALICEINC += -I../$(ANALYSIS_INCLUDE)
23         endif
24         ifneq ($(ANALYSISalice_INCLUDE),)
25                 ALICEINC += -I../$(ANALYSISalice_INCLUDE)
26         endif
27         ifneq ($(CORRFW_INCLUDE),)
28                 ALICEINC += -I../$(CORRFW_INCLUDE)
29         endif
30         ifneq ($(CORRFW_INCLUDE),)
31                 ALICEINC += -I../$(CORRFW_INCLUDE)
32         endif
33         ifneq ($(PWGHFvertexingHF_INCLUDE),)
34                 ALICEINC += -I../$(PWGHFvertexingHF_INCLUDE)
35         endif
36         ifneq ($(PWGflowBase_INCLUDE),)
37                 ALICEINC += -I../$(PWGflowBase_INCLUDE)
38         endif
39         ifneq ($(PWGflowTasks_INCLUDE),)
40                 ALICEINC += -I../$(PWGflowTasks_INCLUDE)
41         endif
42 else
43   ifneq ($(ALICE_ROOT),)
44     ALICEINC += -I$(ALICE_ROOT)/include -I$(ALICE_ROOT)/PWGHF/base -I$(ALICE_ROOT)/PWGHF/vertexingHF -I$(ALICE_ROOT)/PWGHF/hfe -I$(ALICE_ROOT)/PWG/FLOW/Base -I$(ALICE_ROOT)/PWG/FLOW/Tasks
45   else
46   endif
47 endif
48
49 SRCS     = $(wildcard $(subst PWGHF,,$(PACKAGE))/*.cxx)
50 HDRS     = $(SRCS:.cxx=.h)
51 DHDR     = $(PACKAGE)LinkDef.h
52 CXXFLAGS     += $(ALICEINC) -g
53
54 DHDR_PWGHF := $(DHDR)
55 HDRS_PWGHF := $(HDRS)
56 SRCS_PWGHF := $(SRCS) G__$(PACKAGE).cxx
57 OBJS_PWGHF := $(SRCS_PWGHF:.cxx=.o)
58
59 PARFILE       = $(PACKAGE).par
60
61 lib$(PACKAGE).so: $(OBJS_PWGHF)
62         @echo "Linking" $@ ...
63         @/bin/rm -f $@
64 ifeq ($(PLATFORM),macosx)
65         $(LD) $(SOFLAGS) -flat_namespace -undefined suppress $(LDFLAGS) $^ $(OutPutOpt) $@ $(EXPLLINKLIBS)
66 else
67         $(LD) $(SOFLAGS) $(LDFLAGS) $^ $(OutPutOpt) $@ $(EXPLLINKLIBS)
68 endif
69         @chmod a+x $@
70         @echo "done"
71
72 %.o:    %.cxx %.h
73         $(CXX) $(CXXFLAGS) -c $< -o $@
74
75 G__$(PACKAGE).cxx G__$(PACKAGE).h: $(HDRS) $(DHDR)
76         @echo "Generating dictionary ..."
77         rootcint -f $@ -c $(ALICEINC) $^
78
79 clean:
80         @rm -f $(OBJS)  *.so G__$(PACKAGE).*  $(PARFILE)