Index: palm/trunk/SCRIPTS/palmbuild
===================================================================
--- palm/trunk/SCRIPTS/palmbuild	(revision 2506)
+++ palm/trunk/SCRIPTS/palmbuild	(revision 2566)
@@ -27,4 +27,8 @@
 # -----------------
 # $Id$
+# informative messages switched of almost completely in silent mode
+# two header blocks merged into one
+# 
+# 2506 2017-09-29 08:30:37Z raasch
 # option -V added to check for an existing SOURCES_FOR_RUN_... folder
 # host configuration added to SOURCES_FOR_RUN_... folder name
@@ -82,5 +86,8 @@
           exit 1
        else
-          printf "\n\n *** palmbuild finished \n\n"
+          if [[ $silent = false ]]
+          then
+             printf "\n\n *** palmbuild finished \n\n"
+          fi
           exit 0
        fi
@@ -295,88 +302,48 @@
 
     # HEADER-OUTPUT (PART1: MESSAGES CONCERNING THE LOCAL HOST)
- calltime=$(date)
- printf "\n"
- printf "#------------------------------------------------------------------------# \n"
- printf "| %-40s%30s | \n" "$version" "$calltime"
- printf "|                                                                        | \n"
- printf "| %-13s%-57s | \n" "called on:" "$(hostname) (IP:$local_ip)"
- column2=$(echo $config_file | cut -c1-57 )
- printf "| %-13s%-57s | \n" "config file:" "$column2"
- line=$(echo "$config_file" | cut -c58-)
- while [[ "$line" != "" ]]
- do
-    column1=""
-    column2=$(echo $line | cut -c1-57 )
-    printf "| %-13s%-57s | \n" "$column1" "$column2"
-    line=$(echo "$line" | cut -c58-)
- done
- column2=$(echo $makefile | cut -c1-57 )
- printf "| %-13s%-57s | \n" "makefile:" "$column2"
- line=$(echo "$makefile" | cut -c58-)
- while [[ "$line" != "" ]]
- do
-    column1=""
-    column2=$(echo $line | cut -c1-57 )
-    printf "| %-13s%-57s | \n" "$column1" "$column2"
-    line=$(echo "$line" | cut -c58-)
- done
- column2=$(echo $source_path | cut -c1-57 )
- printf "| %-13s%-57s | \n" "source path:" "$column2"
- line=$(echo "$source_path" | cut -c58-)
- while [[ "$line" != "" ]]
- do
-    column1=""
-    column2=$(echo $line | cut -c1-57 )
-    printf "| %-13s%-57s | \n" "$column1" "$column2"
-    line=$(echo "$line" | cut -c58-)
- done
- printf "#------------------------------------------------------------------------# \n"
-
-
-
-    # TAR THE SOURCES AND MAKEFILES
-    # UTILITIES ARE TEMPORARILY COPIED TO THE SOURCE DIRECTORY IN ORDER TO TAR
-    # THEM TOO
- cd  $source_path
- printf "\n\n  *** tar of makefile and source files in"
- printf "\n      $source_path"
- cp -p  ../UTIL/combine_plot_fields.f90  .
- cp -p  ../UTIL/compare_palm_logs.f90  .
- cp -p  ../UTIL/Makefile_utilities  .
- tar -cf  ${program_name}_sources.tar  Makefile*  *.$suf
- rm  combine_plot_fields.f90  compare_palm_logs.f90  Makefile_utilities
- printf "\n"
-
-
-
-    # GET CONFIRMATION TO CONTINUE
- printf "\n  *** update will be made for host configuration \"$host_configuration\" "
-
-
  if [[ $silent = false ]]
  then
-    answer=dummy
-    printf "\n\n"
-    while [[ "$answer" != y  &&  "$answer" != Y  &&  "$answer" != n  &&  "$answer" != N ]]
+    calltime=$(date)
+    printf "\n"
+    printf "#------------------------------------------------------------------------# \n"
+    printf "| %-40s%30s | \n" "$version" "$calltime"
+    printf "|                                                                        | \n"
+    printf "| %-13s%-57s | \n" "called on:" "$(hostname) (IP:$local_ip)"
+    column2=$(echo $config_file | cut -c1-57 )
+    printf "| %-13s%-57s | \n" "config file:" "$column2"
+    line=$(echo "$config_file" | cut -c58-)
+    while [[ "$line" != "" ]]
     do
-       printf " >>> continue (y/n) ?  "
-       read  answer
+       column1=""
+       column2=$(echo $line | cut -c1-57 )
+       printf "| %-13s%-57s | \n" "$column1" "$column2"
+       line=$(echo "$line" | cut -c58-)
     done
-    if [[ $answer = n  ||  $answer = N ]]
-    then
-       locat=user_abort; exit
-    fi
- fi
-
-
-
-
-    printf "\n\n#------------------------------------------------------------------------# \n"
-
+    column2=$(echo $makefile | cut -c1-57 )
+    printf "| %-13s%-57s | \n" "makefile:" "$column2"
+    line=$(echo "$makefile" | cut -c58-)
+    while [[ "$line" != "" ]]
+    do
+       column1=""
+       column2=$(echo $line | cut -c1-57 )
+       printf "| %-13s%-57s | \n" "$column1" "$column2"
+       line=$(echo "$line" | cut -c58-)
+    done
+    column2=$(echo $source_path | cut -c1-57 )
+    printf "| %-13s%-57s | \n" "source path:" "$column2"
+    line=$(echo "$source_path" | cut -c58-)
+    while [[ "$line" != "" ]]
+    do
+       column1=""
+       column2=$(echo $line | cut -c1-57 )
+       printf "| %-13s%-57s | \n" "$column1" "$column2"
+       line=$(echo "$line" | cut -c58-)
+    done
+    printf "|                                                                        | \n"
+   
     if [[ "$remote_ip" != "" ]]
     then
        column2="$host_configuration"
