From 3624ad3eecb2de9860d4bf8943f950f5bfe69fc8 Mon Sep 17 00:00:00 2001 From: vsr Date: Wed, 21 Oct 2009 20:11:46 +0000 Subject: [PATCH] Minor improvements --- config_files/VTK-5.0.0.sh | 16 +++++++++------- config_files/blsurf-2.7.12.sh | 7 ++++++- config_files/doxygen-1.6.1.sh | 10 ++++++++-- 3 files changed, 23 insertions(+), 10 deletions(-) diff --git a/config_files/VTK-5.0.0.sh b/config_files/VTK-5.0.0.sh index ab7efe2..84f905f 100755 --- a/config_files/VTK-5.0.0.sh +++ b/config_files/VTK-5.0.0.sh @@ -12,6 +12,12 @@ # #################################################################################### +# +# VTK version +# +VTK_VERSION=5.0.0 +VTK_LIBVERSION=`echo ${VTK_VERSION} | awk -F. '{printf("%d.%d",$1,$2)}'` + check_version() { if [ -z "$VTKHOME" ]; then @@ -32,7 +38,7 @@ export VTKHOME=\${INST_ROOT}/${SINGLE_DIR:-${PRODUCT}} export PATH=\${VTKHOME}/bin:\${PATH} export LD_LIBRARY_PATH=\${VTKHOME}/lib:\${LD_LIBRARY_PATH} export PYTHONPATH=\${VTKHOME}/lib/python\${PYTHON_VERSION}/site-packages:\${PYTHONPATH} -export TCLLIBPATH="\${VTKHOME}/lib/vtk-5.0/tcl \${TCLLIBPATH}" +export TCLLIBPATH="\${VTKHOME}/lib/vtk-${VTK_LIBVERSION}/tcl \${TCLLIBPATH}" ## EOF (test -w ${PRODUCT_DIR} && cp ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh ${PRODUCT_DIR}) @@ -209,11 +215,7 @@ source ${INSTALL_WORK}/$SHRC # create a product directory test -z ${SINGLE_DIR} && makedir ${PRODUCT_DIR} || mkdir -p ${PRODUCT_DIR} -if [ -n "$MESA_HOME" ]; then - check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}_with_Mesa.tar.gz -C ${PRODUCT_DIR} -else - check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}.tar.gz -C ${PRODUCT_DIR} -fi +check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}.tar.gz -C ${PRODUCT_DIR} # to generate environment script for sources try_preinstalled @@ -229,7 +231,7 @@ export INSTALL_PRODUCTS=$7; shift REMOVE_SRC_TMP=$8; test $# == 10 && shift && SINGLE_DIR=$9 -export PRODUCT="VTK-5.0.0" +export PRODUCT="VTK-${VTK_VERSION}" export PRODUCT_DIR=${INST_ROOT}/${SINGLE_DIR:-${PRODUCT}} export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} export PRODUCT_SRC_DIR=${INST_ROOT}/${PRODUCT}_SRC diff --git a/config_files/blsurf-2.7.12.sh b/config_files/blsurf-2.7.12.sh index fbc8063..46b5fc5 100755 --- a/config_files/blsurf-2.7.12.sh +++ b/config_files/blsurf-2.7.12.sh @@ -12,6 +12,11 @@ # #################################################################################### +# +# BLSurf version +# +BLSURF_VERSION=2.7.12 + check_version(){ # No way to check version! return 0 @@ -89,7 +94,7 @@ REMOVE_SRC_TMP=$9; shift BIN_DIR=$9; test $# == 10 && shift && SINGLE_DIR=$9 -export PRODUCT="blsurf-2.7.12" +export PRODUCT="blsurf-${BLSURF_VERSION}" export PRODUCT_DIR=${INST_ROOT}/${SINGLE_DIR:-${PRODUCT}} export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} export PRODUCT_SRC_DIR=${INST_ROOT}/${PRODUCT}_SRC diff --git a/config_files/doxygen-1.6.1.sh b/config_files/doxygen-1.6.1.sh index 306e4c6..dca67d6 100755 --- a/config_files/doxygen-1.6.1.sh +++ b/config_files/doxygen-1.6.1.sh @@ -12,6 +12,12 @@ # #################################################################################### +# +# Doxygen version +# +DOXYGEN_VERSION=1.6.1 +DOXYGEN_XVERSION=`echo ${DOXYGEN_VERSION} | awk -F. '{printf("%d",$1*10000+$2*100+$3)}'` + check_version() { check_lib_version doxygen $PATH @@ -23,7 +29,7 @@ maj_ver=`echo $ver | awk -F. '{if(NF>0) print $1; else print 0}' | sed -e 's/^\( min_ver=`echo $ver | awk -F. '{if(NF>1) print $2; else print 0}' | sed -e 's/^\([0-9]*\).*$/\1/'` rel_ver=`echo $ver | awk -F. '{if(NF>2) print $3; else print 0}' | sed -e 's/^\([0-9]*\).*$/\1/'` let ver=$maj_ver*10000+$min_ver*100+$rel_ver -if [ $ver -eq 10506 ] ; then +if [ $ver -eq ${DOXYGEN_XVERSION} ] ; then return 0 fi return 1 @@ -123,7 +129,7 @@ export INSTALL_PRODUCTS=$7; shift REMOVE_SRC_TMP=$8; test $# == 10 && shift && SINGLE_DIR=$9 -export PRODUCT="doxygen-1.6.1" +export PRODUCT="doxygen-${DOXYGEN_VERSION}" export PRODUCT_DIR=${INST_ROOT}/${SINGLE_DIR:-${PRODUCT}} export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} export PRODUCT_SRC_DIR=${INST_ROOT}/${PRODUCT}_SRC -- 2.39.2