/[PAMELA software]/DarthVader/Makefile
ViewVC logotype

Diff of /DarthVader/Makefile

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1.1.2 by mocchiut, Sat Jun 17 12:12:48 2006 UTC revision 1.42 by mocchiut, Tue Sep 30 07:38:02 2008 UTC
# Line 1  Line 1 
1  # Trigger flight analysis software  # DarthVader flight analysis software
2  # SOFTWARE VERSION  # SOFTWARE VERSION IS
3  VER= v3r00  VER= v5r02
4  # An almost general purpouse Makefile for PAMELA repository  # An almost general purpouse Makefile for PAMELA repository
5  # Let's start with some usefull definition for colorize the echo  # Let's start with some usefull definition for colorize the echo
6  RED='\E[1;31;40m'  RED='\E[1;31;40m'
# Line 21  EWHITE=echo -e ${WHITE} Line 21  EWHITE=echo -e ${WHITE}
21  # Reset the terminal  # Reset the terminal
22  RESET=tput sgr0  RESET=tput sgr0
23  # Here the variables used to override the standard make flags  # Here the variables used to override the standard make flags
24    #MAKE
25    MAKE=make
26  # C  # C
27  CC=gcc  CC=gcc
28  #CFLAGS=-Wall -O -fPIC -pthread -g  #CFLAGS=-Wall -O -fPIC -pthread -g ${PAM_BIT}
29  CFLAGS=-Wall -O -fPIC -pthread  CFLAGS=-Wall -O -fPIC -pthread ${PAM_BIT}
30  # Enviroment:  # Enviroment:
31  GCCVER=`gcc --version | head -1`  GCCVER=`gcc --version | head -1`
32  UNAMEA=`uname -a`  UNAMEA=`uname -a`
33  TODAY=`date`  TODAY=`date`
34  # F77  # F77
35  F77=g77  F77=g77
36  #F77FLAGS=  -Wall -Wno-globals -fvxt -fno-automatic -fbounds-check -g -extend_source -static -fno-backslash  #F77FLAGS=  -Wall -Wno-globals -fvxt -fno-automatic -fbounds-check -g -extend_source -static -fno-backslash ${PAM_BIT}
37  F77FLAGS=  -Wall -Wno-globals -fvxt -fno-automatic -fbounds-check -extend_source -static -fno-backslash  F77FLAGS=  -Wall -Wno-globals -fPIC -fvxt -fno-automatic -fbounds-check -extend_source -static -fno-backslash ${PAM_BIT}
38  # C++  # C++
39  CXX=g++  CXX=g++
40  #CXXFLAGS=-Wall -O -fPIC -pthread -g  #CXXFLAGS=-Wall -O -fPIC -pthread -g ${PAM_BIT}
41  CXXFLAGS=-Wall -O -fPIC -pthread  CXXFLAGS=-Wall -O4 -fPIC -pthread ${PAM_BIT}
42  # ROOTCINT  # ROOTCINT
43  ROOTCINT=rootcint  ROOTCINT=rootcint
44    #CERNLIB
45    CERNLIB=./docs/cernlib_pam
46    #CERNLIB=cernlib
47    
48  # Here the variables definig the local directories  # Here the variables definig the local directories
49  DIRTOP=${shell pwd}  DIRTOP=${shell pwd}
50  DIRLIB=../lib/${ARCH}  #DIRLIB=../lib/${ARCH}
51  DIRBIN=../bin/${ARCH}  #DIRBIN=../bin/${ARCH}
52  #DIRLIB=lib/${ARCH}  DIRLIB=lib/${ARCH}
53  #DIRBIN=bin/${ARCH}  DIRBIN=bin/${ARCH}
54  DIRSRC=src  DIRSRC=src
55  DIRINC=inc  DIRINC=inc
56  DIRDOC=doc  DIRDOC=doc
57  DIRMACROS=macros  DIRMACROS=macros
58  DIRCALIB=calib  DIRCALIB=param
59  # Here the  PAMELA environmental variables to be checked  # Here the  PAMELA environmental variables to be checked
60  PAM_ENV= PAM_BIN_env PAM_LIB_env PAM_INC_env PAM_DOC_env PAM_YODA_env  PAM_ENV= PAM_BIN_env PAM_LIB_env PAM_INC_env PAM_DOC_env PAM_CALIB_env PAM_YODA_env
61    
62  # Here the local variables used to build the targets  # Here the local variables used to build the targets
63  # -- F77 - no libraries --  # -- F77 - no libraries --
# Line 59  FSRCS= Line 65  FSRCS=
65  FOBJS=$(FSRCS:${DIRSRC}%.for=${DIRLIB}%.o)  FOBJS=$(FSRCS:${DIRSRC}%.for=${DIRLIB}%.o)
66    
67  # -- CPP - no libraries --  # -- CPP - no libraries --
68  CPPSRCS=  CPPSRCS=${DIRSRC}/DarthVaderVerl2.cpp
69  CPPOBJS=$(CPPSRCS:${DIRSRC}%.cpp=${DIRLIB}%.o)  CPPOBJS=$(CPPSRCS:${DIRSRC}%.cpp=${DIRLIB}%.o)
70    
71  # -- C - no libraries --  # -- C - no libraries --
72  CSRCS=  CSRCS=
73  COBJS=$(CSRCS:${DIRSRC}%.c=${DIRLIB}%.o)  COBJS=$(CSRCS:${DIRSRC}%.c=${DIRLIB}%.o)
74    
75  # -- CPP - ROOT libraries --  # -- CPP - ROOT libraries --
76  LIBROOTSRCS=${DIRSRC}/TrigLevel2.cpp  LIBROOTSRCS=
77    
78  LIBROOTLIBS=$(LIBROOTSRCS:${DIRSRC}/%.cpp=${DIRLIB}/lib%_${VER}.so)  LIBROOTLIBS=$(LIBROOTSRCS:${DIRSRC}/%.cpp=${DIRLIB}/lib%_${VER}.so)
79  LIBROOTCLIBS=libTrigLevel2  LIBROOTCLIBS=
80  FULLROOTCLIBS=$(LIBROOTCLIBS:%=${DIRLIB}/%_${VER}.so)  FULLROOTCLIBS=$(LIBROOTCLIBS:%=${DIRLIB}/%_${VER}.so)
81    
82  # -- CPP - NON-ROOT libraries --  # -- CPP - NON-ROOT libraries --
83  LIBCPPSRCS= ${DIRSRC}/TrigCore.cpp \  LIBCPPSRCS=
         ${DIRSRC}/TrigVerl2.cpp  
84  LIBCPPLIBS=$(LIBCPPSRCS:${DIRSRC}/%.cpp=${DIRLIB}/lib%_${VER}.so)  LIBCPPLIBS=$(LIBCPPSRCS:${DIRSRC}/%.cpp=${DIRLIB}/lib%_${VER}.so)
85  LIBCPPCLIBS=libTrigCore libTrigVerl2  LIBCPPCLIBS=
86  FULLLIBCPPLIBS=$(LIBCPPCLIBS:%=${DIRLIB}/%_${VER}.so)  FULLLIBCPPLIBS=$(LIBCPPCLIBS:%=${DIRLIB}/%_${VER}.so)
87    
88  # -- CPP - Executables --  # -- CPP - Executables --
89  CXXEXESRCS=${DIRSRC}/TriggerLevel2.cpp  CXXEXESRCS=${DIRSRC}/DarthVader.cpp
90  CXXEXEOBJS=$(CXXEXESRCS:${DIRSRC}%.cpp=${DIRLIB}%.o)  CXXEXEOBJS=$(CXXEXESRCS:${DIRSRC}%.cpp=${DIRLIB}%.o)
91  CXXEXELIBS:=TriggerLevel2  CXXEXELIBS:=DarthVader
92    
93    # -- list of objects needed to link
94    ##OBJS=$(shell cd ${DIRLIB}&>/dev/null;for file in `ls *.*`; do if [ $${file} != "" ] && [ $${file} != "DarthVader.o" ] && [ $${file} != "R2-D2.o" ]; then echo ${DIRLIB}/$${file}; fi; done)
95    OBJS=$(shell cd ${DIRLIB}&>/dev/null;for file in `ls lib*.so`; do if [ $${file} != "" ]; then echo ${DIRLIB}/$${file}; fi; done) ${CPPOBJS}
96    DARTHVLIB=${DIRLIB}/libDarthVader_${VER}.so
97    
 # -- list of tracker objects needed to link  
 TRKOBJS=${DIRLIB}/libGLTables.so ${DIRLIB}/libRunInfo.so  