-       printf "| %-20s%-50s | \n" "host identifier:" "$column2"
-       printf "|                                                                        | \n"
+       printf "| %-20s%-50s | \n" "host configuration:" "$column2"
        column2=$(echo "$make_depository" | cut -c1-50 )
        printf "| %-20s%-50s | \n" "remote depository:" "$column2"
@@ -384,5 +351,4 @@
        column2="$host_configuration"
        printf "| %-20s%-50s | \n" "host identifier:" "$column2"
-       printf "|                                                                        | \n"
        column2=$(echo "$make_depository" | cut -c1-50 )
        printf "| %-20s%-50s | \n" "local depository:" "$column2"
@@ -396,5 +362,5 @@
        line=$(echo "$line" | cut -c51-)
     done
-
+   
     if [[ "$remote_ip" != "" ]]
     then
@@ -405,8 +371,8 @@
        printf "| %-20s%-50s | \n" "address:" "$local_ip"
     fi
-
+   
     printf "| %-20s%-50s | \n" "compiler:" "$compiler_name"
     printf "| %-20s%-50s | \n" "serial compiler:" "$compiler_name_ser"
-
+   
     if [[ "$make_options" != "" ]]
     then
@@ -471,98 +437,212 @@
     printf "#------------------------------------------------------------------------# \n"
 
-    if [[ $silent = false ]]
-    then
-       answer=dummy
-       printf "\n\n"
-       while [[ "$answer" != y  &&  "$answer" != Y  && "$answer" != c  &&  "$answer" != C  && "$answer" != s  &&  "$answer" != S  &&  "$answer" != a  &&  "$answer" != A ]]
-       do
-          printf " >>> continue (y(es)/c(ontinue)/a(bort)) ?  "
-          read  answer
-       done
-       if [[ $answer = a  ||  $answer = A ]]
-       then
-          locat=user_abort; exit
-       fi
-       if [[ $answer = c  ||  $answer = C ]]
-       then
-          silent=true
-       fi
-    fi
-
-
-       # MAKE ON REMOTE HOST
-    if [[ "$remote_ip" != "" ]]
-    then
-
-          # NEXT IS THE BRANCH FOR CREATING THE MAKE_DEPOSITORY_...
-       if [[ "$fname" = "" ]]
-       then
-
-             # COPY CURRENT SOURCE CODE TO SOURCE-CODE DIRECTORY ON THE REMOTE HOST
-             # CREATE THIS DIRECTORY, IF IT DOES NOT EXIST
+    answer=dummy
+    printf "\n"
+    while [[ "$answer" != y  &&  "$answer" != Y  && "$answer" != c  &&  "$answer" != C  && "$answer" != s  &&  "$answer" != S  &&  "$answer" != a  &&  "$answer" != A ]]
+    do
+       printf " >>> continue (y(es)/c(ontinue)/a(bort)) ?  "
+       read  answer
+    done
+    if [[ $answer = a  ||  $answer = A ]]
+    then
+       locat=user_abort; exit
+    fi
+    if [[ $answer = c  ||  $answer = C ]]
+    then
+       silent=true
+    fi
+ fi
+
+
+    # TAR THE SOURCES AND MAKEFILES
+    # UTILITIES ARE TEMPORARILY COPIED TO THE SOURCE DIRECTORY IN ORDER TO TAR
+    # THEM TOO
+ if [[ $silent = false ]]
+ then
+    printf "\n\n  *** tar of makefile and source files in"
+    printf "\n      $source_path\n"
+ fi
+ cd  $source_path
+ cp -p  ../UTIL/combine_plot_fields.f90  .
+ cp -p  ../UTIL/compare_palm_logs.f90  .
+ cp -p  ../UTIL/Makefile_utilities  .
+ tar -cf  ${program_name}_sources.tar  Makefile*  *.$suf
+ rm  combine_plot_fields.f90  compare_palm_logs.f90  Makefile_utilities
+
+
+    # MAKE ON REMOTE HOST
+ if [[ "$remote_ip" != "" ]]
+ then
+
+       # NEXT IS THE BRANCH FOR CREATING THE MAKE_DEPOSITORY_...
+    if [[ "$fname" = "" ]]
+    then
+
+          # COPY CURRENT SOURCE CODE TO SOURCE-CODE DIRECTORY ON THE REMOTE HOST
+          # CREATE THIS DIRECTORY, IF IT DOES NOT EXIST
+       if [[ $silent = false ]]
+       then
+          echo " "
           echo "  *** copying \"${program_name}_sources.tar\" to \"${remote_ip}:${make_depository}/\" "
           echo "[[ ! -d ${make_depository} ]]  &&  (echo \"  *** ${make_depository} will be created\"; mkdir -p  ${make_depository})"  |  ssh  -q  $ssh_key ${remote_username}@${remote_ip}  2>&1
-
           scp  $ssh_key ${source_path}/${program_name}_sources.tar  ${remote_username}@${remote_ip}:${make_depository}/${program_name}_sources.tar
