Adding includes for EMCAL_Utils and OADB PATH (A. Shabetai)
[u/mrichter/AliRoot.git] / JETAN / Makefile
1 PACKAGE = invalid-only-for-proof
2
3 include $(ROOTSYS)/test/Makefile.arch
4
5 SRCS     = $(wildcard *.cxx)
6 HDRS     = $(SRCS:.cxx=.h)
7 DHDR     = $(PACKAGE)LinkDef.h
8
9
10 ALICEINC      = -I.
11
12 ### define include dir for local case and par case
13 ifneq ($(OADB_PATH),)
14    ALICEINC += -I../$(OADB_PATH)
15 endif
16 ifneq ($(EMCALUtils_INCLUDE),)
17    ALICEINC += -I../$(EMCALUtils_INCLUDE)
18 endif
19 ifneq ($(JETAN_INCLUDE),)
20   ifneq ($(FASTJET_ROOT),)
21    ALICEINC += -I$(FASTJET_ROOT)/include
22   else
23    ALICEINC += -I$(ALICE_ROOT)/JETAN/fastjet
24   endif
25 endif
26 ifneq ($(ESD_INCLUDE),)
27    ALICEINC += -I../$(ESD_INCLUDE)
28    ALICEINC += -I../$(AOD_INCLUDE)
29    ALICEINC += -I../$(STEERBase_INCLUDE)
30    ALICEINC += -I../$(ANALYSIS_INCLUDE)
31    ALICEINC += -I../$(ANALYSISalice_INCLUDE)
32    ifneq ($(JETAN_INCLUDE),)    
33      ALICEINC += -I../$(JETAN_INCLUDE)
34    endif
35  else
36     ifneq ($(ALICE_ROOT),)
37        ALICEINC += -I$(ALICE_ROOT)/include -I$(ALICE_ROOT)/JETAN -I$(ALICE_ROOT)/ANALYSIS
38      endif
39 endif
40
41 CXXFLAGS     += $(ALICEINC) -g
42
43
44 SRCS         += G__$(PACKAGE).cxx
45 OBJS          = $(SRCS:.cxx=.o)
46
47 lib$(PACKAGE).so: $(OBJS)
48         @echo "Linking" $@ ...
49         @/bin/rm -f $@
50 ifeq ($(ARCH),macosx)
51         @$(LD) -bundle -undefined $(UNDEFOPT) $(LDFLAGS) $^ -o $@
52 else
53         @$(LD) $(SOFLAGS) $(LDFLAGS) $^ -o $@
54 endif
55         @chmod a+x $@
56         @echo "done"
57
58 %.o:    %.cxx %.h
59         $(CXX) $(CXXFLAGS) -c $< -o $@
60
61 clean:
62         @rm -f $(OBJS) *.so G__$(PACKAGE).*
63
64 G__$(PACKAGE).cxx G__$(PACKAGE).h: $(HDRS) $(DHDR)
65         @echo "Generating dictionary ..."
66         rootcint -f $@ -c $(CINTFLAGS) $(ALICEINC) $^
67