bv_visus.sh 1.94 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76
function bv_visus_initialize
{
export DO_VISUS="no"
export ON_VISUS="off"
}

function bv_visus_enable
{
DO_VISUS="yes"
ON_VISUS="on"
}

function bv_visus_disable
{
DO_VISUS="no"
ON_VISUS="off"
}

function bv_visus_depends_on
{
return ""
}

function bv_visus_info
{
export VISUS_FILE=${VISUS_FILE:-"visus_26Feb07.tar.gz"}
export VISUS_VERSION=${VISUS_VERSION:-"1.0.0"}
export VISUS_COMPATIBILITY_VERSION=${VISUS_COMPATIBILITY_VERSION:-"1.0"}
export VISUS_BUILD_DIR=${VISUS_BUILD_DIR:-"visus"}
}

function bv_visus_print
{
  printf "%s%s\n" "VISUS_FILE=" "${VISUS_FILE}"
  printf "%s%s\n" "VISUS_VERSION=" "${VISUS_VERSION}"
  printf "%s%s\n" "VISUS_COMPATIBILITY_VERSION=" "${VISUS_COMPATIBILITY_VERSION}"
  printf "%s%s\n" "VISUS_BUILD_DIR=" "${VISUS_BUILD_DIR}"
}

function bv_visus_print_usage
{
printf "\t\t%15s\n" "NOTE: not available for download from web"
printf "%-15s %s [%s]\n" "--visus" "Build ViSUS (experimental!)" "$DO_VISUS"
}

function bv_visus_graphical
{
local graphical_out="VISUS    $VISUS_VERSION($VISUS_FILE)     $ON_VISUS"
echo "$graphical_out"
}

function bv_visus_host_profile
{
    if [[ "$DO_VISUS" == "yes" ]] ; then
        echo >> $HOSTCONF
        echo "##" >> $HOSTCONF
        echo "## Visus" >> $HOSTCONF
        echo "##" >> $HOSTCONF
        echo \
        "VISIT_OPTION_DEFAULT(VISIT_VISUS_DIR \${VISITHOME}/visus/$VISUS_VERSION/\${VISITARCH})" \
        >> $HOSTCONF
    fi
}

function bv_visus_ensure
{
    if [[ "$DO_VISUS" == "yes" ]] ; then
        ensure_built_or_ready "visus" $VISUS_VERSION $VISUS_BUILD_DIR $VISUS_FILE
        if [[ $? != 0 ]] ; then
            ANY_ERRORS="yes"
            DO_VISUS="no"
            error "Unable to build ViSUS.  ${VISUS_FILE} not found."
        fi
    fi
}

77 78 79 80 81 82 83
function bv_visus_dry_run
{
  if [[ "$DO_VISUS" == "yes" ]] ; then
    echo "Dry run option not set for visus."
  fi
}

84 85
function bv_visus_build
{
86 87 88
  if [[ "$DO_VISUS" == "yes" ]] ; then
    echo "Build support not available for visus.."
  fi
89 90
}