-
-
-
-             # UNTAR PREVIOUS UPDATE ON REMOTE HOST, IF EXISTING
+       else
+          echo "[[ ! -d ${make_depository} ]]  &&  mkdir -p  ${make_depository}"  |  ssh  -q  $ssh_key ${remote_username}@${remote_ip}  2>&1
+          scp  $ssh_key ${source_path}/${program_name}_sources.tar  ${remote_username}@${remote_ip}:${make_depository}/${program_name}_sources.tar  >  /dev/null
+       fi
+
+
+
+
+          # UNTAR PREVIOUS UPDATE ON REMOTE HOST, IF EXISTING
+       if [[ $silent = false ]]
+       then
           echo "  *** untar previous update on remote host, if existing"
-          echo "cd ${make_depository}; [[ -f ${program_name}_current_version.tar ]]  &&  tar -xf  ${program_name}_current_version.tar"  |  ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  2>&1
-
-
-             # UNTAR CURRENT SOURCES ON REMOTE HOST
+       fi
+       echo "cd ${make_depository}; [[ -f ${program_name}_current_version.tar ]]  &&  tar -xf  ${program_name}_current_version.tar"  |  ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  2>&1
+
+
+          # UNTAR CURRENT SOURCES ON REMOTE HOST
+       if [[ $silent = false ]]
+       then
           echo "  *** untar current sources on remote host"
-          echo  "cd ${make_depository}; tar -xf  ${program_name}_sources.tar"  |  ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  2>&1
-
-
-             # CREATE INIT AND MODULE COAMMNDS
+       fi
+       echo  "cd ${make_depository}; tar -xf  ${program_name}_sources.tar"  |  ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  2>&1
+
+
+          # CREATE INIT AND MODULE COAMMNDS
+       [[ "$login_init_cmd" != "" ]]   &&  login_init_cmd=${login_init_cmd}";"
+       [[ "$module_commands" != "" ]]  &&  module_commands=${module_commands}";"
+
+
+          # FIRST CREATE EXECUTABLES FOR THE UTILITY ROUTINES
+       if [[ $silent = false ]]
+       then
+          echo " "
+          echo "  *** creating utilities on remote host"
+       fi
+       make_call_string="make  -f Makefile_utilities  $make_options  F90=$compiler_name  F90_SER=$compiler_name_ser  COPT=\"$cpp_options\"  F90FLAGS=\"$compiler_options\"  LDFLAGS=\"$linker_options\" "
+       echo "$login_init_cmd $module_commands cd ${make_depository}; echo $make_call_string > LAST_MAKE_CALL; chmod u+x LAST_MAKE_CALL; $make_call_string; [[ \$? != 0 ]] && echo MAKE_ERROR" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1 | tee ${host_configuration}_last_make_protocol
+
+       if [[ $(grep -c MAKE_ERROR ${host_configuration}_last_make_protocol) != 0 ]]
+       then
+          printf "\a\n  +++ error(s) occurred during compiling or linking of utilities"
+          printf "\n      for host configuration \"$host_configuration\" "
+          if [[ $silent = false ]]
+          then
+             answer=dummy
+             printf "\n"
+             while [[ "$answer" != c  &&  "$answer" != k ]]
+             do
+                printf "  >>> continue / list errors / kill palmbuild (c/l/k) ? "
+                read  answer
+                if [[ "$answer" = l ]]
+                then
+                   more ${host_configuration}_last_make_protocol
+                fi
+             done
+             if [[ $answer = k ]]
+             then
+                locat=user_abort; exit
+             fi
+          else
+                # ABORT ANYWAY
+             locat=user_abort; exit
+          fi
+       fi
+
+
+          # NOW COMPILE THE PALM CODE
+          # COMMANDS WILL BE COMMUNICATED TO SSH VIA PIPE, SINCE THIS WAY THE SYSTEM- AND
+          # USER-PROFILES OF THE SHELL ARE COMPLETELY EXECUTED (OTHERWISE, MAKE
+          # MAY E.G. MISS THE COMPILER-PATHS)
+       if [[ $silent = false ]]
+       then
+          echo " "
+          echo "  *** compile PALM sources on remote host"
+       fi
+       make_call_string="make  $make_options  PROG=$program_name  F90=$compiler_name  COPT=\"$cpp_options\"  F90FLAGS=\"$compiler_options\"  LDFLAGS=\"$linker_options\" "
+       echo "$login_init_cmd $module_commands cd ${make_depository}; echo $make_call_string > LAST_MAKE_CALL; chmod u+x LAST_MAKE_CALL; $make_call_string; [[ \$? != 0 ]] && echo MAKE_ERROR" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1 | tee ${host_configuration}_last_make_protocol
+
+       if [[ $(grep -c MAKE_ERROR ${host_configuration}_last_make_protocol) != 0 ]]
+       then
+          printf "\a\n  +++ error(s) occurred during compiling or linking for host configuration \"$host_configuration\" "
+          if [[ $silent = false ]]
+          then
+             answer=dummy
+             printf "\n"
+             while [[ "$answer" != c  &&  "$answer" != k ]]
+             do
+                printf "  >>> continue / list errors / kill palmbuild (c/l/k) ? "
+                read  answer
+                if [[ "$answer" = l ]]
+                then
+                   more ${host_configuration}_last_make_protocol
+                fi
+             done
+             if [[ $answer = k ]]
+             then
+                locat=user_abort; exit
+             fi
+          else
+                # ABORT ANYWAY
+             locat=user_abort; exit
+          fi
+       fi
+
+          # TAR UPDATED VERSION ON THE REMOTE HOST
+       if [[ $silent = false ]]
+       then
+          printf "\n  *** tar update on remote host ..."
+       fi
+       echo  "cd ${make_depository}; chmod u+w *; tar -cf  ${program_name}_current_version.tar  ${program_name}  *.f90 *.o *.mod *.x"  |  ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  2>&1
+
+
+       # NOW COMES THE BRANCH FOR CREATING THE EXECUTABLE FOR THE CURRENT RUN
+       # INCLUDING E.G. USER-INTERFACE ROUTINES. ALSO ADD OTHER UTILITY EXECUTABLES. EVERYTHING IS
+       # COLLECTED IN DIRECTORY SOURCES_FOR_RUN_...
+    elif [[ "$fname" != "" ]]
+    then
+
+          # FIRST CHECK, IF COMPILED SOURCES FOR THIS RUN IDENTIFIER EXISTS
+          # AND ASK, IF THEY SHALL BE USED
+       echo  "[[ -d ${fast_io_catalog}/${sources_for_run_catalog} ]]  &&  echo sources for run found" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1  >  ${host_configuration}_last_make_protocol
+       if [[ $(grep -c "sources for run found" ${host_configuration}_last_make_protocol) != 0  &&  $use_existing_sources_folder = true ]]
+       then
+          printf "\a\n  *** compiled sources for run \"$fname\" found on remote host in folder"
+          printf "\n      ${fast_io_catalog}/${sources_for_run_catalog}"
+          printf "\n      will be used!"
+          exit
+       fi
+
+          # COPY MAKE DEPOSITORY ON REMOTE MACHINE TO SOURCES_FOR_RUN_...
+       if [[ $silent = false ]]
+       then
+          printf "\n  *** copy MAKE_DEPOSITORY_${host_configuration} on remote host to $sources_for_run_catalog \n"
+       fi
+       echo  "rm -rf ${fast_io_catalog}/${sources_for_run_catalog}; mkdir -p ${fast_io_catalog}/${sources_for_run_catalog}; cp ${make_depository}/${program_name}_current_version.tar  ${fast_io_catalog}/${sources_for_run_catalog}; cd ${fast_io_catalog}/${sources_for_run_catalog}; tar xf ${program_name}_current_version.tar"  |  ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  2>&1
+
+
+          # COPY CONTENTS OF SOURCES_FOR_RUN_... TO SOURCES_FOR_RUN_... ON THE REMOTE MACHINE
+       if [[ $silent = false ]]
+       then
+          printf "\n  *** copy ${base_directory}/${sources_for_run_catalog}"
+          printf "\n      to $sources_for_run_catalog on remote host \n"
+       fi
+       scp  -q  $ssh_key  ${base_directory}/${sources_for_run_catalog}/{*,.[!.]*}  ${remote_username}@${remote_ip}:${fast_io_catalog}/${sources_for_run_catalog}
+
+
+          # CREATE EXECUTABLE FROM THE NEW/MODIFIED SOURCE FILES, IF THERE ARE ANY
+       if [[ $(ls -1 ${base_directory}/${sources_for_run_catalog}/ | grep -c .$suf) != 0 ]]
+       then
+
+          make_call_string="make  $make_options  PROG=$program_name  F90=$compiler_name  COPT=\"$cpp_options\"  F90FLAGS=\"$compiler_options\"  LDFLAGS=\"$linker_options\" "
           [[ "$login_init_cmd" != "" ]]   &&  login_init_cmd=${login_init_cmd}";"
           [[ "$module_commands" != "" ]]  &&  module_commands=${module_commands}";"
