Added capability of searching neighboring digits for particle id in function AliDigit...
[u/mrichter/AliRoot.git] / Makefile
CommitLineData
fe4da5cc 1############################### Main Makefile #################################
2
3# Include machine specific definitions
4
5include $(ALICE_ROOT)/conf/GeneralDef
6include $(ALICE_ROOT)/conf/MachineDef.$(ALICE_TARGET)
7
08301132 8MAKEFLAGS += -s
fe4da5cc 9
10##### MACROS #####
11
12PACKAGE = Main
13
47b969ba 14DOTS = " ................................................................................"
15
0237511c 16PRETTY = $(AWK) '{print $$0 substr($(DOTS),1,79-length($$0))}'
47b969ba 17
fe4da5cc 18##### Module libraries #####
19
09898eb4 20ALIROOT_DIRS = STEER TGeant3 TRD PHOS TPC ZDC MUON PMD FMD TOF ITS \
e72c66aa 21 CASTOR RICH START STRUCT EVGEN RALICE ALIFAST \
01910535 22 THijing CONTAINERS MEVSIM TMEVSIM THbtp HBTP EMCAL HBTAN
fe4da5cc 23
24##### TARGETS #####
25
26default: lib bin alilibs aliroot
27
28lib bin:
29 @mkdir $@
30
31alilibs: lib
0237511c 32 echo MAKEFLAGS = $(MAKEFLAGS)
47b969ba 33 for i in $(ALIROOT_DIRS) ; do \
34 echo "Making headers in $$i" | $(PRETTY); \
31ccd13b 35 ${MAKE} -C $$i headers ; \
47b969ba 36 done
31ccd13b 37 @for i in $(ALIROOT_DIRS) ; do \
47b969ba 38 echo "Making dependencies in $$i" | $(PRETTY); \
fe4da5cc 39 ${MAKE} -C $$i depend ; \
40 done
41 @for i in $(ALIROOT_DIRS) ; do \
47b969ba 42 echo "Making in $$i" | $(PRETTY); \
fe4da5cc 43 ${MAKE} -C $$i ; \
44 done
45
2c7de6df 46aliroot geant321 minicern pdf pythia6 hijing: FORCE
0237511c 47 @DIR=`echo $@ | $(AWK) '{print toupper($$0)}'` ; \
47b969ba 48 echo "Making dependencies in $$DIR" | $(PRETTY); \
49 ${MAKE} -C $$DIR depend;\
50 echo "Making in $$DIR" | $(PRETTY); \
51 ${MAKE} -C $$DIR
fe4da5cc 52
8a3bc8e5 53TGeant4 AliGeant4 AliFluka : FORCE
5adf8bdf 54 @DIR=$@; \
55 echo "Making dependencies in $$DIR" | $(PRETTY); \
56 ${MAKE} -C $$DIR depend;\
57 echo "Making in $$DIR" | $(PRETTY); \
58 ${MAKE} -C $$DIR
59
2c7de6df 60cernlibs: geant321 pythia6 minicern pdf hijing
5adf8bdf 61
62geant4: TGeant4 AliGeant4
fe4da5cc 63
8a3bc8e5 64Flugg: FORCE
65 @DIR=$@; \
66 echo "Making in $$DIR" | $(PRETTY); \
67 ${MAKE} -C $$DIR/source
68
69fluka: Flugg TGeant4 AliGeant4 AliFluka
70
b83f95da 71all: cernlibs default
fe4da5cc 72
73FORCE:
74
75############################### General Macros ################################
76
3e27ea2b 77# include $(ALICE_ROOT)/conf/GeneralMacros
fe4da5cc 78
79############################### Specific Macros ###############################
80
81STRUCT_DIRS = html conf macros data share include Euclid picts \
4bff45ae 82 doc etc Makefile .rootrc
fe4da5cc 83
36022826 84LIBRARY_DIRS = MINICERN GEANT321 PYTHIA6 PDF HIJING
fe4da5cc 85
6ac62af5 86dist: AliRoot$(VERSION).tar.gz
fe4da5cc 87
6ac62af5 88AliRoot$(VERSION).tar.gz: $(STRUCT_DIRS) $(ALIROOT_DIRS) ALIROOT
fe4da5cc 89
6ac62af5 90distall: AliOffline$(VERSION).tar.gz
fe4da5cc 91
6ac62af5 92AliOffline$(VERSION).tar.gz: $(STRUCT_DIRS) $(ALIROOT_DIRS) $(LIBRARY_DIRS) ALIROOT
fe4da5cc 93
6ac62af5 94distlib: AliLibs$(VERSION).tar.gz
fe4da5cc 95
6ac62af5 96AliLibs$(VERSION).tar.gz: $(LIBRARY_DIRS)
fe4da5cc 97
6ac62af5 98AliRoot$(VERSION).tar.gz AliLibs$(VERSION).tar.gz AliOffline$(VERSION).tar.gz:
fe4da5cc 99 @rm -f $(ALICE)/$@
100 @rm -f `find . -name '*~' -print` \
101 `find . -name '*.bak' -print` \
cec56ef0 102 `find . -name '.*~' -print` \
18778aed 103 `find . -name '*\#*' -print`
fe4da5cc 104 @rm -f /tmp/saves
105 @ls -1d $^ | sed -e "s/^/$(ALICE_LEVEL)\//" > /tmp/saves
106 @cd $(ALICE) ; \
107 gtar cvfz $@ --exclude '*.o' --exclude '*Cint.*' \
e9fe1fae 108 --exclude 'roothtml' --exclude 'CVS' \
ce7c8058 109 --exclude Make-depend --exclude '*html/gif' \
ee854967 110 --exclude "*tgt_*" --exclude check \
ce7c8058 111 `cat /tmp/saves`
fe4da5cc 112
fe4da5cc 113htmldocnew: FORCE
114 @for i in $(ALIROOT_DIRS) ; do \
115 echo "Making HTML doc for $$i" ; \
116 rm -rf $(ALICE_ROOT)/$$i/html ; \
117 cd $(ALICE_ROOT)/$$i ; \
118 aliroot -b -q mkhtml.C > /dev/null; \
119 for j in `ls *.C` ; do \
120 echo $$j ; \
121 aliroot -b -q "mkhtml.C(\"$$j\")" > /dev/null; \
122 done \
123 done
124
125
126htmldoc: FORCE
127 @rm -rf html/roothtml
e95543bd 128 @rm -f html/picts
fe4da5cc 129 @rm -f /tmp/macros
130 @cd html ;\
131 aliroot -q -b "mkhtml.C(0,1)" ;\
132 ls ../macros/*.C > /tmp/macros ;\
133 for i in $(ALIROOT_DIRS) ; do \
134 ls ../$$i/*.C 2>/dev/null >> /tmp/macros ;\
135 done ;\
136 for i in `cat /tmp/macros` ; do \
137 echo $$i ; \
138 aliroot -b -q "mkhtml.C(\"$$i\")" > /dev/null ;\
139 done ;\
140 ./makeExampleList ;
1439f98e 141 @ln -s ../picts html/picts
142 @ln -s ../../picts html/roothtml/picts
143 @ln -s ../../../picts html/roothtml/src/picts
144 @ln -s ../../../picts html/roothtml/examples/picts
fe4da5cc 145
146clean: FORCE
147 @rm -f *~ \#*
6c83c8fa 148 @rm -f include/*
38c7852e 149 @for i in $(ALIROOT_DIRS) ALIROOT; do \
fe4da5cc 150 ${MAKE} -C $$i macroclean ; \
151 done
38c7852e 152 ifdef G4INSTALL
153 @for i in TGeant4 AliGeant4; do \
154 ${MAKE} -C $$i macroclean ; \
155 done
156 endif
fe4da5cc 157
158libclean: FORCE
159 @rm -f *~ \#*
160 @for i in $(LIBRARY_DIRS) ; do \
161 ${MAKE} -C $$i macroclean ; \
162 done
163
164allclean: libclean clean
41f6cf69 165
166# IRST coding rule check
c40fbac6 167CHECK_DIRS = $(ALIROOT_DIRS) ALIROOT TGeant4 AliGeant4
41f6cf69 168check:
169 @for i in $(CHECK_DIRS) ; do \
170 echo "Checking $$i" ; \
171 ${MAKE} -C $$i check ; \
172 done
173
3e27ea2b 174REVENG_DIRS = $(ALIROOT_DIRS)
175
176reveng:
177 @for i in $(REVENG_DIRS) ; do \
178 echo "Reverse engineering $$i" ; \
179 ${MAKE} -C $$i reveng ; \
180 done
181
41f6cf69 182
183
184
185
186
187
188