Merge branch 'master' of https://git.cern.ch/reps/AliRoot
[u/mrichter/AliRoot.git] / PWGPP / 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 ($(PWGPPevchar_INCLUDE),)
18    ALICEINC += -I../$(PWGPPevchar_INCLUDE) 
19 endif
20
21 ifneq ($(PWGPPpid_INCLUDE),)
22    ALICEINC += -I../$(PWGPPpid_INCLUDE)
23 endif
24
25 # only if no par file was loaded before
26 #ifeq ($(ALICEINC),-I.)
27   ifneq ($(ALICE_ROOT),)
28     ALICEINC += -I$(ALICE_ROOT)/include -I$(ALICE_ROOT)/ITS
29   endif
30 #endif
31
32 ifneq ($(EINCLUDE),)
33   ALICEINC += $(EINCLUDE:%=-I$(ALICE_ROOT)/%)
34 endif
35
36
37 CXXFLAGS += $(ALICEINC) -g
38
39 SRCS         += G__$(PACKAGE).cxx
40 OBJS          = $(SRCS:.cxx=.o)
41
42 lib$(PACKAGE).so: $(OBJS)
43         @echo "Linking" $@ ...
44         @/bin/rm -f $@
45         $(LD) $(SOFLAGS) $(LDFLAGS) $^ $(OutPutOpt) $@ $(EXPLLINKLIBS)
46         @chmod a+x $@
47         @echo "done"
48
49 %.o:    %.cxx %.h
50         $(CXX) $(PACKCXXFLAGS) -c $< -o $@
51
52 clean:
53         @rm -f $(OBJS) *.so G__$(PACKAGE).*
54
55 G__$(PACKAGE).cxx G__$(PACKAGE).h: $(HDRS) $(DHDR)
56         @echo "Generating dictionaries ..." $(ALICEINC)
57         rootcint -f $@ -c $(CINTFLAGS) $(ALICEINC) $^
58