-
-
-             # FIRST CREATE EXECUTABLES FOR THE UTILITY ROUTINES
-          echo " "
-          echo "  *** creating utilities on remote host"
-          make_call_string="make  -f Makefile_utilities  $make_options  F90=$compiler_name  F90_SER=$compiler_name_ser  COPT=\"$cpp_options\"  F90FLAGS=\"$compiler_options\"  LDFLAGS=\"$linker_options\" "
-          echo "$login_init_cmd $module_commands cd ${make_depository}; echo $make_call_string > LAST_MAKE_CALL; chmod u+x LAST_MAKE_CALL; $make_call_string; [[ \$? != 0 ]] && echo MAKE_ERROR" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1 | tee ${host_configuration}_last_make_protocol
-
-          if [[ $(grep -c MAKE_ERROR ${host_configuration}_last_make_protocol) != 0 ]]
-          then
-             printf "\a\n  +++ error(s) occurred during compiling or linking of utilities"
-             printf "\n      for host configuration \"$host_configuration\" "
-             if [[ $silent = false ]]
-             then
-                answer=dummy
-                printf "\n"
-                while [[ "$answer" != c  &&  "$answer" != k ]]
-                do
-                   printf "  >>> continue / list errors / kill palmbuild (c/l/k) ? "
-                   read  answer
-                   if [[ "$answer" = l ]]
-                   then
-                      more ${host_configuration}_last_make_protocol
-                   fi
-                done
-                if [[ $answer = k ]]
-                then
-                   locat=user_abort; exit
-                fi
-             else
-                   # ABORT ANYWAY
-                locat=user_abort; exit
-             fi
-          fi
-
-
-             # NOW COMPILE THE PALM CODE
-             # COMMANDS WILL BE COMMUNICATED TO SSH VIA PIPE, SINCE THIS WAY THE SYSTEM- AND
-             # USER-PROFILES OF THE SHELL ARE COMPLETELY EXECUTED (OTHERWISE, MAKE
-             # MAY E.G. MISS THE COMPILER-PATHS)
-          echo " "
-          echo "  *** compile PALM sources on remote host"
-          make_call_string="make  $make_options  PROG=$program_name  F90=$compiler_name  COPT=\"$cpp_options\"  F90FLAGS=\"$compiler_options\"  LDFLAGS=\"$linker_options\" "
-          echo "$login_init_cmd $module_commands cd ${make_depository}; echo $make_call_string > LAST_MAKE_CALL; chmod u+x LAST_MAKE_CALL; $make_call_string; [[ \$? != 0 ]] && echo MAKE_ERROR" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1 | tee ${host_configuration}_last_make_protocol
+          if [[ $silent = false ]]
+          then
+             echo "  *** execute \"make\" on remote host"
+          fi
+          echo "$login_init_cmd $module_commands cd ${fast_io_catalog}/${sources_for_run_catalog}; echo $make_call_string > LAST_MAKE_CALL; chmod u+x LAST_MAKE_CALL; $make_call_string; [[ \$? != 0 ]] && echo MAKE_ERROR" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1 | tee ${host_configuration}_last_make_protocol
 
           if [[ $(grep -c MAKE_ERROR ${host_configuration}_last_make_protocol) != 0 ]]
