fix memory leak and funny multiplicity
[u/mrichter/AliRoot.git] / JETAN / Makefile
1 PACKAGE = invalid-only-for-proof
2
3 include $(ROOTSYS)/test/Makefile.arch
4 include lib$(PACKAGE).pkg
5
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    ALICEINC += -I../$(AOD_INCLUDE)
13    ALICEINC += -I../$(STEERBase_INCLUDE)
14    ALICEINC += -I../$(ANALYSIS_INCLUDE)
15    ALICEINC += -I../$(ANALYSISalice_INCLUDE)
16  else
17     ifneq ($(ALICE_ROOT),)
18        ALICEINC += -I$(ALICE_ROOT)/include
19      endif
20 endif
21
22 CXXFLAGS     += $(ALICEINC) -g
23
24
25 SRCS         += G__$(PACKAGE).cxx
26 OBJS          = $(SRCS:.cxx=.o)
27
28 lib$(PACKAGE).so: $(OBJS)
29         @echo "Linking" $@ ...
30         @/bin/rm -f $@
31 ifeq ($(ARCH),macosx)
32         @$(LD) -bundle -undefined $(UNDEFOPT) $(LDFLAGS) $^ -o $@
33 else
34         @$(LD) $(SOFLAGS) $(LDFLAGS) $^ -o $@
35 endif
36         @chmod a+x $@
37         @echo "done"
38
39 %.o:    %.cxx %.h
40         $(CXX) $(CXXFLAGS) -c $< -o $@
41
42 clean:
43         @rm -f $(OBJS) *.so G__$(PACKAGE).*
44
45 G__$(PACKAGE).cxx G__$(PACKAGE).h: $(HDRS) $(DHDR)
46         @echo "Generating dictionary ..."
47         rootcint -f $@ -c $(ALICEINC) $^
48