4 ver=`python -c 'import Numeric; print Numeric.__version__' 2>/dev/null`
5 if [ "$ver" == "22.0" ]; then
12 cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <<EOF
13 #$DELIM ${PRODUCT_TYPE} $DELIM
14 export PYTHONPATH=\${INSTALL_ROOT}/${PRODUCT}/lib/python\${PYTHON_VERSION}/site-packages/Numeric:\${PYTHONPATH}
17 (test -w ${PRODUCT_DIR} && cp ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh ${PRODUCT_DIR})
18 make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}"
21 # looks for the native product and collects it's environment (used by make_env())
23 numpath=`python -c "import Numeric; print Numeric.__file__" 2>/dev/null`
24 if [ -n "${numpath}" ] ; then
25 numpath=`dirname ${numpath}`
26 ver=`python -c 'import Numeric; print Numeric.__version__' 2>/dev/null | awk -F. '{v=0;for(i=1;i<=NF;i++)v=v*100+$i;print v}'`
27 if [ $ver -ge 2200 ] ; then
28 tmp="${numpath} ${numpath} \${PYTHONPATH} ${PYTHONPATH}";
29 pythonpath=`sort_path ${tmp}`
30 cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <<EOF
31 #$DELIM ${PRODUCT_TYPE} $DELIM
32 export PYTHONPATH=${pythonpath}
35 make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}"
36 if [ $ver -eq 2200 ] ; then
47 try_existing ${PRODUCT_DIR} ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" ${PRODUCT_TYPE}
53 make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" ${PRODUCT_TYPE}
54 source ${INSTALL_WORK}/$SHRC
56 makedir ${PRODUCT_DIR}
58 check_jb tar xfz ${SOURCE_DIR}/Numeric-22.0.tar.gz -C ${INSTALL_WORK}
61 check_job ${PRODUCT_DIR}/INSTALL.LOG python setup.py install --prefix=${PRODUCT_DIR}
63 #du -sk ${PRODUCT_WORK} > ${PRODUCT_DIR}/size.log
64 cd ${PRODUCT_DIR}; rm -fr ${PRODUCT_WORK}
70 check_jb tar xfz ${SOURCE_DIR}/Numeric-22.0.tar.gz -C ${INSTALL_ROOT}
76 export INSTALL_WORK=$2;
78 export INSTALL_ROOT=$4;
79 export PRODUCT_SEQUENCE=$5;
80 if [ $# == 6 ] ; then export PRODUCT_TYPE=$6 ; else export PRODUCT_TYPE="numeric" ; fi
81 export PRODUCT="Numeric-22.0"
82 export PRODUCT_DIR=${INSTALL_ROOT}/${PRODUCT}
83 export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT}