--- chewbacca/Makefile 2008/09/23 07:29:29 1.2 +++ chewbacca/Makefile 2008/10/01 10:04:49 1.4 @@ -33,25 +33,33 @@ for sub_dir in $(DIRS) ; do \ ( cd $$sub_dir && make distclean) ; \ done + for sub_dir in `find ./ -name obj` ; do \ + rm -rf $$sub_dir ; \ + done install: - if [ "$(PAM_SOFTWARE)" == "" ]; then echo "";\ + @echo " Creating PAMELA environment " + @if [ "$(PAM_SOFTWARE)" == "" ]; then echo "";\ echo "PLEASE SET THE PAMELA ENVIRONMENT BEFORE INSTALLING";\ echo ""; \ exit; fi - if [ ! -d $(PAM_SOFTWARE) ]; then mkdir $(PAM_SOFTWARE); fi - if [ ! -d $(PAM_LIB) ]; then mkdir $(PAM_LIB); fi - if [ ! -d $(PAM_INC) ]; then mkdir $(PAM_INC); fi - ln -sf $(PAM_SOFTWARE)/inc $(PAM_SOFTWARE)/include - if [ ! -d $(PAM_BIN) ]; then mkdir $(PAM_BIN); fi - if [ ! -d $(PAM_DOC) ]; then mkdir $(PAM_DOC); fi - if [ ! -d $(PAM_MACROS) ]; then mkdir $(PAM_MACROS); fi - if [ ! -d $(PAM_SRC) ]; then mkdir $(PAM_SRC); fi - if [ ! -d $(PAM_CALIB) ]; then mkdir $(PAM_CALIB); fi - if [ ! -d $(FEV_PLUGIN) ]&&[ "$(FEV_PLUGIN)" != "" ]; then mkdir $(FEV_PLUGIN); fi - cp -f $(BASEDIR)/event/libyoda.so.0.0.0 $(PAM_LIB)/ - ln -sf $(PAM_LIB)/libyoda.so.0.0.0 $(PAM_LIB)/libyoda.so - ln -sf $(PAM_LIB)/libyoda.so.0.0.0 $(PAM_LIB)/libyoda.so.0 - cp -rf $(BASEDIR)/event/ $(PAM_INC)/yoda/ - cp -f $(BASEDIR)/PamOffLineSW/chewbacca $(PAM_BIN)/ - (cd YodaProfiler && make forceinstall) + @if [ ! -d $(PAM_HOME) ]; then mkdir $(PAM_HOME); fi + @if [ ! -d $(PAM_SOFTWARE) ]; then mkdir $(PAM_SOFTWARE); fi + @if [ ! -d $(PAM_LIB) ]; then mkdir $(PAM_LIB); fi + @if [ ! -d $(PAM_INC) ]; then mkdir $(PAM_INC); fi + @ln -sf $(PAM_SOFTWARE)/inc $(PAM_SOFTWARE)/include + @if [ ! -d $(PAM_BIN) ]; then mkdir $(PAM_BIN); fi + @if [ ! -d $(PAM_DOC) ]; then mkdir $(PAM_DOC); fi + @if [ ! -d $(PAM_MACROS) ]; then mkdir $(PAM_MACROS); fi + @if [ ! -d $(PAM_SRC) ]; then mkdir $(PAM_SRC); fi + @if [ ! -d $(PAM_CALIB) ]; then mkdir $(PAM_CALIB); fi + @if [ ! -d $(FEV_PLUGIN) ]&&[ "$(FEV_PLUGIN)" != "" ]; then mkdir $(FEV_PLUGIN); fi + @echo " Installing libyoda.so " + @cp -f $(BASEDIR)/event/libyoda.so.0.0.0 $(PAM_LIB)/ + @ln -sf $(PAM_LIB)/libyoda.so.0.0.0 $(PAM_LIB)/libyoda.so + @ln -sf $(PAM_LIB)/libyoda.so.0.0.0 $(PAM_LIB)/libyoda.so.0 + @echo " Installing chewbacca executable " + @cp -f $(BASEDIR)/PamOffLineSW/chewbacca $(PAM_BIN)/ + @echo " Installing yoda headers " + @cp -rf $(BASEDIR)/event/ $(PAM_INC)/yoda/ + @(cd YodaProfiler && make forceinstall)