98  # -- directory where to find tracker headers needed to compile  # -- directory where to find tracker headers needed to compile
99  SUBDIR=../GLTables ../RunInfo  #TRKHEAD=${DIRTOP}/../tracker/inc
100    #TRKHEAD=-I${PAM_INC} -ITrackerLevel2/inc/ -IRunInfo/inc/ -IGLTables/inc/
101    
102    #
103    SUBDIR=./RunInfo ./S4Level2 ./NDLevel2 ./TrackerLevel2 ./TriggerLevel2 ./ToFLevel2 ./CalorimeterLevel2 ./AnticounterLevel2 ./OrbitalInfo
104  SUBINC=$(shell for dir in `echo ${SUBDIR}`; do echo -I$${dir}/inc; done)  SUBINC=$(shell for dir in `echo ${SUBDIR}`; do echo -I$${dir}/inc; done)
105    
106  # List of all libraries we want to install  # List of all libraries we want to install
107  FULLLIBS = ${FULLROOTCLIBS} ${FULLLIBCPPLIBS}  FULLLIBS = ${FULLROOTCLIBS} ${FULLLIBCPPLIBS} ${DARTHVLIB}
108    
109  # Other objects to install  # Other objects to install
110  EXESRCS=${DIRBIN}/TriggerLevel2  EXESRCS=${DIRBIN}/DarthVader
111    
112  INCSRCS=${DIRINC}/TrigLevel2.h  INCSRCS=
113    
114  MACROSSRCS=  MACROSSRCS=
115    
116  CALIBFILES=  CALIBFILES=${DIRCALIB}/trk-param ${DIRCALIB}/cal-param ${DIRCALIB}/tof-param ${DIRCALIB}/orb-param
117    
118  DOCFILES=  DOCFILES=
119    
120  # Here the Variables used for info target  # Here the Variables used for info target
121  PACKAGE=Trigger analysis flight software  PACKAGE=PAMELA analysis flight software
122  EXECUTABLES= ${EXESRCS}  EXECUTABLES= ${EXESRCS}
123  LIBS= ${FULLLIBS}  LIBS= ${FULLLIBS}
124  DOCS=  DOCS=
# Line 118  INCLUDE= ${INCSRCS} Line 130  INCLUDE= ${INCSRCS}
130  TOBEDEL = junk  TOBEDEL = junk
131  ROOTINC=$$${shell root-config --incdir}  ROOTINC=$$${shell root-config --incdir}
132  NROOTINC=${shell root-config --incdir}  NROOTINC=${shell root-config --incdir}
133    # Directories where you place detectors software
134    #SUBDIR=./GLTables ./RunInfo ./TrackerLevel2 ./CalorimeterLevel2
135    
136  # Let's start  # Let's start
137  #all: test mkbindir mklibdir mkverpath ${FOBJS} ${CPPOBJS} ${LIBROOTLIBS} ${LIBCPPLIBS} ${CXXEXELIBS}  #all: test mkbindir mklibdir mkverpath ${FOBJS} ${CPPOBJS} ${LIBROOTLIBS} ${LIBCPPLIBS} ${CXXEXELIBS}
138  all: prepare libs  
139  all:  all:
140            @for dir in `echo ${SUBDIR}`; do  \
141             echo "Making all in $${dir}"; \
142             (cd $${dir} && ${MAKE} all); \
143            done; make locall
144    
145    locall: prepare libs exe
146    locall:
147          @echo -e ${GREEN} ""          @echo -e ${GREEN} ""
148          @(${EGREEN} " Finished, now you can install the package \n  (use: make install or make upgrade or make forceinstall) "; ${RESET})          @(${EGREEN} " Finished, now you can install the package \n  (use: make install or make upgrade or make forceinstall) "; ${RESET})
149          @echo -e ${GREEN} ""          @echo -e ${GREEN} ""
150          @${RESET}          @${RESET}
151    
152  standalone: all exe  #subdir:
153    #       @for dir in `echo ${SUBDIR}`; do  \
154    #        echo "Making ${target} in $${dir}"; \
155    #        (cd $${dir} && ${MAKE} ${target}); \
156    #        done;
157    
158  prepare: test mkbindir mklibdir mkverpath  prepare: test mkbindir mklibdir mkverpath
159    
# Line 138  libs: prepare ${LIBROOTLIBS} ${LIBCPPLIB Line 164  libs: prepare ${LIBROOTLIBS} ${LIBCPPLIB
164  # Here some general rules to produce objects in our local dir  # Here some general rules to produce objects in our local dir
165  ${DIRLIB}/%.o: ${DIRSRC}/%.cpp  ${DIRLIB}/%.o: ${DIRSRC}/%.cpp
166          @(${EGREEN} "Creating CPP object file: "${WHITE} "`basename $@`"; ${RESET})          @(${EGREEN} "Creating CPP object file: "${WHITE} "`basename $@`"; ${RESET})
167          @${CXX} ${CXXFLAGS} -c -o $@ ${DIRSRC}/`basename ${@} .o`.cpp -I${DIRINC} ${SUBINC} -I${PAM_YODA}/include/yoda/  -I${PAM_YODA}/include/utils/ `root-config --cflags`          @${CXX} ${CXXFLAGS} -c -o $@ ${DIRSRC}/`basename ${@} .o`.cpp -I${DIRINC} ${SUBINC} -I${PAM_YODA}/include/yoda/ -I${PAM_INC}/ `root-config --cflags`
168    
169  ${DIRLIB}/%.o: ${DIRSRC}/%.c  ${DIRLIB}/%.o: ${DIRSRC}/%.c
170          @(${EGREEN} "Creating C object file: "${WHITE} "`basename $@`"; ${RESET})          @(${EGREEN} "Creating C object file: "${WHITE} "`basename $@`"; ${RESET})
171          @${CXX} ${CXXFLAGS} -c -o $@ ${DIRSRC}/`basename ${@} .o`.c -I${DIRINC} ${SUBINC} -I${PAM_YODA}/include/yoda/ `root-config --cflags`          @${CXX} ${CXXFLAGS} -c -o $@ ${DIRSRC}/`basename ${@} .o`.c -I${DIRINC}  -I${PAM_YODA}/include/yoda/ -I${PAM_INC}/ `root-config --cflags`
172    
173  ${DIRLIB}/%.o: ${DIRSRC}/%.for  ${DIRLIB}/%.o: ${DIRSRC}/%.for
174          @(${EGREEN} "Creating F77 object file: "${WHITE} "`basename $@`"; ${RESET})          @(${EGREEN} "Creating F77 object file: "${WHITE} "`basename $@`"; ${RESET})
# Line 153  ${LIBROOTLIBS}: ${LIBROOTSRCS} Line 179  ${LIBROOTLIBS}: ${LIBROOTSRCS}
179  #  #
180  #       Create *Dict.cpp and *Dict.h  #       Create *Dict.cpp and *Dict.h
181  #  #
182          @${ROOTCINT} -f ${DIRSRC}/`basename $(@F) _${VER}.so | sed s/lib//`Dict.cpp -c -I${ROOTINC} -I${PAM_YODA}/include/yoda/ ${DIRINC}/`basename $(@F) _${VER}.so | sed s/lib//`.h ${DIRINC}/`basename $(@F) _${VER}.so | sed s/lib//`LinkDef.h          @${ROOTCINT} -f ${DIRSRC}/`basename $(@F) _${VER}.so | sed s/lib//`Dict.cpp -c -I${ROOTINC} -I${PAM_YODA}/include/yoda/ -I${PAM_INC}/ ${DIRINC}/`basename $(@F) _${VER}.so | sed s/lib//`.h ${DIRINC}/`basename $(@F) _${VER}.so | sed s/lib//`LinkDef.h
183  #  #
184  #       create .o  #       create .o
185  #  #
186          @(${EGREEN} "Compiling CPP file: "${WHITE} "`basename $(@F) _${VER}.so | sed s/lib//`.cpp"; ${RESET})          @(${EGREEN} "Compiling CPP file: "${WHITE} "`basename $(@F) _${VER}.so | sed s/lib//`.cpp"; ${RESET})
187          @${CXX} ${CXXFLAGS} -c ${DIRTOP}/${DIRSRC}/`basename $(@F) _${VER}.so | sed s/lib//`.cpp -o ${DIRTOP}/${DIRLIB}/`basename $(@F) _${VER}.so | sed s/lib//`.o -I${DIRTOP}/${DIRINC} -I${DIRTOP} ${SUBINC} -I${PAM_YODA}/include/yoda/ -I${NROOTINC};          @cd ${DIRSRC} &>/dev/null && ${CXX} ${CXXFLAGS} -c `basename $(@F) _${VER}.so | sed s/lib//`.cpp -I${DIRTOP}/${DIRINC} -I${DIRTOP} -I${PAM_YODA}/include/yoda/ -I${PAM_INC}/ -I${NROOTINC};
188          @(${EGREEN} "Compiling CPP file: "${WHITE} "`basename $(@F) _${VER}.so | sed s/lib//`Dict.cpp"; ${RESET})          @(${EGREEN} "Compiling CPP file: "${WHITE} "`basename $(@F) _${VER}.so | sed s/lib//`Dict.cpp"; ${RESET})
189          @${CXX} ${CXXFLAGS} -c ${DIRTOP}/${DIRSRC}/`basename $(@F) _${VER}.so | sed s/lib//`Dict.cpp -o ${DIRTOP}/${DIRLIB}/`basename $(@F) _${VER}.so | sed s/lib//`Dict.o -I${DIRTOP}/${DIRINC} -I${DIRTOP} ${SUBINC} -I${PAM_YODA}/include/yoda/ -I${NROOTINC};          @cd ${DIRSRC} &>/dev/null && ${CXX} ${CXXFLAGS} -c `basename $(@F) _${VER}.so | sed s/lib//`Dict.cpp -I${DIRTOP}/${DIRINC} -I${DIRTOP} -I${PAM_YODA}/include/yoda/ -I${PAM_INC}/ -I${NROOTINC};
190  #  #
191  #       create .so  #       create .so
192  #  #
193          @(${EGREEN} "Creating shared library: "${WHITE} "`basename $@`"; ${RESET})          @(${EGREEN} "Creating shared library: "${WHITE} "`basename $@`"; ${RESET})
194          @${CXX} ${CXXFLAGS} -Xlinker -soname=$(@F) -shared -o $@ -lg2c -I${DIRTOP}/${DIRINC} -I${DIRTOP} -I${PAM_YODA}/include/yoda/ ${SUBINC} ${DIRTOP}/${DIRLIB}/`basename $(@F) _${VER}.so | sed s/lib//`.o ${DIRTOP}/${DIRLIB}/`basename $(@F) _${VER}.so | sed s/lib//`Dict.o 1>/dev/null          @${CXX} ${CXXFLAGS} -Xlinker -soname=$(@F) -shared -o $@ -lg2c -I${DIRTOP}/${DIRINC} -I${DIRTOP} -I${PAM_YODA}/include/yoda/ -I${PAM_INC}/ ${DIRTOP}/${DIRSRC}/`basename $(@F) _${VER}.so | sed s/lib//`.o ${DIRTOP}/${DIRSRC}/`basename $(@F) _${VER}.so | sed s/lib//`Dict.o 1>/dev/null
195          @ln -sf  ${DIRTOP}/${DIRLIB}/$(@F) ${DIRTOP}/${DIRLIB}/$(patsubst %_${VER}.so,%.so,$(@F))          @ln -sf  ${DIRTOP}/${DIRLIB}/$(@F) ${DIRTOP}/${DIRLIB}/$(patsubst %_${VER}.so,%.so,$(@F))
196    
197  ${LIBCPPLIBS}: ${LIBSRCS} ${COBJS} ${FOBJS}  ${LIBCPPLIBS}: ${LIBSRCS} ${COBJS} ${FOBJS}
# Line 173  ${LIBCPPLIBS}: ${LIBSRCS} ${COBJS} ${FOB Line 199  ${LIBCPPLIBS}: ${LIBSRCS} ${COBJS} ${FOB
199  #       create .o  #       create .o
200  #  #
201          @(${EGREEN} "Compiling CPP file: "${WHITE} "`basename $(@F) _${VER}.so | sed s/lib//`.cpp"; ${RESET})          @(${EGREEN} "Compiling CPP file: "${WHITE} "`basename $(@F) _${VER}.so | sed s/lib//`.cpp"; ${RESET})
202          @${CXX} ${CXXFLAGS} -c ${DIRTOP}/${DIRSRC}/`basename $(@F) _${VER}.so | sed s/lib//`.cpp -o ${DIRTOP}/${DIRLIB}/`basename $(@F) _${VER}.so | sed s/lib//`.o -I${DIRTOP}/${DIRINC} -I${DIRTOP} ${SUBINC} -I${PAM_YODA}/include/yoda/ -I${NROOTINC};          @cd ${DIRSRC} &>/dev/null && ${CXX} ${CXXFLAGS} -c `basename $(@F) _${VER}.so | sed s/lib//`.cpp -I${DIRTOP}/${DIRINC} -I${DIRTOP} ${SUBINC} -I${PAM_YODA}/include/yoda/ -I${PAM_INC}/ -I${NROOTINC};
203  #  #
204  #       create .so  #       create .so
205  #  #
206          @(${EGREEN} "Creating shared library: "${WHITE} "`basename $@`"; ${RESET})          @(${EGREEN} "Creating shared library: "${WHITE} "`basename $@`"; ${RESET})
207          @${CXX} ${CXXFLAGS} -Xlinker -soname=$(@F) -shared -o $@ -lg2c -I${DIRTOP}/${DIRINC} -I${DIRTOP} ${SUBINC} -I${PAM_YODA}/include/yoda/ ${DIRTOP}/${DIRLIB}/`basename $(@F) _${VER}.so | sed s/lib//`.o ${FOBJS} ${COBJS} 1>/dev/null          @${CXX} ${CXXFLAGS} -Xlinker -soname=$(@F) -shared -o $@ -lg2c -I${DIRTOP}/${DIRINC} -I${DIRTOP} ${SUBINC} -I${PAM_YODA}/include/yoda/ -I${PAM_INC}/ ${DIRTOP}/${DIRSRC}/`basename $(@F) _${VER}.so | sed s/lib//`.o ${FOBJS} ${COBJS} 1>/dev/null
208          @ln -sf  ${DIRTOP}/${DIRLIB}/$(@F) ${DIRTOP}/${DIRLIB}/$(patsubst %_${VER}.so,%.so,$(@F))          @ln -sf  ${DIRTOP}/${DIRLIB}/$(@F) ${DIRTOP}/${DIRLIB}/$(patsubst %_${VER}.so,%.so,$(@F))
209    
210  ${CXXEXELIBS}: ${CPPOBJS} ${COBJS} ${CXXEXEOBJS}  ${CXXEXELIBS}: ${CPPOBJS} ${COBJS} ${CXXEXEOBJS}
211          @(${EGREEN} "Creating exec file: "${WHITE} "$@"; ${RESET})          @(${EGREEN} "Creating exec file: "${WHITE} "$@"; ${RESET})
212          @${CXX} ${CXXFLAGS} -o ${DIRBIN}/$@ ${DIRLIB}/$@.o ${FULLROOTCLIBS} ${FULLLIBCPPLIBS} ${TRKOBJS} ${CPPOBJS} ${COBJS} ${FOBJS} ${PAM_YODA}/lib/libyoda.so -lThread `root-config --cflags --glibs` `cernlib mathlib`          @${CXX} ${CXXFLAGS} -o ${DIRBIN}/$@ ${DIRTOP}/${DIRLIB}/$@.o ${OBJS} ${PAM_LIB}/libGLTables.so ${PAM_LIB}/libsgp4.so ${PAM_YODA}/lib/libyoda.so -lThread `root-config --cflags --glibs` `${CERNLIB} mathlib`
213            @(${EGREEN} "Creating libDarthVader.so library: "${WHITE} "$@"; ${RESET})
214            @${CXX} ${CXXFLAGS} -Xlinker -soname=libDarthVader_${VER}.so -shared -o ${DIRTOP}/${DIRLIB}/libDarthVader_${VER}.so -lg2c ${DIRTOP}/${DIRLIB}/libAcLevel2.so ${DIRTOP}/${DIRLIB}/libCaloLevel0.so ${DIRTOP}/${DIRLIB}/libCaloLevel1.so ${DIRTOP}/${DIRLIB}/libCaloLevel2.so  ${PAM_LIB}/libsgp4.so ${DIRTOP}/${DIRLIB}/libNDLevel2.so ${DIRTOP}/${DIRLIB}/libS4Level2.so ${DIRTOP}/${DIRLIB}/libToFLevel2.so ${DIRTOP}/${DIRLIB}/libTrigLevel2.so ${DIRTOP}/${DIRLIB}/libTrkLevel2.so ${DIRTOP}/${DIRLIB}/libTrkLevel1.so ${DIRTOP}/${DIRLIB}/libTrkLevel0.so ${DIRTOP}/${DIRLIB}/libTrkHough.so  ${DIRTOP}/${DIRLIB}/libTrkCalib.so ${DIRTOP}/${DIRLIB}/libTrkParams.so ${PAM_LIB}/libGLTables.so ${DIRTOP}/${DIRLIB}/libRunInfo.so ${DIRTOP}/${DIRLIB}/libOrbitalInfo.so ${DIRTOP}/${DIRLIB}/libInclinationInfo.so `${CERNLIB} mathlib`
215    
216    #       @${CXX} ${CXXFLAGS} -o ${DIRBIN}/$@ ${DIRTOP}/${DIRLIB}/$@.o ${OBJS} ${PAM_YODA}/lib/libyoda.so ${PAM_YODA}/lib/libutils.so -lThread `root-config --cflags --glibs` `cernlib mathlib`
217    
218  # A small target to check environmental variables  # A small target to check environmental variables
219  %_env:  %_env:
# Line 201  ${DIRLIB}: Line 231  ${DIRLIB}:
231          @${test_and_mk}          @${test_and_mk}
232    
233  # Here what has to be deleted in clean target  # Here what has to be deleted in clean target
234  clean: TOBEDEL= ${DIRSRC}/*.o ${DIRSRC}/*Dict.cpp ${DIRSRC}/*Dict.h ${FOBJS} ${FULLLIBS} ${DIRBIN}/${CXXEXELIBS} ${CPPOBJS} ${CXXEXEOBJS} ${FULLLINKCLIBS} ${FULLMACROCLIBS} ${FULLLINKMACROCLIBS} ${DIRSRC}/TrigVerl2.cpp  clean:
235  clean:          @for dir in `echo ${SUBDIR}`; do  \
236          @${test_and_rm}           echo "Making clean in $${dir}"; \
237             (cd $${dir} && ${MAKE} clean); \
238            done; make locclean
239    
240  distclean: clean  locclean: TOBEDEL= ${DIRSRC}/*.o ${DIRSRC}/*Dict.cpp ${DIRSRC}/*Dict.h ${FOBJS} ${FULLLIBS} ${DIRBIN}/${CXXEXELIBS} ${CPPOBJS} ${CXXEXEOBJS} ${FULLLINKCLIBS} ${FULLMACROCLIBS} ${FULLLINKMACROCLIBS} ${DIRSRC}/DarthVaderVerl2.cpp
241  distclean: TOBEDEL= ${DIRBIN} ${DIRLIB}  locclean:
 distclean:  
242          @${test_and_rm}          @${test_and_rm}
243    
244    distclean:
245            @for dir in `echo ${SUBDIR}`; do  \
246             echo "Making distclean in $${dir}"; \
247             (cd $${dir} && ${MAKE} distclean); \
248            done; make locdistclean
249    
250    locdistclean: clean
251    locdistclean: TOBEDEL= ${DIRBIN} ${DIRLIB}
252    locdistclean:
253            @${test_and_rm}
254    
 forceinstall: FORCE=-f  
 forceinstall: install  
   
 forceinstallstandalone: FORCE=-f  
 forceinstallstandalone: installstandalone  
   
 upgrade: FORCE=-u  
 upgrade: install  
255    
256  upgradestandalone: FORCE=-u  forceinstall:
257  upgradestandalone: installstandalone          @for dir in `echo ${SUBDIR}`; do  \
258             echo "Making forceinstall in $${dir}"; \
259             (cd $${dir} && ${MAKE} forceinstall); \
260            done; make locforceinstall
261    
262    locforceinstall: FORCE=-f
263    locforceinstall: install
264    
265    upgrade:
266            @for dir in `echo ${SUBDIR}`; do  \
267             echo "Making upgrade in $${dir}"; \
268             (cd $${dir} && ${MAKE} upgrade); \
269            done; make locupgrade
270    
271    locupgrade: FORCE=-u
272    locupgrade: locinstall
273    
274    upgradenc:
275            @for dir in `echo ${SUBDIR}`; do  \
276             echo "Making upgrade in $${dir}"; \
277             (cd $${dir} && ${MAKE} upgrade); \
278            done; make locupgradenc
279    
280    locupgradenc: FORCE=-u
281    locupgradenc: locinstallnc
282    
283    install:
284            @for dir in `echo ${SUBDIR}`; do  \
285             echo "Making install in $${dir}"; \
286             (cd $${dir} && ${MAKE} install); \
287            done; make locinstall
288    
289  install: installlib installinc installmacros installcalib installdoc installcmacro  locinstall: installlib installinc installmacros installcalib installdoc installexe installcmacro
290    
291  installstandalone: install installexe  locinstallnc: installlib installinc installmacros installdoc installexe installcmacro
292    
293  installlib: LINK=y  installlib: LINK=y
294  installlib: TOBEMOVED= $(FULLLIBS:${DIRLIB}%=${PAM_LIB}%)  installlib: TOBEMOVED= $(FULLLIBS:${DIRLIB}%=${PAM_LIB}%)
# Line 257  installmacros: Line 320  installmacros:
320  installcalib: TOBEMOVED= $(CALIBFILES:${DIRCALIB}/%=${PAM_CALIB}/%)  installcalib: TOBEMOVED= $(CALIBFILES:${DIRCALIB}/%=${PAM_CALIB}/%)
321  installcalib: ORIGIN=${DIRCALIB}  installcalib: ORIGIN=${DIRCALIB}
322  installcalib:  installcalib:
323          @${test_and_cp}          @${cp_dir}
324    
325  installdoc: TOBEMOVED= $(DOCFILES:${DIRDOC}/%=${PAM_DOC}/%)  installdoc: TOBEMOVED= $(DOCFILES:${DIRDOC}/%=${PAM_DOC}/%)
326  installdoc: ORIGIN=${DIRDOC}  installdoc: ORIGIN=${DIRDOC}
# Line 265  installdoc: Line 328  installdoc:
328          @${test_and_cp}          @${test_and_cp}
329    
330  mkverpath:  mkverpath:
331          @echo '#include <TSystem.h>' >  ${DIRTOP}/${DIRSRC}/TrigVerl2.cpp; echo ' char *TrigInfo(bool print){ if ( print ) printf("\nTrigger Level2 flight package version: ${VER}\n\nCompiled on '${TODAY}' with: '${GCCVER}'\n\nOn: '${UNAMEA}'\n\n"); return("${VER}"); }' >>  ${DIRTOP}/${DIRSRC}/TrigVerl2.cpp          @echo '#include <TSystem.h>' >  ${DIRTOP}/${DIRSRC}/DarthVaderVerl2.cpp; echo ' char *DarthVaderInfo(bool print){ if ( print ) printf("\nPAMELA Level2 flight package version: ${VER}\n\nCompiled on '${TODAY}' with: '${GCCVER}'\n\nOn: '${UNAMEA}'\n\n"); return("${VER}"); }' >>  ${DIRTOP}/${DIRSRC}/DarthVaderVerl2.cpp
332          @sleep 0.8          @sleep 0.8
333    
334    
# Line 335  fi \ Line 398  fi \
398  done  done
399  endef  endef
400    
401    define  cp_dir
402    wd=`pwd`;\
403    for i in ${TOBEMOVED} ; do \
404    wv=$${i##/*/}; \
405    dest=$${i/$${wv}/}; \
406    ${EYELLOW} " Copying directory: "${WHITE} ${ORIGIN}/$${i##/*/} ;\
407    ${EYELLOW} "          to: "${WHITE} ${PAM_CALIB} ; ${RESET}; \
408    cp -rf ${ORIGIN}/$${i##/*/} ${PAM_CALIB}; \
409    done
410    endef
411    
412  define  test_and_mk  define  test_and_mk
413  ${EGREEN} "Testing for :" ${WHITE} "$@"; ${RESET}  ${EGREEN} "Testing for :" ${WHITE} "$@"; ${RESET}
414  test -d "$@" || \  test -d "$@" || \

Legend:
Removed from v.1.1.1.2  
changed lines
  Added in v.1.42

  ViewVC Help
Powered by ViewVC 1.1.23