@@ -584,155 +664,195 @@
                 if [[ $answer = k ]]
                 then
+                   echo "rm -rf ${fast_io_catalog}/${sources_for_run_catalog}" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1
                    locat=user_abort; exit
                 fi
              else
                    # ABORT ANYWAY
+                echo "rm -rf ${fast_io_catalog}/${sources_for_run_catalog}" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1
                 locat=user_abort; exit
              fi
           fi
 
-             # TAR UPDATED VERSION ON THE REMOTE HOST
-          printf "\n  *** tar update on remote host ..."
-          echo  "cd ${make_depository}; chmod u+w *; tar -cf  ${program_name}_current_version.tar  ${program_name}  *.f90 *.o *.mod *.x"  |  ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  2>&1
-
-
-          # NOW COMES THE BRANCH FOR CREATING THE EXECUTABLE FOR THE CURRENT RUN
-          # INCLUDING E.G. USER-INTERFACE ROUTINES. ALSO ADD OTHER UTILITY EXECUTABLES. EVERYTHING IS
-          # COLLECTED IN DIRECTORY SOURCES_FOR_RUN_...
-       elif [[ "$fname" != "" ]]
-       then
-
-             # FIRST CHECK, IF COMPILED SOURCES FOR THIS RUN IDENTIFIER EXISTS
-             # AND ASK, IF THEY SHALL BE USED
-          echo  "[[ -d ${fast_io_catalog}/${sources_for_run_catalog} ]]  &&  echo sources for run found" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1  >  ${host_configuration}_last_make_protocol
-          if [[ $(grep -c "sources for run found" ${host_configuration}_last_make_protocol) != 0  &&  $use_existing_sources_folder = true ]]
-          then
-             printf "\a\n  *** compiled sources for run \"$fname\" found on remote host in folder"
-             printf "\n      ${fast_io_catalog}/${sources_for_run_catalog}"
-             printf "\n      will be used!"
-             exit
-          fi
-
-             # COPY MAKE DEPOSITORY ON REMOTE MACHINE TO SOURCES_FOR_RUN_...
-          printf "\n  *** copy MAKE_DEPOSITORY_${host_configuration} on remote host to $sources_for_run_catalog \n"
-          echo  "rm -rf ${fast_io_catalog}/${sources_for_run_catalog}; mkdir -p ${fast_io_catalog}/${sources_for_run_catalog}; cp ${make_depository}/${program_name}_current_version.tar  ${fast_io_catalog}/${sources_for_run_catalog}; cd ${fast_io_catalog}/${sources_for_run_catalog}; tar xf ${program_name}_current_version.tar"  |  ssh  -q  $ssh_key  ${remote_username}@${remote_ip}  2>&1
-
-
-             # COPY CONTENTS OF SOURCES_FOR_RUN_... TO SOURCES_FOR_RUN_... ON THE REMOTE MACHINE
-          printf "\n  *** copy ${base_directory}/${sources_for_run_catalog}"
-          printf "\n      to $sources_for_run_catalog on remote host \n"
-          scp  -q  $ssh_key  ${base_directory}/${sources_for_run_catalog}/{*,.[!.]*}  ${remote_username}@${remote_ip}:${fast_io_catalog}/${sources_for_run_catalog}
-
-
-             # CREATE EXECUTABLE FROM THE NEW/MODIFIED SOURCE FILES, IF THERE ARE ANY
-          if [[ $(ls -1 ${base_directory}/${sources_for_run_catalog}/ | grep -c .$suf) != 0 ]]
-          then
-
-             make_call_string="make  $make_options  PROG=$program_name  F90=$compiler_name  COPT=\"$cpp_options\"  F90FLAGS=\"$compiler_options\"  LDFLAGS=\"$linker_options\" "
-             [[ "$login_init_cmd" != "" ]]   &&  login_init_cmd=${login_init_cmd}";"
-             [[ "$module_commands" != "" ]]  &&  module_commands=${module_commands}";"
-             echo "  *** execute \"make\" on remote host"
-             echo "$login_init_cmd $module_commands cd ${fast_io_catalog}/${sources_for_run_catalog}; echo $make_call_string > LAST_MAKE_CALL; chmod u+x LAST_MAKE_CALL; $make_call_string; [[ \$? != 0 ]] && echo MAKE_ERROR" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1 | tee ${host_configuration}_last_make_protocol
-
-             if [[ $(grep -c MAKE_ERROR ${host_configuration}_last_make_protocol) != 0 ]]
-             then
-                printf "\a\n  +++ error(s) occurred during compiling or linking for host configuration \"$host_configuration\" "
-                if [[ $silent = false ]]
-                then
-                   answer=dummy
-                   printf "\n"
-                   while [[ "$answer" != c  &&  "$answer" != k ]]
-                   do
-                      printf "  >>> continue / list errors / kill palmbuild (c/l/k) ? "
-                      read  answer
-                      if [[ "$answer" = l ]]
-                      then
-                         more ${host_configuration}_last_make_protocol
-                      fi
-                   done
-                   if [[ $answer = k ]]
-                   then
-                      echo "rm -rf ${fast_io_catalog}/${sources_for_run_catalog}" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1
-                      locat=user_abort; exit
-                   fi
-                else
-                      # ABORT ANYWAY
-                   echo "rm -rf ${fast_io_catalog}/${sources_for_run_catalog}" | ssh  -q  $ssh_key  ${remote_username}@${remote_ip} 2>&1
-                   locat=user_abort; exit
-                fi
-             fi
-
-          else
-
-             echo "  *** nothing to compile for this run"
-
-          fi
-
-       fi
-
-       rm -rf  ${source_path}/${host_configuration}_last_make_protocol
-
-
-       # MAKE ON LOCAL HOST
-    else
-
-
-          # NEXT IS THE BRANCH FOR CREATING THE MAKE_DEPOSITORY_... ON THE
-          # LOCAL HOST
-       if [[ "$fname" = "" ]]
-       then
-
-             # SET THE ENVIRONMENT (EXECUTE INIT AND MODULE COMMANDS)
-          if [[ "$login_init_cmd" != "" ]]
-          then
-             $login_init_cmd
-          fi
-
-          if [[ "$module_commands" != "" ]]
-          then
-             $module_commands
-          fi
-
-
-             # CREATE MAKE-DEPOSITORY, IF IT DOES NOT EXIST
-          eval make_depository=$make_depository
-          if [[ ! -d $make_depository ]]
-          then
-             if  mkdir -p $make_depository
+       else
+
+          echo "  *** nothing to compile for this run"
+
+       fi
+
+    fi
+
+    rm -rf  ${source_path}/${host_configuration}_last_make_protocol
+
+
+    # MAKE ON LOCAL HOST
+ else
+
+
+       # NEXT IS THE BRANCH FOR CREATING THE MAKE_DEPOSITORY_... ON THE
+       # LOCAL HOST
+    if [[ "$fname" = "" ]]
+    then
+
+          # SET THE ENVIRONMENT (EXECUTE INIT AND MODULE COMMANDS)
+       if [[ "$login_init_cmd" != "" ]]
+       then
+          $login_init_cmd
+       fi
+
+       if [[ "$module_commands" != "" ]]
+       then
+          $module_commands
+       fi
+
+
+          # CREATE MAKE-DEPOSITORY, IF IT DOES NOT EXIST
+       eval make_depository=$make_depository
+       if [[ ! -d $make_depository ]]
+       then
+          if  mkdir -p $make_depository
+          then
+             if [[ $silent = false ]]
              then
                 printf "\n\n  *** directory for local make depository:"
                 printf "\n           $make_depository"
                 printf "\n      was created\n"
