From 2b28998e8ca66f019f0c15b84ed5a652b28f413d Mon Sep 17 00:00:00 2001 From: maintenance team Date: Mon, 23 Mar 2009 09:04:58 +0000 Subject: [PATCH] Update and implementation of script for new products --- config_files/docutils-0.4.0.sh | 150 +++++++++++++++++++++++ config_files/metis-4.0.sh | 2 + config_files/omniORB-4.1.3.sh | 218 +++++++++++++++++++++++++++++++++ config_files/scotch-4.0.sh | 6 + config_files/sphinx-0.5.sh | 170 +++++++++++++++++++++++++ 5 files changed, 546 insertions(+) create mode 100755 config_files/docutils-0.4.0.sh create mode 100755 config_files/omniORB-4.1.3.sh create mode 100755 config_files/sphinx-0.5.sh diff --git a/config_files/docutils-0.4.0.sh b/config_files/docutils-0.4.0.sh new file mode 100755 index 0000000..2fc1d6f --- /dev/null +++ b/config_files/docutils-0.4.0.sh @@ -0,0 +1,150 @@ +#!/bin/bash -noprofile + +#################################################################################### +# File : docutils-0.4.0.sh +# Created : Thu Dec 18 12:01:00 2002 +# Author : Vadim SANDLER, Open CASCADE SAS (vadim.sandler@opencascade.com) +# Project : SALOME +# Module : Installation Wizard +# Copyright : 2002-2008 CEA +# +# This script is the part of the SALOME installation procedure. +# +#################################################################################### + +check_version(){ +# It is not necessary to check version! +return 0 +} + +print_env_bin(){ +cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < ${INSTALL_WORK}/env_${PRODUCT_TYPE}_src.sh < _rst2latex.py +mv -f _rst2latex.py rst2latex.py +chmod a+x rst2latex.py +ln -sf rst2latex.py rst2latex + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" rst2html.py > _rst2html.py +mv -f _rst2html.py rst2html.py +chmod a+x rst2html.py +ln -sf rst2html.py rst2html + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" rst2newlatex.py > _rst2newlatex.py +mv -f _rst2newlatex.py rst2newlatex.py +chmod a+x rst2newlatex.py +ln -sf rst2newlatex.py rst2newlatex + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" rst2pseudoxml.py > _rst2pseudoxml.py +mv -f _rst2pseudoxml.py rst2pseudoxml.py +chmod a+x rst2pseudoxml.py +ln -sf rst2pseudoxml.py rst2pseudoxml + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" rst2s5.py > _rst2s5.py +mv -f _rst2s5.py rst2s5.py +chmod a+x rst2s5.py +ln -sf rst2s5.py rst2s5 + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" rst2xml.py > _rst2xml.py +mv -f _rst2xml.py rst2xml.py +chmod a+x rst2xml.py +ln -sf rst2xml.py rst2xml + +# remove sources and temporary files after building +if [ ${REMOVE_SRC_TMP} == "TRUE" ] ; then + test -d ${PRODUCT_SRC_DIR} && rm -fr ${PRODUCT_SRC_DIR} +fi + +# to generate environment scripts +try_preinstalled +} + +install_binary() +{ +make_env ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE} +source ${INSTALL_WORK}/$SHRC + +# create a product directory +test -z ${SINGLE_DIR} && makedir ${PRODUCT_DIR} || mkdir -p ${PRODUCT_DIR} + +check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}.tar.gz -C ${PRODUCT_DIR} +cd ${PRODUCT_DIR}/bin; + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" rst2latex.py > _rst2latex.py +mv -f _rst2latex.py rst2latex.py +chmod a+x rst2latex.py +ln -sf rst2latex.py rst2latex + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" rst2html.py > _rst2html.py +mv -f _rst2html.py rst2html.py +chmod a+x rst2html.py +ln -sf rst2html.py rst2html + +# to generate environment script for sources +try_preinstalled +} + +export PROCEDURE=$1; +export INSTALL_WORK=$2; +export SOURCE_DIR=$3; +export INST_ROOT=$4; +export PRODUCT_SEQUENCE=$5; +export PRODUCT_TYPE=$6; +export INSTALL_PRODUCTS=$7; +shift +REMOVE_SRC_TMP=$8; +test $# == 10 && shift && SINGLE_DIR=$9 +export PRODUCT="docutils-0.4.0" +export PRODUCT_DIR=${INST_ROOT}/${SINGLE_DIR:-${PRODUCT}} +export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} +export PRODUCT_SRC_DIR=${INST_ROOT}/${PRODUCT}_SRC +source ./common.sh +$PROCEDURE diff --git a/config_files/metis-4.0.sh b/config_files/metis-4.0.sh index f4fc04f..8c5dccb 100755 --- a/config_files/metis-4.0.sh +++ b/config_files/metis-4.0.sh @@ -78,6 +78,8 @@ check_job ${PRODUCT_DIR}/MAKE.LOG make cp -rf Doc Graphs libmetis.a pmetis kmetis oemetis onmetis partdmesh partnmesh mesh2dual mesh2nodal graphchk ${PRODUCT_DIR} ( mkdir -p ${PRODUCT_DIR}/Lib && cp Lib/*.h ${PRODUCT_DIR}/Lib ) +cd ${PRODUCT_DIR}; + # remove sources and temporary files after building if [ ${REMOVE_SRC_TMP} == "TRUE" ] ; then test -d ${PRODUCT_SRC_DIR} && rm -fr ${PRODUCT_SRC_DIR} diff --git a/config_files/omniORB-4.1.3.sh b/config_files/omniORB-4.1.3.sh new file mode 100755 index 0000000..f5b63e1 --- /dev/null +++ b/config_files/omniORB-4.1.3.sh @@ -0,0 +1,218 @@ +#!/bin/bash -noprofile + +#################################################################################### +# File : omniORB-4.1.3.sh +# Created : Mon Feb 09 16:21:00 2009 +# Author : Vadim SANDLER, Open CASCADE SAS (vadim.sandler@opencascade.com) +# Project : SALOME +# Module : Installation Wizard +# Copyright : 2002-2009 CEA +# +# This script is the part of the SALOME installation procedure. +# +#################################################################################### + +check_version() +{ +if [ -z "${OMNIORBDIR}" ]; then + #echo "OMNIORBDIR doesn't set" + return 1 +fi +python_version="`python -c 'import sys; print sys.version[:3]'`" +check_lib_version libomniORB4.so.1.3 ${OMNIORBDIR}/lib +if [ "$?" -ne "0" ]; then + return 1 +fi +check_lib_version _omnipymodule.so.3.3 ${OMNIORBDIR}/lib/python${python_version}/site-packages +if [ "$?" -ne "0" ]; then + return 1 +fi +check_lib_version libCOSNotify4.so.0.1 ${OMNIORBDIR}/lib +if [ "$?" -ne "0" ]; then + return 1 +fi +check_lib_version notifd ${OMNIORBDIR}/bin +if [ "$?" -ne "0" ]; then + return 1 +fi +return 0 +} + +print_env_bin() +{ + +if [ `uname -m` = "x86_64" ] && [ -d ${PRODUCT_DIR}/lib64 ] ; then + OMNI_LIB_PREFIX=64 +elif [ -d ${PRODUCT_DIR}/lib ] ; then + OMNI_LIB_PREFIX="" +else + OMNI_LIB_PREFIX=64 +fi + +cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < ${PRODUCT_DIR}/.omniORB.cfg < ${INSTALL_WORK}/env_${PRODUCT_TYPE}_src.sh <> ${PRODUCT_DIR}/MAKE_OMNIORB.LOG <> ${PRODUCT_DIR}/MAKE_OMNIORBPY.LOG <> ${PRODUCT_DIR}/MAKE_OMNINOTIFY.LOG < _omniidl +mv -f _omniidl omniidl +chmod a+x omniidl +sed -e "s%#\!.*python%#\!/usr/bin/env python%" omniidlrun.py > _omniidlrun.py +mv -f _omniidlrun.py omniidlrun.py +chmod a+x omniidlrun.py + +cd ${PRODUCT_DIR} + +# remove sources and temporary files after building +if [ ${REMOVE_SRC_TMP} == "TRUE" ] ; then + test -d ${PRODUCT_SRC_DIR} && rm -fr ${PRODUCT_SRC_DIR} +fi + +# to generate environment scripts +try_preinstalled +} + +install_binary() +{ +make_env ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE} +source ${INSTALL_WORK}/$SHRC + +# create a product directory +test -z ${SINGLE_DIR} && makedir ${PRODUCT_DIR} || mkdir -p ${PRODUCT_DIR} + +check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}.tar.gz -C ${PRODUCT_DIR} + +ln -sf ${PRODUCT_DIR} ${INST_ROOT}/omni + +cd ${PRODUCT_DIR}/bin +sed -e "s%#\!.*python%#\!/usr/bin/env python%" omniidl > _omniidl +mv -f _omniidl omniidl +chmod a+x omniidl +sed -e "s%#\!.*python%#\!/usr/bin/env python%" omniidlrun.py > _omniidlrun.py +mv -f _omniidlrun.py omniidlrun.py +chmod a+x omniidlrun.py + +# to generate environment script for sources +try_preinstalled +} + +export PROCEDURE=$1; +export INSTALL_WORK=$2; +export SOURCE_DIR=$3; +export INST_ROOT=$4; +export PRODUCT_SEQUENCE=$5; +export PRODUCT_TYPE=$6; +export INSTALL_PRODUCTS=$7; +shift +REMOVE_SRC_TMP=$8; +test $# == 10 && shift && SINGLE_DIR=$9 +export PRODUCT="omniORB-4.1.3" +export PRODUCT_DIR=${INST_ROOT}/${SINGLE_DIR:-${PRODUCT}} +export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} +export PRODUCT_SRC_DIR=${INST_ROOT}/${PRODUCT}_SRC +source ./common.sh +$PROCEDURE diff --git a/config_files/scotch-4.0.sh b/config_files/scotch-4.0.sh index b5e5e12..f3c9edb 100755 --- a/config_files/scotch-4.0.sh +++ b/config_files/scotch-4.0.sh @@ -76,6 +76,10 @@ else ln -sf Make.inc/Makefile.inc.i686_pc_linux2.prof Makefile.inc fi +sed -e "s%gmake%make%" Makefile.inc > _Makefile.inc +mv -f _Makefile.inc Makefile.inc +chmod a+x Makefile.inc + # make check_job ${PRODUCT_DIR}/MAKE.LOG make @@ -83,6 +87,8 @@ check_job ${PRODUCT_DIR}/MAKE.LOG make cd ${PRODUCT_SRC_DIR} cp -rf bin doc grf tgt ${PRODUCT_DIR} +cd ${PRODUCT_DIR}; + # remove sources and temporary files after building if [ ${REMOVE_SRC_TMP} == "TRUE" ] ; then test -d ${PRODUCT_SRC_DIR} && rm -fr ${PRODUCT_SRC_DIR} diff --git a/config_files/sphinx-0.5.sh b/config_files/sphinx-0.5.sh new file mode 100755 index 0000000..e2ac532 --- /dev/null +++ b/config_files/sphinx-0.5.sh @@ -0,0 +1,170 @@ +#!/bin/bash -noprofile + +#################################################################################### +# File : sphinx-0.5.sh +# Created : Thu Dec 18 12:01:00 2002 +# Author : Vadim SANDLER, Open CASCADE SAS (vadim.sandler@opencascade.com) +# Project : SALOME +# Module : Installation Wizard +# Copyright : 2002-2008 CEA +# +# This script is the part of the SALOME installation procedure. +# +#################################################################################### + +check_version(){ +# It is not necessary to check version! +return 0 +} + +print_env_bin(){ +cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < ${INSTALL_WORK}/env_${PRODUCT_TYPE}_src.sh < _easy_install +mv -f _easy_install easy_install +chmod a+x easy_install + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" easy_install-2.4 > _easy_install-2.4 +mv -f _easy_install-2.4 easy_install-2.4 +chmod a+x easy_install-2.4 + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" pygmentize > _pygmentize +mv -f _pygmentize pygmentize +chmod a+x pygmentize + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" sphinx-build > _sphinx-build +mv -f _sphinx-build sphinx-build +chmod a+x sphinx-build + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" sphinx-quickstart > _sphinx-quickstart +mv -f _sphinx-quickstart sphinx-quickstart +chmod a+x sphinx-quickstart + +cd ${PRODUCT_DIR} + +# remove sources and temporary files after building +if [ ${REMOVE_SRC_TMP} == "TRUE" ] ; then + test -d ${PRODUCT_SRC_DIR} && rm -fr ${PRODUCT_SRC_DIR} +fi + +# to generate environment scripts +try_preinstalled +} + +install_binary() +{ +make_env ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE} +source ${INSTALL_WORK}/$SHRC + +# create a product directory +test -z ${SINGLE_DIR} && makedir ${PRODUCT_DIR} || mkdir -p ${PRODUCT_DIR} + +check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}.tar.gz -C ${PRODUCT_DIR} + +cd ${PRODUCT_DIR}/bin; + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" easy_install > _easy_install +mv -f _easy_install easy_install +chmod a+x easy_install + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" easy_install-2.4 > _easy_install-2.4 +mv -f _easy_install-2.4 easy_install-2.4 +chmod a+x easy_install-2.4 + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" pygmentize > _pygmentize +mv -f _pygmentize pygmentize +chmod a+x pygmentize + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" sphinx-build > _sphinx-build +mv -f _sphinx-build sphinx-build +chmod a+x sphinx-build + +sed -e "s%#\!.*python%#\!/usr/bin/env python%" sphinx-quickstart > _sphinx-quickstart +mv -f _sphinx-quickstart sphinx-quickstart +chmod a+x sphinx-quickstart + +# to generate environment script for sources +try_preinstalled +} + +export PROCEDURE=$1; +export INSTALL_WORK=$2; +export SOURCE_DIR=$3; +export INST_ROOT=$4; +export PRODUCT_SEQUENCE=$5; +export PRODUCT_TYPE=$6; +export INSTALL_PRODUCTS=$7; +shift +REMOVE_SRC_TMP=$8; +test $# == 10 && shift && SINGLE_DIR=$9 +export PRODUCT="sphinx-0.5" +export PRODUCT_DIR=${INST_ROOT}/${SINGLE_DIR:-${PRODUCT}} +export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} +export PRODUCT_SRC_DIR=${INST_ROOT}/${PRODUCT}_SRC +source ./common.sh +$PROCEDURE -- 2.39.2