Bring PIPEupgrade naming conventions in acc. with ITSU expectations
[u/mrichter/AliRoot.git] / STEER / Makefile
1 PACKAGE = invalid-only-for-proof
2
3 include Makefile.arch
4
5 SRCS     = $(wildcard *.cxx)
6 HDRS     = $(SRCS:.cxx=.h)
7 DHDR     = $(PACKAGE)LinkDef.h
8
9
10 ifndef PACKCXXFLAGS
11    PACKCXXFLAGS = $(CXXFLAGS)
12 endif
13
14 ALICEINC = -I.
15 ALICEINC += -I./$(PACKAGE)/
16
17 ifneq ($(ESD_INCLUDE),)
18    ALICEINC += -I../$(ESD_INCLUDE) 
19 endif
20
21 ifneq ($(AOD_INCLUDE),)
22    ALICEINC += -I../$(AOD_INCLUDE) 
23 endif
24
25 ifneq ($(STEERBase_INCLUDE),)
26    ALICEINC += -I../$(STEERBase_INCLUDE)
27 endif
28
29 # only if no par file was loaded before
30 #ifeq ($(ALICEINC),-I.)
31   ifneq ($(ALICE_ROOT),)
32     ALICEINC += -I$(ALICE_ROOT)/include
33   endif
34 #endif
35
36 ifeq ($(PLATFORM),macosx)
37 ROOTLIBDIR     := $(shell $(RC) --libdir)
38 ifeq ($(PACKAGE),STEERBase)
39    PACKLDFLAGS = -L$(ROOTLIBDIR)  -lVMC -lMinuit -lEG -lGeom
40 endif
41 ifeq ($(PACKAGE),ESD)
42    PACKLDFLAGS = $(STEERBase_LIBS) -L$(ROOTLIBDIR) -lVMC -lEG -lGeom
43 endif
44 ifeq ($(PACKAGE),AOD)
45    PACKLDFLAGS = $(STEERBase_LIBS) -L$(ROOTLIBDIR) -lEG -lGeom
46 endif
47 ifeq ($(PACKAGE),CDB)
48    PACKLDFLAGS = $(STEERBase_LIBS) -L$(ROOTLIBDIR) -lMinuit -lTree -lXMLParser
49 endif
50 endif
51
52
53 CXXFLAGS += $(ALICEINC) -g
54
55 SRCS         += G__$(PACKAGE).cxx
56 OBJS          = $(SRCS:.cxx=.o)
57
58 lib$(PACKAGE).so: $(OBJS)
59         @echo "Linking" $@ ...
60         @/bin/rm -f $@
61 ifeq ($(PLATFORM),macosx)
62         $(LD) $(SOFLAGS)$@ $(LDFLAGS) $^ $(OutPutOpt) $@ $(PACKLDFLAGS) $(EXPLLINKLIBS)
63 else
64         $(LD) $(SOFLAGS) $(LDFLAGS) $^ $(OutPutOpt) $@ $(PACKLDFLAGS) $(EXPLLINKLIBS)
65 endif
66         @chmod a+x $@
67         @echo "done"
68
69 %.o:    %.cxx %.h
70         $(CXX) $(PACKCXXFLAGS) -c $< -o $@
71
72 clean:
73         @rm -f $(OBJS) *.so G__$(PACKAGE).*
74
75 G__$(PACKAGE).cxx G__$(PACKAGE).h: $(HDRS) $(DHDR)
76         @echo "Generating dictionaries ..." $(ALICEINC)
77         rootcint -f $@ -c $(CINTFLAGS) $(ALICEINC) $^
78