-             else
-                printf "\n  +++ directory for local make depository:"
-                printf "\n           $make_depository"
-                printf "\n      cannot be created"
-                locat=local_depository; exit
              fi
-          fi
-
-             # COPY SOURCE-CODE FROM REPOSITORY TO MAKE-DEPOSITORY
+          else
+             printf "\n  +++ directory for local make depository:"
+             printf "\n           $make_depository"
+             printf "\n      cannot be created"
+             locat=local_depository; exit
+          fi
+       fi
+
+          # COPY SOURCE-CODE FROM REPOSITORY TO MAKE-DEPOSITORY
+       if [[ $silent = false ]]
+       then
           echo " "
           echo "  *** untar current source sources on local host in"
           echo "      $make_depository"
-          cd  $make_depository
-          cp  $source_path/${program_name}_sources.tar  .
-          tar xf  ${program_name}_sources.tar
-
-
-             # FIRST CREATE EXECUTABLES FOR THE UTILITY ROUTINES
+       fi
+       cd  $make_depository
+       cp  $source_path/${program_name}_sources.tar  .
+       tar xf  ${program_name}_sources.tar
+
+
+          # FIRST CREATE EXECUTABLES FOR THE UTILITY ROUTINES
+       if [[ $silent = false ]]
+       then
           echo " "
           echo "  *** creating utilities on local host"
-          make  -f Makefile_utilities  $make_options  F90=$compiler_name  F90_SER=$compiler_name_ser  COPT="$cpp_options"  F90FLAGS="$compiler_options"  LDFLAGS="$linker_options"
-
-
-             # CALL MAKE ON LOCAL HOST USING THE  OPTIONS DETERMINED FURTHER ABOVE
+       fi
+       make  -f Makefile_utilities  $make_options  F90=$compiler_name  F90_SER=$compiler_name_ser  COPT="$cpp_options"  F90FLAGS="$compiler_options"  LDFLAGS="$linker_options"
+
+
+          # CALL MAKE ON LOCAL HOST USING THE  OPTIONS DETERMINED FURTHER ABOVE
+       if [[ $silent = false ]]
+       then
           echo " "
           echo "  *** compile PALM sources on local host"
