From c19074299fb86cd30949857fa8468620bcd0092b Mon Sep 17 00:00:00 2001 From: maintenance team Date: Wed, 26 Apr 2006 13:10:01 +0000 Subject: [PATCH] Adding config files for installation on Mandriva 2006 --- config_files/BOOST-1.32.0.sh | 144 +++++++++++++++++++++++++++ config_files/Python-2.4.1.sh | 159 ++++++++++++++++++++++++++++++ config_files/doxygen-1.4.4.sh | 159 ++++++++++++++++++++++++++++++ config_files/gcc-4.0.1.sh | 95 ++++++++++++++++++ config_files/omniORB-4.0.6.sh | 179 ++++++++++++++++++++++++++++++++++ 5 files changed, 736 insertions(+) create mode 100755 config_files/BOOST-1.32.0.sh create mode 100755 config_files/Python-2.4.1.sh create mode 100755 config_files/doxygen-1.4.4.sh create mode 100755 config_files/gcc-4.0.1.sh create mode 100755 config_files/omniORB-4.0.6.sh diff --git a/config_files/BOOST-1.32.0.sh b/config_files/BOOST-1.32.0.sh new file mode 100755 index 0000000..2e8610a --- /dev/null +++ b/config_files/BOOST-1.32.0.sh @@ -0,0 +1,144 @@ +#!/bin/sh + +check_version(){ +if [ -n "${BOOSTDIR}" ]; then + ver=`egrep 'BOOST_VERSION [0-9]+' ${BOOSTDIR}/boost/version.hpp | sed 's/.*BOOST_VERSION \([0-9]\+\)/\1/g'` + if [ "$ver" = "103200" ]; then + return 0 + fi +fi +return 1; +} + +print_env() +{ +cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < /dev/null + if [ "$?" -ne "0" ] ; then + return 1 + fi + ver=`egrep 'BOOST_VERSION [0-9]+' ${boostdir}/boost/version.hpp | sed 's/.*BOOST_VERSION \([0-9]\+\)/\1/g'` + if [ $ver -ge 103200 ] ; then + cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <> ${PRODUCT_DIR}/BUILD.LOG < signals_common.hpp.orig +#mv -f signals_common.hpp.orig signals_common.hpp + +# install +cd ${PRODUCT_WORK} +python_root=`find_in_path python $PATH`; +python_root=`cd ${python_root}/..; pwd` +python_version=`python -c "import sys; print sys.version[:3]"` + +echo "`pwd` -> ./tools/build/jam_src/bin.linuxx86/bjam >> ${PRODUCT_DIR}/INSTALL.LOG" +./tools/build/jam_src/bin.linuxx86/bjam "-sBOOST_ALL_DYN_LINK=1" \ + "-sBUILD=release dynamic multi" \ + --prefix=${PRODUCT_DIR} --builddir=${PRODUCT_WORK} \ + "-sPYTHON_VERSION=$python_version" --with-python-root=${python_root} \ + install >> ${PRODUCT_DIR}/INSTALL.LOG 2> $INSTALL_WORK/errlog + +if [ "$?" -ne "0" ] ; then + cat ${PRODUCT_DIR}/INSTALL.LOG + cat $INSTALL_WORK/errlog >&2 + cat $INSTALL_WORK/errlog >> ${PRODUCT_DIR}/INSTALL.LOG +fi + +# move includes +cd ${PRODUCT_DIR}/include +mv -f boost-1_32/boost boost +rm -rf boost-1_32 + +# create additional links for libraries +cd ${PRODUCT_DIR}/lib +for aLib in date_time filesystem prg_exec_monitor python regex signals test_exec_monitor thread unit_test_framework ; do + if [ -f libboost_${aLib}-gcc-mt-1_32.so ] ; then + ln -s libboost_${aLib}-gcc-mt-1_32.so libboost_${aLib}-mt.so + fi +done + +du -sk ${PRODUCT_WORK} > ${PRODUCT_DIR}/size.log +cd ${PRODUCT_DIR}; rm -fr ${PRODUCT_WORK} + +print_env +} + +install_binary() +{ +make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" ${PRODUCT_TYPE} +source ${INSTALL_WORK}/$SHRC + +check_jb tar xfz ${SOURCE_DIR}/boost-1.32.0.tar.gz -C ${INSTALL_ROOT} + +print_env +} + +export PROCEDURE=$1; +export INSTALL_WORK=$2; +export SOURCE_DIR=$3; +export INSTALL_ROOT=$4; +export PRODUCT_SEQUENCE=$5; +if [ $# == 6 ] ; then export PRODUCT_TYPE=$6 ; else export PRODUCT_TYPE="boost" ; fi +export PRODUCT="boost-1.32.0" +export PRODUCT_DIR=${INSTALL_ROOT}/${PRODUCT} +export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} +source ./common.sh +$PROCEDURE diff --git a/config_files/Python-2.4.1.sh b/config_files/Python-2.4.1.sh new file mode 100755 index 0000000..cd183ec --- /dev/null +++ b/config_files/Python-2.4.1.sh @@ -0,0 +1,159 @@ +#!/bin/sh + +check_version() +{ +if [ -z "$PYTHONHOME" ]; then + return 1 +fi +isPython=`which python 2>/dev/null` +if [ -n "$isPython" ]; then + # version number is calculated as: *10000+*100+ + # for Python 2.4.1 it is equal to 20401 + ver=`python -V 2>&1` + ver=`echo $ver | awk '{print $2}' | awk -F. '{v1=0;v2=0;v3=0;if(NF>0)v1=$1;if(NF>1)v2=$2;if(NF>2)v3=$3;print v1*10000+v2*100+v3}'` + if [ $ver -eq 20401 ] ; then + return 0 + fi +fi +return 1 +} + +print_env() +{ +cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <, and + # and numbers are checked strickly, but number can be larger than required one + # version number is calculated as: *10000+*100+ + # for Python 2.4.1 it is equal to 20401 + ver=`python -V 2>&1` + maj_ver=`echo $ver | awk '{print $2}' | awk -F. '{if(NF>0) print $1; else print 0}'` + min_ver=`echo $ver | awk '{print $2}' | awk -F. '{if(NF>1) print $2; else print 0}'` + rel_ver=`echo $ver | awk '{print $2}' | awk -F. '{if(NF>2) print $3; else print 0}'` + let ver=$maj_ver*10000+$min_ver*100+$rel_ver + if [ $ver -ge 20401 ] ; then + tmp="\${PYTHONHOME}/bin ${pythonhome}/bin \${PATH} ${PATH}"; + path=`sort_path ${tmp}` + tmp="\${PYTHONHOME}/lib/python\${PYTHON_VERSION} ${pythonhome}/lib/python${maj_ver}.${min_ver} \${PYTHONPATH} ${PYTHONPATH}"; + pythonpath=`sort_path ${tmp}` + tmp="\${PYTHONHOME}/lib ${pythonhome}/lib \${LD_LIBRARY_PATH} ${LD_LIBRARY_PATH}"; + ld_library_path=`sort_path ${tmp}` + cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < _Makefile +mv -f _Makefile Makefile +GCC=`which gcc` +cat >> ${PRODUCT_DIR}/MAKE.LOG < _"$sc" + mv -f _"$sc" "$sc" + chmod a+x "$sc" + fi +done + +#du -sk ${PRODUCT_WORK} > ${PRODUCT_DIR}/size.log +cd ${PRODUCT_DIR}; rm -fr ${PRODUCT_WORK} +print_env +} + +install_binary() +{ +make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" ${PRODUCT_TYPE} +source ${INSTALL_WORK}/$SHRC + +check_jb tar xfz ${SOURCE_DIR}/Python-2.4.1.tar.gz -C ${INSTALL_ROOT} + +(cd ${PRODUCT_DIR}/lib/python2.4/config; ln -fs ../../libpython2.4.so.1.0 libpython2.4.so) + +cd ${PRODUCT_DIR}/bin +for sc in idle pydoc smtpd.py ; do + if [ -e $sc ] ; then + sed -e "s%#\!.*python%#\!/usr/bin/env python%" "$sc" > _"$sc" + mv -f _"$sc" "$sc" + chmod a+x "$sc" + fi +done + +print_env +} + +export PROCEDURE=$1; +export INSTALL_WORK=$2; +export SOURCE_DIR=$3; +export INSTALL_ROOT=$4; +export PRODUCT_SEQUENCE=$5; +if [ $# == 6 ] ; then export PRODUCT_TYPE=$6 ; else export PRODUCT_TYPE="python" ; fi +export PRODUCT="Python-2.4.1" +export PRODUCT_DIR=${INSTALL_ROOT}/${PRODUCT} +export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} +source ./common.sh +${PROCEDURE} diff --git a/config_files/doxygen-1.4.4.sh b/config_files/doxygen-1.4.4.sh new file mode 100755 index 0000000..9a891d7 --- /dev/null +++ b/config_files/doxygen-1.4.4.sh @@ -0,0 +1,159 @@ +#!/bin/sh + +check_version() +{ +check_lib_version doxygen $PATH +if [ "$?" -ne "0" ]; then + return 1 +fi +check_lib_version doxytag $PATH +if [ "$?" -ne "0" ]; then + return 1 +fi +check_lib_version doxywizard $PATH +if [ "$?" -ne "0" ]; then + return 1 +fi +ver=`doxygen --version` +if [ "$ver" == "1.4.4" ]; then + return 0 +fi +return 1 +} + +print_env() +{ +cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <> ${PRODUCT_DIR}/MAKE.LOG </dev/null 2>&1; ISFOUND=$? +if [ ${ISFOUND} -eq 0 ] ; then which makeindex >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which latex >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which latex2html >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which pdflatex >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which pslatex >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which pstoimg >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then + check_job ${PRODUCT_DIR}/MAKEDOCS.LOG make docs + check_job ${PRODUCT_DIR}/MAKEINSTALLDOCS.LOG make install_docs +else + cat >> ${PRODUCT_DIR}/MAKEDOCS.LOG < ${PRODUCT_DIR}/size.log +cd ${PRODUCT_DIR}; rm -fr ${PRODUCT_WORK} +print_env +} + +install_binary() +{ +make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" ${PRODUCT_TYPE} +source ${INSTALL_WORK}/$SHRC + +check_jb tar xfz ${SOURCE_DIR}/doxygen-1.4.4.tar.gz -C ${INSTALL_ROOT} +which epstopdf >/dev/null 2>&1; ISFOUND=$? +if [ ${ISFOUND} -eq 0 ] ; then which makeindex >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which latex >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which latex2html >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which pdflatex >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which pslatex >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -eq 0 ] ; then which pstoimg >/dev/null 2>&1; ISFOUND=$?; fi +if [ ${ISFOUND} -ne 0 ] ; then + cat >> ${PRODUCT_DIR}/DOCS.LOG <*10000+*100+ +# e.g. for gcc 3.2 it is equal to 30200, for gcc 3.4.1 - 30401, for gcc 4.0.1 - 40001 +gcc_ver=`gcc -dumpversion | awk -F. '{v1=0;v2=0;v3=0;if(NF>0)v1=$1;if(NF>1)v2=$2;if(NF>2)v3=$3;print v1*10000+v2*100+v3}'` +if [ $gcc_ver -eq 40001 ] ; then + return 0 +fi +return 1 +} + +print_env(){ +cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <, and + # and numbers are checked strickly, but number can be larger than required one + # version number is calculated as: *10000+*100+ + # e.g. for gcc 3.2 it is equal to 30200, for gcc 3.4.1 - 30401, for gcc 4.0.1 - 40001 + maj_ver=`${gcc_root}/bin/gcc -dumpversion | awk -F. '{if(NF>0) print $1; else print 0}'` + min_ver=`${gcc_root}/bin/gcc -dumpversion | awk -F. '{if(NF>1) print $2; else print 0}'` + rel_ver=`${gcc_root}/bin/gcc -dumpversion | awk -F. '{if(NF>2) print $3; else print 0}'` + let gcc_ver=$maj_ver*10000+$min_ver*100+$rel_ver + if [ $gcc_ver -ge 40001 ] ; then + tmp="\${GCC_ROOT}/bin ${gcc_root}/bin \${PATH} ${PATH}"; + path=`sort_path ${tmp}` + tmp="\${GCC_ROOT}/lib ${gcc_root}/lib \${LD_LIBRARY_PATH} ${LD_LIBRARY_PATH}"; + ld_library_path=`sort_path ${tmp}` + cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < ${PRODUCT_DIR}/.omniORB.cfg < ${INSTALL_WORK}/env_${PRODUCT_TYPE}.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 + +#du -sk ${PRODUCT_WORK} > ${PRODUCT_DIR}/size.log +cd ${PRODUCT_DIR} +rm -fr ${INSTALL_WORK}/omniORB-4.0.5 +rm -fr ${INSTALL_WORK}/omniORBpy-2.5 +rm -fr ${INSTALL_WORK}/omniNotify +print_env +} + +install_binary() +{ +make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" ${PRODUCT_TYPE} +source ${INSTALL_WORK}/$SHRC + +check_jb tar xfz ${SOURCE_DIR}/omniORB-4.0.5.tar.gz -C ${INSTALL_ROOT} + +ln -sf ${PRODUCT_DIR} ${INSTALL_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 + +print_env +} + +export PROCEDURE=$1; +export INSTALL_WORK=$2; +export SOURCE_DIR=$3; +export INSTALL_ROOT=$4; +export PRODUCT_SEQUENCE=$5; +if [ $# == 6 ] ; then export PRODUCT_TYPE=$6 ; else export PRODUCT_TYPE="omni" ; fi +export PRODUCT="omniORB-4.0.5" +export PRODUCT_DIR=${INSTALL_ROOT}/${PRODUCT} +export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} +source ./common.sh +$PROCEDURE -- 2.39.2