1#!/bin/csh 2# 3# This script creates the version of the day (votd) tar files 4# 5################################################################ 6# 7# Usage: create_votd_tar.csh root_directory platform 8################################################################ 9 10# set base directory 11set ROOT = $1 12set PLATFORM = $2 13set BASE = $ROOT/test_$PLATFORM 14set SQA = $ROOT/OPT++/bin 15 16# Make sure config/make ran successfully 17if (-e $BASE/OPT++/make_optpp.err) then 18 echo "OPTPP build failed" 19else 20 echo "OPTPP built successfully" 21 22 # if votd directory does not exist, create 23 if (-e $BASE/votd) then 24 echo "VOTD directory is $BASE/votd" 25 else 26 mkdir -p $BASE/votd 27 echo "Creating base directory $BASE/votd" 28 endif 29 30 # change to votd directory 31 cd $BASE/votd 32 \rm -f votd.log 33 \rm -f *.gz 34 if (-e optpp) then # if OPT++ exist, remove it 35 \rm -rf optpp 36 endif 37 38 # EXTERNAL VOTD (Linux only) 39 # call extract_src script with head OPT++, 40 if ( $PLATFORM == 'linux' ) then 41 echo "External VOTD: extract src tar files" >> votd.log 42 # Create optpp_votd.src.tar 43 $SQA/extract_src.csh votd head >>& votd.log 44 gzip optpp*.tar 45 # Secure copy VOTD tar files to csmr and extract VOTD HTML docs 46 scp optpp_votd.src.tar.gz csmr.ca.sandia.gov:/home/pwillia/votd/. 47 endif 48