-
-          make  $make_options  PROG=$program_name  F90=$compiler_name  COPT="$cpp_options"  F90FLAGS="$compiler_options"  LDFLAGS="$linker_options"  2>&1 | tee ${host_configuration}_last_make_protocol
+       fi
+
+       make  $make_options  PROG=$program_name  F90=$compiler_name  COPT="$cpp_options"  F90FLAGS="$compiler_options"  LDFLAGS="$linker_options"  2>&1 | tee ${host_configuration}_last_make_protocol
+
+       if [[ $? != 0 ]]
+       then
+          printf "\a\n  +++ error(s) occurred during compiling or linking for host configuration \"$host_configuration\" "
+          if [[ $silent = false ]]
+          then
+             answer=dummy
+             printf "\n"
+             while [[ "$answer" != c  &&  "$answer" != k ]]
+             do
+                printf "  >>> continue / list errors / kill palmbuild (c/l/k) ? "
+                read  answer
+                if [[ "$answer" = l ]]
+                then
+                   more ${host_configuration}_last_make_protocol
+                fi
+             done
+             if [[ $answer = k ]]
+             then
+                locat=user_abort; exit
+             fi
+          else
+                # ABORT ANYWAY
+             locat=user_abort; exit
+          fi
+       fi
+
+
+          # TAR NEW VERSION ON LOCAL HOST
+       if [[ $silent = false ]]
+       then
+          printf "\n  *** tar update on local host ..."
+       fi
+       tar -cf  ${program_name}_current_version.tar  ${program_name} *.$suf *.o *.mod *.x
+
+    else
+
+          # NOW COMES THE BRANCH FOR CREATING THE EXECUTABLE FOR THE CURRENT RUN
+          # INCLUDING E.G. USER-INTERFACE ROUTINES. ALSO ADD OTHER UTILITY EXECUTABLES. EVERYTHING IS
+          # COLLECTED IN DIRECTORY SOURCES_FOR_RUN_...
+
+          # FIRST CHECK, IF COMPILED SOURCES FOR THIS RUN IDENTIFIER EXISTS
+          # AND ASK, IF THEY SHALL BE USED
+       if [[ -d ${fast_io_catalog}/${sources_for_run_catalog}  &&  $use_existing_sources_folder = true ]]
+       then
+          printf "\a\n  *** compiled sources for run \"$fname\" found on local host in folder"
+          printf "\n      ${fast_io_catalog}/${sources_for_run_catalog}"
+          printf "\n      will be used!"
+          exit
+       fi
+
+          # SECOND CHECK, IF A DEPOSITORY EXISTS ON THE LOCAL MACHINE
+       if [[ ! -d ${make_depository} ]]
+       then
+          printf "\n  +++ directory for local make depository:"
+          printf "\n           $make_depository"
+          printf "\n      not found. Please run \"palmbuild -h $host_configuration\" "
+          locat=make_depository; exit
+       fi
+
+
+          # COPY MAKE DEPOSITORY ON LOCAL MACHINE TO SOURCES_FOR_RUN_...
+       if [[ $silent = false ]]
+       then
+          printf "\n  *** copy MAKE_DEPOSITORY_${host_configuration} on local host to "
+          printf "\n      ${fast_io_catalog}/${sources_for_run_catalog} \n"
+       fi
+       rm -rf ${fast_io_catalog}/${sources_for_run_catalog}
+       mkdir -p ${fast_io_catalog}/${sources_for_run_catalog}
+       cp ${make_depository}/${program_name}_current_version.tar  ${fast_io_catalog}/${sources_for_run_catalog}
+       cd $fast_io_catalog/${sources_for_run_catalog}
+       tar xf ${program_name}_current_version.tar
+
+
+          # COPY CONTENTS OF SOURCES_FOR_RUN_... TO SOURCES_FOR_RUN_...
+          # IN THE FAST_IO_CATALOG ON THE LOCAL MACHINE
+       if [[ $silent = false ]]
+       then
+          printf "\n  *** copy ${base_directory}/${sources_for_run_catalog} to"
+          printf "\n      ${fast_io_catalog}/${sources_for_run_catalog} on local host \n"
+       fi
+       cp  ${base_directory}/${sources_for_run_catalog}/{*,.[!.]*}  ${fast_io_catalog}/${sources_for_run_catalog}
+
+
+          # CREATE EXECUTABLE FROM THE NEW/MODIFIED SOURCE FILES, IF THERE ARE ANY
+       if [[ $(ls -1 ${base_directory}/${sources_for_run_catalog}/ | grep -c .$suf) != 0 ]]
+       then
+
+          if [[ $silent = false ]]
+          then
+             echo "  *** execute \"make\" on local host"
+          fi
+          [[ "$login_init_cmd" != "" ]]   &&  $login_init_cmd
+          [[ "$module_commands" != "" ]]  &&  $module_commands
+
+          make  $make_options  PROG=$program_name  F90=$compiler_name  COPT="$cpp_options"  F90FLAGS="$compiler_options"  LDFLAGS="$linker_options"
 
           if [[ $? != 0 ]]
           then
