fix codding violation in AliTRDseedV1 class
[u/mrichter/AliRoot.git] / Makefile
CommitLineData
b9d0a01d 1# Top level Makefile for AliRoot System
2#
3# Author: Jan-Erik Revsbech (revsbech@fys.ku.dk)
4# Developed on idea of Boris Polichtchouk (Boris.Polichtchouk@cern.ch), 15/4/2001
fe4da5cc 5
462ee303 6# /* $Id$ */
fe4da5cc 7
b9d0a01d 8ifdef ALIVERBOSE
9MUTE:=
10else
11MUTE:=@
12endif
fe4da5cc 13
8d7652bd 14CLEAN=$(findstring clean,$(MAKECMDGOALS))
bdfb9593 15
462ee303 16#-------------------------------------------------------------------------------
b9d0a01d 17# IRST coding rule check
462ee303 18
b9d0a01d 19IRST_INSTALLDIR=$(ALICE)/local/IRST
50a3b0ee 20IRST_CONFIG_DIR=$(IRST_INSTALLDIR)/userConfig/ALICE
b9d0a01d 21CLASSPATH=$(IRST_INSTALLDIR)
50a3b0ee 22export CLASSPATH IRST_INSTALLDIR IRST_CONFIG_DIR
b9d0a01d 23CODE_CHECK=java rules.ALICE.ALICERuleChecker
24REV_ENG=$(IRST_INSTALLDIR)/scripts/revEng.sh
fe4da5cc 25
67f2eee7 26SMELL_DETECTOR_DIR=$(IRST_INSTALLDIR)/smell-detector
118c0ae6 27
9be1be4e 28#-------------------------------------------------------------------------------
29# The compilers
ae92cd6c 30CXX := $(shell root-config --cxx)
31F77 := $(shell root-config --f77)
32CC := $(shell root-config --cc)
118c0ae6 33
d76d4136 34CXXWARN =
35
462ee303 36#-------------------------------------------------------------------------------
462ee303 37# Include machine dependent macros
fe4da5cc 38
b9d0a01d 39-include build/Makefile.$(ALICE_TARGET)
fe4da5cc 40
462ee303 41#-------------------------------------------------------------------------------
42# Check if called with debug
42865053 43
b9d0a01d 44ifeq ($(ALIDEBUG),YES)
b934f194 45override ALICE_TARGET := $(ALICE_TARGET)DEBUG
46FFLAGS := -g $(filter-out -O%,$(FFLAGS))
4448d4ac 47CXXFLAGS := -g $(filter-out -O%,$(CXXFLAGS))
48CFLAGS := -g $(filter-out -O%,$(CFLAGS))
b934f194 49SOFLAGS := -g $(filter-out -O%,$(SOFLAGS))
50LDFLAGS := -g $(filter-out -O%,$(LDFLAGS))
b9d0a01d 51endif
fe4da5cc 52
462ee303 53#-------------------------------------------------------------------------------
54# Check if called with profile
2d8cad5a 55
56ifeq ($(ALIPROFILE),YES)
b934f194 57override ALICE_TARGET := $(ALICE_TARGET)PROF
58FFLAGS += -pg
2d8cad5a 59CXXFLAGS += -pg
b934f194 60CFLAGS += -pg
61SOFLAGS += -pg
62LDFLAGS += -pg
2d8cad5a 63endif
2d8cad5a 64
462ee303 65#-------------------------------------------------------------------------------
66# Check if DATE is installed
b8f3fa00 67
dc7dd139 68ifneq ($(shell which date-config | grep "^/"),)
8b13487a 69DATEFLAGS := -DALI_DATE $(shell date-config --cflags | tr \" \')
b934f194 70CXXFLAGS += $(DATEFLAGS)
71CFLAGS += $(DATEFLAGS)
b8f3fa00 72CINTFLAGS += $(DATEFLAGS)
e506ace2 73DEPINC += $(DATEFLAGS)
8b13487a 74DMONLIBS := $(shell date-config --monitorlibs)
e506ace2 75else
8b13487a 76DATEFLAGS := -D`uname` -DDATE_SYS=`uname` -Dlong32='int' \
e506ace2 77 -Dlong64='long long' -DdatePointer='long'
78CXXFLAGS += $(DATEFLAGS)
79CFLAGS += $(DATEFLAGS)
80CINTFLAGS += $(DATEFLAGS)
b934f194 81DEPINC += $(DATEFLAGS)
8b13487a 82DMONLIBS :=
0a1aa611 83endif
0a1aa611 84
bef53f4a 85#-------------------------------------------------------------------------------
d76d4136 86# Add warning flags if any
87
88ifneq ($(ALICXXWARN),no)
89CXXFLAGS += $(CXXWARN)
90endif
91
92#-------------------------------------------------------------------------------
49e7d912 93# ROOT Stuff
94ROOTCONFIG := root-config
95ROOTLIBDIR := $(shell $(ROOTCONFIG) --libdir)
96ROOTPLUGDIR := $(ROOTLIBDIR)/$(dir $(shell $(ROOTCONFIG) --version))
97ROOTINCDIR := $(shell $(ROOTCONFIG) --incdir)
98ROOTCLIBS := $(shell $(ROOTCONFIG) --glibs) \
99 -lThread \
100 -lMinuit \
101 -lVMC \
102 -lEG \
103 -lGeom \
104 -lTreePlayer \
105 -lXMLIO \
1f943cd9 106 -lXMLParser \
49e7d912 107 -lProof \
108 -lProofPlayer \
109 -lMLP \
110 -lSpectrum \
111 -L$(ROOTPLUGDIR)
8b13487a 112CHECKALIEN := $(shell root-config --has-alien)
113CHECKXML := $(shell root-config --has-xml)
49e7d912 114
462ee303 115#-------------------------------------------------------------------------------
e44bc3df 116# Location where to install libraries and binaries and common header files
117
118LIBPATH := lib/tgt_$(ALICE_TARGET)
119BINPATH := bin/tgt_$(ALICE_TARGET)
120EXPORTDIR := $(ALICE_ROOT)/include
121BINLIBDIRS := -L$(ALICE_ROOT)/$(LIBPATH)
122
123#-------------------------------------------------------------------------------
462ee303 124# Modules to build
fe4da5cc 125
e3642d02 126ifeq (ALIVERBOSE,2)
462ee303 127$(warning MAKECMDGOALS=$(MAKECMDGOALS))
128endif
fe4da5cc 129
b934f194 130ALIROOTMODULES := STEER PHOS TRD TPC ZDC MUON PMD FMD TOF ITS \
0850b27f 131 ACORDE HMPID T0 BCM STRUCT EVGEN RALICE VZERO \
7dd2cbe4 132 THijing THbtp EMCAL \
ae675276 133 THerwig TEPEMGEN FASTSIM TPHIC RAW MONITOR ANALYSIS \
0b35d932 134 JETAN HLT LHC ESDCheck STAT TTherminator CORRFW DPMJET TDPMjet \
b48d2542 135 PWG0 PWG1 PWG2 PWG3 PWG4 TRIGGER
8db084d0 136
fb1102ea 137# Additional generators
138ALIROOTMODULES += TUHKMgen
139ALIROOTMODULES += EPOS
140
49e7d912 141ifneq ($(shell $(ROOTCONFIG) --has-pythia8), no)
03229d48 142ALIROOTMODULES += PYTHIA8
143endif
144
49e7d912 145ifneq ($(shell $(ROOTCONFIG) --has-opengl), no)
3b85abd6 146ALIROOTMODULES += EVE
8db084d0 147endif
41f6cf69 148
b9d0a01d 149ifeq ($(findstring TFluka,$(MAKECMDGOALS)),TFluka)
462ee303 150ALIROOTMODULES += TFluka
b9d0a01d 151endif
152
c376a06a 153ifeq ($(findstring THydjet,$(MAKECMDGOALS)),THydjet)
154ALIROOTMODULES += THydjet
155endif
156
18d2e4ee 157ifeq ($(findstring SHUTTLE,$(MAKECMDGOALS)),SHUTTLE)
158ALIROOTMODULES += SHUTTLE
159endif
160
8db084d0 161CERNMODULES := LHAPDF HIJING MICROCERN HERWIG
49e7d912 162ifneq ($(wildcard $(ROOTINCDIR)/TPythia6.h),)
8db084d0 163CERNMODULES += PYTHIA6
164endif
b9d0a01d 165
462ee303 166MODULES := $(ALIROOTMODULES) $(CERNMODULES) ALIROOT
b9d0a01d 167
168MODDIRS := $(MODULES)
169
462ee303 170#-------------------------------------------------------------------------------
171# Default include dirs for C++, Fortran, Cint, and dependencies
172# The module directory will be added by each module
b9d0a01d 173
19ca05d1 174GENINC := -I$(ALICE_ROOT)/include -I$(shell root-config --incdir)
ae92cd6c 175RCFLAGS := $(shell root-config --cflags)
176RLFLAGS := $(shell root-config --ldflags)
177CXXFLAGS += $(GENINC) $(RCFLAGS)
178CXXFLAGSNO += $(GENINC) $(RCFLAGS)
179CFLAGS += $(GENINC) $(RCFLAGS)
180CINTFLAGS += $(GENINC) $(RCFLAGS)
181FFLAGS += $(RCFLAGS)
182LDFLAGS += $(RLFLAGS)
183SOFLAGS += $(RLFLAGS)
19ca05d1 184DEPINC += $(GENINC)
b9d0a01d 185
462ee303 186#-------------------------------------------------------------------------------
187# Libraries to link binaries against
188# Libraries will be linked against SHLIB
de6c7cfd 189# ROOT libraries
190
de6c7cfd 191ALILIBS := -L$(LIBDIR) -lMUON -lTPC -lPMD -lTRD -lFMD -lTOF \
b384f8a4 192 -lITS -lPHOS -lACORDE -lHMPID -lVZERO -lZDC -lSTRUCT \
b48d2542 193 -lT0 -lEVGEN -lSTEER -lTRIGGER
de6c7cfd 194
195LIBS := $(ROOTCLIBS) $(ROOTPLIBS) $(SYSLIBS)
b9d0a01d 196
6635aec0 197ARVERSIONFILE := $(EXPORTDIR)/ARVersion.h
9da71557 198SVNREV := $(strip $(shell LANG=C LANGUAGE=C svn info | grep "Last Changed Rev:" | \
49e7d912 199 cut -d: -f2 ))
d33faa69 200SVNBRANCH := $(subst //alisoft.cern.ch/AliRoot/,,$(shell svn info | grep "URL:" | cut -d: -f3 ))
6635aec0 201
462ee303 202#-------------------------------------------------------------------------------
b9d0a01d 203# default target
462ee303 204
6635aec0 205default: $(ARVERSIONFILE)
0693bbb3 206 $(MUTE)$(MAKE) aliroot
b9d0a01d 207
462ee303 208#-------------------------------------------------------------------------------
6635aec0 209# Write header file with aliroot svn version and url
210
d33faa69 211$(ARVERSIONFILE): $(ALICE_ROOT)/.svn/entries $(EXPORTDIR)
6635aec0 212 $(MUTE)rm -f $(ARVERSIONFILE)
213 @echo "***** Making $(ARVERSIONFILE) *****"
214 @echo "#ifndef ALIROOT_ARVersion" >> $@
215 @echo "#define ALIROOT_ARVersion" >> $@
216 @echo "#define ALIROOT_SVN_REVISION $(SVNREV)" >> $@
217 @echo "#define ALIROOT_SVN_BRANCH \"$(SVNBRANCH)\"" >> $@
218 @echo "#endif" >> $@
219#-------------------------------------------------------------------------------
462ee303 220# Each module will add to these macros
b9d0a01d 221
222ALLLIBS :=
223ALLEXECS :=
224INCLUDEFILES :=
b934f194 225BINLIBS :=
226EXPORTFILES :=
b9d0a01d 227
462ee303 228#-------------------------------------------------------------------------------
8d7652bd 229# Dependencies of module.mk files if not cleaning
b9d0a01d 230
8ef0bd93 231ifeq ($(CLEAN),)
b9d0a01d 232include build/module.dep
8d7652bd 233endif
b9d0a01d 234
462ee303 235#-------------------------------------------------------------------------------
236# Check if module.mk is present for the library
237
5386b933 238%.mk: build/module.tpl build/header.tpl build/clean.tpl share/alibtool
b9d0a01d 239ifndef ALIQUIET
240 @echo "***** Creating $@ file *****";
241endif
242 @share/alibtool mkmodule $(patsubst %/module.mk,%,$@) > $@;
b9d0a01d 243
462ee303 244#-------------------------------------------------------------------------------
462ee303 245# If making modules, not not include anything
b9d0a01d 246
bdfb9593 247ifeq ($(findstring modules,$(MAKECMDGOALS)),)
b9d0a01d 248
462ee303 249#-------------------------------------------------------------------------------
250# Include the modules
251
b934f194 252-include $(patsubst %,%/module.mk,$(MODULES))
b9d0a01d 253
462ee303 254#-------------------------------------------------------------------------------
bdfb9593 255# If cleaning, do not include dependencies or module.mk files.
256
257ifeq ($(CLEAN),)
258
259#-------------------------------------------------------------------------------
462ee303 260# Include dependencies if not making them!
b9d0a01d 261
462ee303 262ifneq ($(MAKECMDGOALS),depend)
9f1751e4 263ifneq ($(MAKECMDGOALS),)
462ee303 264
e3642d02 265ifeq (ALIVERBOSE,2)
462ee303 266$(warning INCLUDEFILES=$(INCLUDEFILES))
b9d0a01d 267endif
462ee303 268-include $(INCLUDEFILES)
b9d0a01d 269
270endif
271endif
462ee303 272endif
9f1751e4 273endif
462ee303 274
275#-------------------------------------------------------------------------------
276# Include dummy dependency file *MUST* be last includefile
b9d0a01d 277
b9d0a01d 278include build/dummy.d
b9d0a01d 279
280
462ee303 281#-------------------------------------------------------------------------------
282# Targets
b9d0a01d 283
2ea00b17 284.PHONY: alilibs aliroot makedistr clean distclean clean-all \
9f1751e4 285 htmldoc profile modules depend
b9d0a01d 286
b934f194 287modules: $(patsubst %,%/module.mk,$(MODULES))
41f6cf69 288
2d8cad5a 289ifeq ($(ALIPROFILE),YES)
3a5e5a40 290alilibs: $(LIBPATH) modules $(ALLLIBS) $(ALLALIBS)
2d8cad5a 291else
3a5e5a40 292alilibs: $(LIBPATH) modules $(ALLLIBS)
2d8cad5a 293endif
41f6cf69 294
b8205a22 295aliroot: alilibs $(BINPATH) $(ALLEXECS)
9f1751e4 296
cf5fccae 297ALIRECO.par: macros/loadlibsrec.C STEER/PROOF-INF.ALIRECO/SETUP.C
298 $(MUTE)echo "***** Creating package archive" $@ "*****"
299 $(MUTE)rm -rf ALIRECO
300 $(MUTE)mkdir -p ALIRECO/PROOF-INF
301 $(MUTE)cat $^ > ALIRECO/PROOF-INF/SETUP.C
302 (tar cfzh $@ ALIRECO 2> /dev/null && echo "Package archive" $@ "created in" $(PWD)/$@) || (tar cfzh /tmp/$@ ALIRECO 2> /dev/null && echo "Package archive" $@ "created in /tmp/"$@)
303 $(MUTE)rm -rf ALIRECO
304
9be2a0b4 305ROOTALIBDIR:=$(shell root-config --libdir)
a6e3afe8 306
913d9052 307ALIMDCSPECFILE=$(RAWDIRO)/alimdc.spec
308ALIMDCVERSION=$(subst -,.,$(notdir $(subst /RAW/mdc.h,,$(shell svn info RAW/mdc.h | grep "URL:" | cut -d: -f3 ))))
309ALIMDCRELEASE=$(firstword $(shell svn info RAW/mdc.h | grep "Revision:" | cut -d: -f2 ))
310
311alimdc-rpm: alimdc-static alimdc-specfile
99102ed0 312 $(MUTE)rm -rf alimdc-root
313 $(MUTE)mkdir -p alimdc-root/opt/alimdc/lib
314 $(MUTE)mkdir -p alimdc-root/opt/alimdc/include
315 $(MUTE)cp RAW/mdc.h alimdc-root/opt/alimdc/include
316 $(MUTE)cp $(LIBPATH)/libAliMDC.a \
317 $(ROOTALIBDIR)/libRoot.a \
318 $(ROOTALIBDIR)/libfreetype.a $(ROOTALIBDIR)/libpcre.a \
319 alimdc-root/opt/alimdc/lib
320 $(MUTE)rm -rf RPMS
6603b075 321 $(MUTE)case `uname -m` in \
322 i?86*) ALIMDCARCHDIR=i386;;\
323 ia64*) ALIMDCARCHDIR=ia64;;\
324 x86_64*) ALIMDCARCHDIR=x86_64;;\
325 *) echo "Unknown architecture: `uname -m`"; exit 1;;\
326 esac; \
327 mkdir -p RPMS/$$ALIMDCARCHDIR; \
328 rpmbuild --verbose --define "_topdir $(ALICE_ROOT)" --define "_tmppath $(ALICE_ROOT)" -bb $(ALIMDCSPECFILE); \
329 cp -p RPMS/$$ALIMDCARCHDIR/alimdc-*.rpm .;
99102ed0 330 $(MUTE)rm -rf alimdc-root
331 $(MUTE)rm -rf RPMS
332 @echo "***** alimdc RPM created and put $(ALICE_ROOT) folder *****"
333
913d9052 334alimdc-specfile: $(RAWDIRO)
335 $(MUTE)rm -rf $(ALIMDCSPECFILE)
336 @echo "***** Making alimdc RPM spec-file $(ALIMDCSPECFILE) *****"
337 @echo "# RPM specfile for alimdc static libs" >> $(ALIMDCSPECFILE)
338 @echo "# Package contains both ROOT and AliRoot" >> $(ALIMDCSPECFILE)
339 @echo "# static libs needed by mStreamRecorder" >> $(ALIMDCSPECFILE)
340 @echo "# in order to ROOT-ify the incoming raw" >> $(ALIMDCSPECFILE)
341 @echo "# data" >> $(ALIMDCSPECFILE)
342 @echo "# Example how-to build alimdc RPM:" >> $(ALIMDCSPECFILE)
343 @echo "# cd $ALICE_ROOT" >> $(ALIMDCSPECFILE)
344 @echo "# make alimdc-rpm" >> $(ALIMDCSPECFILE)
345 @echo "" >> $(ALIMDCSPECFILE)
346 @echo "Summary: AliMDC static libraries" >> $(ALIMDCSPECFILE)
347 @echo "Name: alimdc" >> $(ALIMDCSPECFILE)
348 @echo "Version: $(ALIMDCVERSION)" >> $(ALIMDCSPECFILE)
349 @echo "Release: $(ALIMDCRELEASE)" >> $(ALIMDCSPECFILE)
350 @echo "# Copyright: CERN Alice Off-line" >> $(ALIMDCSPECFILE)
351 @echo "License: CERN Alice Off-line" >> $(ALIMDCSPECFILE)
352 @echo "Vendor: ALICE Core Off-line Group" >> $(ALIMDCSPECFILE)
353 @echo "URL: http://aliceinfo.cern.ch" >> $(ALIMDCSPECFILE)
354 @echo "Group: Applications/Alice" >> $(ALIMDCSPECFILE)
355 @echo "Prefix: /opt/%{name}" >> $(ALIMDCSPECFILE)
356 @echo "BuildRoot: %{_tmppath}/%{name}-root" >> $(ALIMDCSPECFILE)
357 @echo "" >> $(ALIMDCSPECFILE)
358 @echo "# automatic dependencies" >> $(ALIMDCSPECFILE)
359 @echo "AutoReqProv: yes" >> $(ALIMDCSPECFILE)
360 @echo "" >> $(ALIMDCSPECFILE)
361 @echo "# list here required RPM packages for runtime" >> $(ALIMDCSPECFILE)
362 @echo "Requires: glibc" >> $(ALIMDCSPECFILE)
363 @echo "" >> $(ALIMDCSPECFILE)
364 @echo "Provides: alimdc" >> $(ALIMDCSPECFILE)
365 @echo "" >> $(ALIMDCSPECFILE)
366 @echo "# description of the package" >> $(ALIMDCSPECFILE)
367 @echo "%description" >> $(ALIMDCSPECFILE)
368 @echo "Package contains both ROOT and AliRoot" >> $(ALIMDCSPECFILE)
369 @echo "static libs needed by mStreamRecorder" >> $(ALIMDCSPECFILE)
370 @echo "in order to ROOT-ify the incoming raw" >> $(ALIMDCSPECFILE)
371 @echo "data. The package version correspond to" >> $(ALIMDCSPECFILE)
372 @echo "the AliRoot one." >> $(ALIMDCSPECFILE)
373 @echo "" >> $(ALIMDCSPECFILE)
374 @echo "# list of files to be installed" >> $(ALIMDCSPECFILE)
375 @echo "%files" >> $(ALIMDCSPECFILE)
376 @echo "%defattr (-,root,root)" >> $(ALIMDCSPECFILE)
377 @echo "%{prefix}/lib/libAliMDC.a" >> $(ALIMDCSPECFILE)
378 @echo "%{prefix}/lib/libRoot.a" >> $(ALIMDCSPECFILE)
379 @echo "%{prefix}/lib/libpcre.a" >> $(ALIMDCSPECFILE)
380 @echo "%{prefix}/lib/libfreetype.a" >> $(ALIMDCSPECFILE)
381 @echo "%{prefix}/include/mdc.h" >> $(ALIMDCSPECFILE)
382
e66566e2 383alimdc-static: $(LIBPATH) $(BINPATH) $(RAWDatabaseALIB) $(MDCALIB) $(ESDALIB) $(STEERBaseALIB) $(alimdcCXXO)
3c1a04dc 384 $(MUTE)rm -rf $(LIBPATH)/libAliMDC.a
385 $(MUTE)rm -rf junk
e66566e2 386 mkdir junk && cd junk && ar x ../$(RAWDatabaseALIB) && ar x ../$(MDCALIB) && ar x ../$(ESDALIB) && ar x ../$(STEERBaseALIB) && ar r ../$(LIBPATH)/libAliMDC.a *.o && cd .. && rm -rf junk
a6e3afe8 387 $(LD) $(LDFLAGS) -o $(BINPATH)/alimdca $(alimdcCXXO) \
388 $(LIBPATH)/libAliMDC.a \
389 $(ROOTALIBDIR)/libRoot.a \
390 $(ROOTALIBDIR)/libfreetype.a $(ROOTALIBDIR)/libpcre.a \
28133321 391 -pthread -ldl -lcurses
5fdadcc5 392
e5f9749d 393alilibs-static: $(LIBPATH) modules $(ALLALIBS)
394
5fdadcc5 395include build/MakefileDA
396
462ee303 397#-------------------------------------------------------------------------------
b9d0a01d 398# Single Makefile "distribution": Makefile + modules + mkdepend scripts
b934f194 399makedistr: $(MODULES)
b9d0a01d 400 tar -cvf MakeDistr.tar $(patsubst %,%/*.pkg,$(MODULES)) \
b934f194 401 Makefile create build/*
41f6cf69 402
b9d0a01d 403all: aliroot
41f6cf69 404
b934f194 405depend: $(INCLUDEFILES)
41f6cf69 406
b9d0a01d 407debug:
408ifndef ALIQUIET
409 @echo "***** Entering DEBUG mode. *****"
410endif
e1f602dc 411 @(export ALIDEBUG=YES && $(MAKE) aliroot)
b934f194 412
2d8cad5a 413profile:
414ifndef ALIQUIET
415 @echo "***** Entering PROFILE mode. *****"
416endif
e1f602dc 417 @(export ALIPROFILE=YES && $(MAKE) aliroot)
b934f194 418
b9d0a01d 419$(MODULES):
420ifndef ALIQUIET
421 @echo "***** Making $@ *****"
422endif
423 @mkdir -p $@
424
425$(BINPATH):
426ifndef ALIQUIET
427 @echo "***** Making $@ *****"
428endif
429 @mkdir -p $@
430
431$(LIBPATH):
432ifndef ALIQUIET
433 @echo "***** Making $@ *****"
434endif
435 @mkdir -p $@
436
437build/dummy.d: $(EXPORTFILES)
438 @(if [ ! -f $@ ] ; then \
439 touch $@; \
440 fi)
441
442clean:
2ea00b17 443 @echo "***** No target clean, use one of these *****"
b9d0a01d 444 @echo " clean-aliroot : Clean up all aliroot libraries"
445 @echo " clean-MODULENAME : Clean everything from module MODULENAME"
446 @echo " clean-all : Cleans up everything, including cern libraires"
1aa44b64 447 @echo " distclean : Like clean-all + clean all tgt_*'s"
b934f194 448 @echo " clean-modules : Clean all module.mk files in all modules"
b9d0a01d 449 @echo " clean-libs : Clean all libraries (not object files)"
450 @echo "********************************************"
451
452clean-all: clean-modules clean-libs clean-bins
453ifndef ALIQUIET
454 @echo "***** Cleaning up everything ****"
455endif
456 $(MUTE)rm -rf $(patsubst %,%/tgt_$(ALICE_TARGET),$(MODULES))
457 $(MUTE)rm -rf $(EXPORTDIR)
458
2ea00b17 459distclean: clean-all
1aa44b64 460 $(MUTE)rm -rf */tgt_* bin lib
2ea00b17 461
462ee303 462#-------------------------------------------------------------------------------
463# This cleans only libraries that are not CERN-libraries
b9d0a01d 464
465clean-aliroot: $(patsubst %,%/module.mk,$(ALIROOTMODULES)) $(patsubst %,clean-%,$(ALIROOTMODULES))
466
7e96fcc7 467CHECKMODULES := $(MODULES)
0b5dd071 468CHECKMODULES := $(filter-out TPHIC,$(CHECKMODULES))
af4ebdd2 469CHECKMODULES := $(filter-out LHAPDF,$(CHECKMODULES))
7e96fcc7 470CHECKMODULES := $(filter-out MICROCERN,$(CHECKMODULES))
b9d0a01d 471
b934f194 472check-all: $(patsubst %,%/module.mk,$(CHECKMODULES)) $(patsubst %,check-%,$(CHECKMODULES))
b9d0a01d 473
5b0f3b29 474smell-all: $(patsubst %,%/module.mk,$(CHECKMODULES)) $(patsubst %,smell-%,$(CHECKMODULES))
475
b934f194 476reveng-all: $(patsubst %,%/module.mk,$(CHECKMODULES)) $(patsubst %,reveng-%,$(CHECKMODULES))
b9d0a01d 477
b934f194 478revdisp-all: $(patsubst %,%/module.mk,$(CHECKMODULES)) $(patsubst %,revdisp-%,$(CHECKMODULES))
b9d0a01d 479
118c0ae6 480smell-all: $(patsubst %,%/module.mk,$(CHECKMODULES)) $(patsubst %,smell-%,$(CHECKMODULES))
481
b9d0a01d 482clean-dicts:
483ifndef ALIQUIET
484 @echo "***** Cleaning up G__ files *****"
485endif
486 $(MUTE)rm -rf */tgt_$(ALICE_TARGET)/G__*
41f6cf69 487
b9d0a01d 488clean-modules:
489ifndef ALIQUIET
b945e71d 490 @echo "***** Cleaning up module.mk and temporary compilation files *****"
b9d0a01d 491endif
b934f194 492 $(MUTE)rm -rf $(patsubst %,%/module.mk,$(MODULES))
b945e71d 493 $(MUTE)rm -rf $(patsubst %,%/tgt_$(ALICE_TARGET),$(MODULES))
41f6cf69 494
b9d0a01d 495clean-depend:
496ifndef ALIQUIET
497 @echo "***** Cleaning up dependencies *****"
498endif
499 $(MUTE)echo rm `find . -name "*.d"`
500
501clean-objects:
502ifndef ALIQUIET
503 @echo "***** Cleaning up .o files *****"
504endif
505 $(MUTE)echo rm `find . -name "*.o"`
506
507clean-libs:
508ifndef ALIQUIET
509 @echo "***** Cleaning up library files *****"
510endif
511 $(MUTE)rm -rf lib/tgt_$(ALICE_TARGET)/*
512
513clean-bins:
514ifndef ALIQUIET
515 @echo "***** Cleaning up binary files *****"
516endif
517 $(MUTE)rm -rf bin/tgt_$(ALICE_TARGET)
d7a221d0 518
b934f194 519clean-check-all: $(patsubst %,%/module.mk,$(CHECKMODULES)) $(patsubst %,clean-check-%,$(CHECKMODULES))
ba546cfd 520
5b0f3b29 521clean-smell-all: $(patsubst %,%/module.mk,$(CHECKMODULES)) $(patsubst %,clean-smell-%,$(CHECKMODULES))
522
b934f194 523clean-reveng-all: $(patsubst %,%/module.mk,$(CHECKMODULES)) $(patsubst %,clean-reveng-%,$(CHECKMODULES))
ba546cfd 524
d7a221d0 525htmldoc:
526 @rm -rf html/roothtml
527 @rm -f html/picts
528 @rm -f /tmp/macros
529 @cd html ;\
530 aliroot -q -b "mkhtml.C(0,1)" ;\
531 ls ../macros/*.C > /tmp/macros ;\
532 for i in $(ALIROOTMODULES) ; do \
533 ls ../$$i/*.C 2>/dev/null >> /tmp/macros ;\
534 done ;\
535 for i in `cat /tmp/macros` ; do \
536 echo $$i ; \
537 aliroot -b -q "mkhtml.C(\"$$i\")" > /dev/null ;\
538 done ;\
539 ./makeExampleList ;
540 @ln -s ../picts html/picts
541 @ln -s ../../picts html/roothtml/picts
542 @ln -s ../../../picts html/roothtml/src/picts
543 @ln -s ../../../picts html/roothtml/examples/picts