+
              printf "\a\n  +++ error(s) occurred during compiling or linking for host configuration \"$host_configuration\" "
              if [[ $silent = false ]]
@@ -742,110 +862,25 @@
                 while [[ "$answer" != c  &&  "$answer" != k ]]
                 do
-                   printf "  >>> continue / list errors / kill palmbuild (c/l/k) ? "
+                   printf "  >>> continue / kill palmbuild (c/k) ? "
                    read  answer
-                   if [[ "$answer" = l ]]
-                   then
-                      more ${host_configuration}_last_make_protocol
-                   fi
                 done
                 if [[ $answer = k ]]
                 then
+                   rm -rf ${fast_io_catalog}/${sources_for_run_catalog}
                    locat=user_abort; exit
                 fi
              else
                    # ABORT ANYWAY
+                rm -rf ${fast_io_catalog}/${sources_for_run_catalog}
                 locat=user_abort; exit
              fi
           fi
 
-
-             # TAR NEW VERSION ON LOCAL HOST
-          printf "\n  *** tar update on local host ..."
-          tar -cf  ${program_name}_current_version.tar  ${program_name} *.$suf *.o *.mod *.x
-
        else
 
-             # NOW COMES THE BRANCH FOR CREATING THE EXECUTABLE FOR THE CURRENT RUN
-             # INCLUDING E.G. USER-INTERFACE ROUTINES. ALSO ADD OTHER UTILITY EXECUTABLES. EVERYTHING IS
-             # COLLECTED IN DIRECTORY SOURCES_FOR_RUN_...
-
-             # FIRST CHECK, IF COMPILED SOURCES FOR THIS RUN IDENTIFIER EXISTS
-             # AND ASK, IF THEY SHALL BE USED
-          if [[ -d ${fast_io_catalog}/${sources_for_run_catalog}  &&  $use_existing_sources_folder = true ]]
-          then
-             printf "\a\n  *** compiled sources for run \"$fname\" found on local host in folder"
-             printf "\n      ${fast_io_catalog}/${sources_for_run_catalog}"
-             printf "\n      will be used!"
-             exit
-          fi
-
-             # SECOND CHECK, IF A DEPOSITORY EXISTS ON THE LOCAL MACHINE
-          if [[ ! -d ${make_depository} ]]
-          then
-             printf "\n  +++ directory for local make depository:"
-             printf "\n           $make_depository"
-             printf "\n      not found. Please run \"palmbuild -h $host_configuration\" "
-             locat=make_depository; exit
-          fi
-
-
-             # COPY MAKE DEPOSITORY ON LOCAL MACHINE TO SOURCES_FOR_RUN_...
-          printf "\n  *** copy MAKE_DEPOSITORY_${host_configuration} on local host to "
-          printf "\n      ${fast_io_catalog}/${sources_for_run_catalog} \n"
-          rm -rf ${fast_io_catalog}/${sources_for_run_catalog}
-          mkdir -p ${fast_io_catalog}/${sources_for_run_catalog}
-          cp ${make_depository}/${program_name}_current_version.tar  ${fast_io_catalog}/${sources_for_run_catalog}
-          cd $fast_io_catalog/${sources_for_run_catalog}
-          tar xf ${program_name}_current_version.tar
-
-
-             # COPY CONTENTS OF SOURCES_FOR_RUN_... TO SOURCES_FOR_RUN_...
-             # IN THE FAST_IO_CATALOG ON THE LOCAL MACHINE
-          printf "\n  *** copy ${base_directory}/${sources_for_run_catalog} to"
-          printf "\n      ${fast_io_catalog}/${sources_for_run_catalog} on local host \n"
-          cp  ${base_directory}/${sources_for_run_catalog}/{*,.[!.]*}  ${fast_io_catalog}/${sources_for_run_catalog}
-
-
-             # CREATE EXECUTABLE FROM THE NEW/MODIFIED SOURCE FILES, IF THERE ARE ANY
-          if [[ $(ls -1 ${base_directory}/${sources_for_run_catalog}/ | grep -c .$suf) != 0 ]]
-          then
-
-             echo "  *** execute \"make\" on local host"
-             [[ "$login_init_cmd" != "" ]]   &&  $login_init_cmd
-             [[ "$module_commands" != "" ]]  &&  $module_commands
-
-             make  $make_options  PROG=$program_name  F90=$compiler_name  COPT="$cpp_options"  F90FLAGS="$compiler_options"  LDFLAGS="$linker_options"
-
-             if [[ $? != 0 ]]
-             then
-
-                printf "\a\n  +++ error(s) occurred during compiling or linking for host configuration \"$host_configuration\" "
-                if [[ $silent = false ]]
-                then
-                   answer=dummy
-                   printf "\n"
-                   while [[ "$answer" != c  &&  "$answer" != k ]]
-                   do
-                      printf "  >>> continue / kill palmbuild (c/k) ? "
-                      read  answer
-                   done
-                   if [[ $answer = k ]]
-                   then
-                      rm -rf ${fast_io_catalog}/${sources_for_run_catalog}
-                      locat=user_abort; exit
-                   fi
-                else
-                      # ABORT ANYWAY
-                   rm -rf ${fast_io_catalog}/${sources_for_run_catalog}
-                   locat=user_abort; exit
-                fi
-             fi
-
-          else
-
-             echo "  *** nothing to compile for this run"
-
-          fi
-
-       fi
-    fi
+          echo "  *** nothing to compile for this run"
+
+       fi
+
+    fi
+ fi
