From 310a94722baa57b070e8db36dd9cf3ccace6ffac Mon Sep 17 00:00:00 2001 From: maintenance team Date: Fri, 26 Oct 2007 08:18:11 +0000 Subject: [PATCH] Update for Salome series 4x --- config_files/hdf5-1.6.3.sh | 135 ------------- config_files/{med-2.2.3.sh => med-2.3.1.sh} | 37 ++-- config_files/qt-3.3.3.sh | 201 -------------------- config_files/{qt-3.3.4.sh => qt-3.3.8.sh} | 21 +- 4 files changed, 16 insertions(+), 378 deletions(-) delete mode 100755 config_files/hdf5-1.6.3.sh rename config_files/{med-2.2.3.sh => med-2.3.1.sh} (83%) delete mode 100755 config_files/qt-3.3.3.sh rename config_files/{qt-3.3.4.sh => qt-3.3.8.sh} (91%) diff --git a/config_files/hdf5-1.6.3.sh b/config_files/hdf5-1.6.3.sh deleted file mode 100755 index d09b4c6..0000000 --- a/config_files/hdf5-1.6.3.sh +++ /dev/null @@ -1,135 +0,0 @@ -#!/bin/bash -noprofile - -#################################################################################### -# File : hdf5-1.6.3.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-2007 CEA -# -# This script is the part of the SALOME installation procedure. -# -#################################################################################### - -check_version() -{ -if [ -z "$HDF5HOME" ]; then - return 1 -fi -check_lib_version libhdf5.so.0.0.0 ${HDF5HOME}/lib -if [ "$?" -ne "0" ]; then - return 1 -fi -check_lib_version libhdf5.settings ${HDF5HOME}/lib -if [ "$?" -eq "0" ]; then - ver=`grep "HDF5 Version:" ${HDF5HOME}/lib/libhdf5.settings | awk '{print $3}'` - if [ "$ver" == "1.6.3" ]; then - return 0 - fi -fi -return 1 -} - -print_env_bin() -{ -cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < ${INSTALL_WORK}/env_${PRODUCT_TYPE}_src.sh <> ${PRODUCT_DIR}/MAKE.LOG < ${PRODUCT_DIR}/size.log -cd ${PRODUCT_DIR}; - -# remove sources and temporary files after building -if [ ${REMOVE_SRC_TMP} == "TRUE" ] ; then - test -d ${PRODUCT_DIR}_SRC && rm -fr ${PRODUCT_DIR}_SRC -fi - -# to generate environment scripts -try_preinstalled -} - -install_binary() -{ -make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE} -source ${INSTALL_WORK}/$SHRC - -check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}.tar.gz -C ${INSTALL_ROOT} - -### modify libhdf5.la file to correct direct path to hdf5 library -### no need to do this for sources installation because 'make install' does it! -cd ${PRODUCT_DIR}/lib -sed -e "s%^libdir='\(.*\)'%libdir='${PRODUCT_DIR}/lib'%g" libhdf5.la > libhdf5.la.new -mv -f libhdf5.la.new libhdf5.la - -# to generate environment script for sources -try_preinstalled -} - -export PROCEDURE=$1; -export INSTALL_WORK=$2; -export SOURCE_DIR=$3; -export INSTALL_ROOT=$4; -export PRODUCT_SEQUENCE=$5; -export PRODUCT_TYPE=$6; -export INSTALL_PRODUCTS=$7; -shift -REMOVE_SRC_TMP=$8; -export PRODUCT="hdf5-1.6.3" -export PRODUCT_DIR=${INSTALL_ROOT}/${PRODUCT} -export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} -source ./common.sh -$PROCEDURE diff --git a/config_files/med-2.2.3.sh b/config_files/med-2.3.1.sh similarity index 83% rename from config_files/med-2.2.3.sh rename to config_files/med-2.3.1.sh index 38d8d82..74e1872 100755 --- a/config_files/med-2.2.3.sh +++ b/config_files/med-2.3.1.sh @@ -1,7 +1,7 @@ #!/bin/bash -noprofile #################################################################################### -# File : med-2.2.3.sh +# File : med-2.3.1.sh # Created : Thu Dec 18 12:01:00 2002 # Author : Vadim SANDLER, Open CASCADE SAS (vadim.sandler@opencascade.com) # Project : SALOME @@ -79,15 +79,22 @@ makedir ${PRODUCT_DIR} #vsr: provide additional flags for f95 (Mandriva 2006.0, Fedora Core 4) is_mandriva=0 +is_mandriva2007=0 is_fedora=0 if [ -e /etc/redhat-release ] ; then grep -e "Mandriva Linux release 2006.0" /etc/redhat-release > /dev/null if [ $? == 0 ] ; then is_mandriva=1 ; fi + grep -e "Mandriva Linux release 2007.0" /etc/redhat-release > /dev/null + if [ $? == 0 ] ; then is_mandriva2007=1 ; fi grep -e "Fedora Core release 4" /etc/redhat-release > /dev/null if [ $? == 0 ] ; then is_fedora=1 ; fi fi - -if [ $is_mandriva == 1 ] || [ $is_fedora == 1 ] ; then +if [ $is_mandriva2007 == 1 ] ; then +chmod +w ./Makefile.am +mv Makefile.am Makefile.am.orig +sed -e 's/ include src tests tools doc / include src tools doc /g' Makefile.am.orig > Makefile.am +fi +if [ $is_mandriva == 1 ] || [ $is_mandriva2007 == 1 ] || [ $is_fedora == 1 ] ; then if test `uname -m` = "x86_64" ; then echo "`pwd` -> ./configure --prefix=${PRODUCT_DIR} FFLAGS='-g -O2 -ffixed-line-length-none' CFLAGS=-m64 CXXFLAGS=-m64 >> ${PRODUCT_DIR}/CONFIGURE.LOG" ./configure --prefix=${PRODUCT_DIR} FFLAGS="-g -O2 -ffixed-line-length-none" CFLAGS=-m64 CXXFLAGS=-m64 >> ${PRODUCT_DIR}/CONFIGURE.LOG 2> ${PRODUCT_DIR}_SRC/errlog @@ -116,24 +123,6 @@ check_job ${PRODUCT_DIR}/INSTALL.LOG make install #du -sk ${PRODUCT_DIR}_SRC > ${PRODUCT_DIR}/size.log cd ${PRODUCT_DIR}; -### modify libmed.la libmedC.la files to correct direct path to hdf5 library -cd ${PRODUCT_DIR}/lib -sed -e 's%\(.*\)\([[:space:]].*libhdf5.la\)\(.*\)%\1 -lhdf5\3%g' libmed.la > libmed.la.new -mv -f libmed.la.new libmed.la -sed -e 's%\(.*\)\([[:space:]].*libhdf5.la\)\(.*\)%\1 -lhdf5\3%g' libmedC.la > libmedC.la.new -mv -f libmedC.la.new libmedC.la -tmp="" -if [ -n "${HDF5HOME}" ]; then - tmp="-L${HDF5HOME}/lib" -fi -sed -e "s%\(.*\)\([[:space:]].*-L.*/hdf5-[0-9]\.[0-9]\.[0-9]/lib[[:space:]]\)\(.*\)%\1 $tmp \3%g" libmed.la > libmed.la.new -mv -f libmed.la.new libmed.la -sed -e "s%\(.*\)\([[:space:]].*-L.*/hdf5-[0-9]\.[0-9]\.[0-9]/lib[[:space:]]\)\(.*\)%\1 $tmp \3%g" libmedC.la > libmedC.la.new -mv -f libmedC.la.new libmedC.la - -chmod 755 libmed.la -chmod 755 libmedC.la - # remove sources and temporary files after building if [ ${REMOVE_SRC_TMP} == "TRUE" ] ; then test -d ${PRODUCT_DIR}_SRC && rm -fr ${PRODUCT_DIR}_SRC @@ -162,9 +151,9 @@ tmp="" if [ -n "${HDF5HOME}" ]; then tmp="-L${HDF5HOME}/lib" fi -sed -e "s%\(.*\)\([[:space:]].*-L.*/hdf5-[0-9]\.[0-9]\.[0-9]/lib[[:space:]]\)\(.*\)%\1 $tmp \3%g" libmed.la > libmed.la.new +sed -e "s%\(-L[^[:space:]]*/hdf5-[0-9]\.[0-9]\.[0-9]/lib[[:space:]]\)%$tmp %g" libmed.la > libmed.la.new mv -f libmed.la.new libmed.la -sed -e "s%\(.*\)\([[:space:]].*-L.*/hdf5-[0-9]\.[0-9]\.[0-9]/lib[[:space:]]\)\(.*\)%\1 $tmp \3%g" libmedC.la > libmedC.la.new +sed -e "s%\(-L[^[:space:]]*/hdf5-[0-9]\.[0-9]\.[0-9]/lib[[:space:]]\)%$tmp %g" libmedC.la > libmedC.la.new mv -f libmedC.la.new libmedC.la chmod 755 libmed.la @@ -189,7 +178,7 @@ export PRODUCT_TYPE=$6; export INSTALL_PRODUCTS=$7; shift REMOVE_SRC_TMP=$8; -export PRODUCT="med-2.2.3" +export PRODUCT="med-2.3.1" export PRODUCT_DIR=${INSTALL_ROOT}/${PRODUCT} export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} source ./common.sh diff --git a/config_files/qt-3.3.3.sh b/config_files/qt-3.3.3.sh deleted file mode 100755 index 9cd044a..0000000 --- a/config_files/qt-3.3.3.sh +++ /dev/null @@ -1,201 +0,0 @@ -#!/bin/bash -noprofile - -#################################################################################### -# File : qt-3.3.3.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-2007 CEA -# -# This script is the part of the SALOME installation procedure. -# -#################################################################################### - -check_version(){ -if [ -z "$QTDIR" ] || [ ! -f ${QTDIR}/include/qglobal.h ]; then - return 1 -fi - -ver=`grep "QT_VERSION_STR" ${QTDIR}/include/qglobal.h | sed -e 's%^#define QT_VERSION_STR\([[:space:]]*\)%%g' -e 's%\"%%g'` -if [ "$ver" == "3.3.3" ] ; then - return 0 -fi -return 1 -} - -print_env_bin() -{ -cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh < ${INSTALL_WORK}/env_${PRODUCT_TYPE}_src.sh < configure -chmod +x configure - -export QTDIR=${PRODUCT_DIR}_SRC -export LD_LIBRARY_PATH=${QTDIR}/lib:$LD_LIBRARY_PATH - -# basic flags -QT_FLAGS="-release -thread -shared -qt-gif -platform linux-g++" -# use system graphics libraries -QT_FLAGS=$QT_FLAGS" -system-libjpeg -system-libpng -system-libmng -qt-imgfmt-jpeg -qt-imgfmt-png -qt-imgfmt-mng -lpng -lmng -ljpeg" -# use all plugin styles except -plugin-style-windows -QT_FLAGS=$QT_FLAGS" -plugin-style-cde -plugin-style-compact -plugin-style-motif -plugin-style-motifplus -plugin-style-platinum -plugin-style-sgi" - -# add -dlopen-opengl flag (ONLY if the corresponding patch was applied) -if [ "$patched_for_gl" == "yes" ] ; then - QT_FLAGS=$QT_FLAGS" -dlopen-opengl" -fi - -# configure -check_job ${PRODUCT_DIR}/CONFIGURE.LOG ./configure $QT_FLAGS -prefix ${PRODUCT_DIR} - -sed -e "s%^all: symlinks src-qmake src-moc sub-src sub-tools sub-tutorial sub-examples%all: symlinks src-qmake src-moc sub-src sub-tools%g" Makefile > _Makefile -mv -f _Makefile Makefile - -GCC=`which gcc` -cat >> ${PRODUCT_DIR}/MAKE.LOG < ${PRODUCT_DIR}/lib/libqt-mt.la.new - mv -f ${PRODUCT_DIR}/lib/libqt-mt.la.new ${PRODUCT_DIR}/lib/libqt-mt.la -fi - -#rm -rf ${PRODUCT_DIR}/doc - -#du -sk ${PRODUCT_DIR}_SRC > ${PRODUCT_DIR}/size.log -cd ${PRODUCT_DIR}; - -# remove sources and temporary files after building -if [ ${REMOVE_SRC_TMP} == "TRUE" ] ; then - test -d ${PRODUCT_DIR}_SRC && rm -fr ${PRODUCT_DIR}_SRC -fi - -# to generate environment scripts -try_preinstalled -} - -install_binary() -{ -make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE} -source ${INSTALL_WORK}/$SHRC - -check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}.tar.gz -C ${INSTALL_ROOT} - -cd ${PRODUCT_DIR}/lib - -# modify libdir -sed -e "s%^libdir='\(.*\)'%libdir='${PRODUCT_DIR}/lib'%g" libqt-mt.la > libqt-mt.la.new -mv -f libqt-mt.la.new libqt-mt.la - -# modify libGL.so flags -has_gl_dep=`grep -E "^dependency_libs=.*-lGL.*" libqt-mt.la` -gllibdir="`where_gl_libs`" -if [ "$has_gl_dep" != "" ] && [ "$gllibdir" != "" ] ; then - sed -e "s%-lGL%%g" \ - -e "s%^dependency_libs='\(.*\)%dependency_libs='-L$gllibdir -lGL \1%g" \ - libqt-mt.la > libqt-mt.la.new - mv -f libqt-mt.la.new libqt-mt.la -fi - -# modify qt package config -cd ${PRODUCT_DIR}/lib/pkgconfig -sed -e "s%^prefix=\(.*\)%prefix=${PRODUCT_DIR}%g" qt-mt.pc > qt-mt.pc.new -mv -f qt-mt.pc.new qt-mt.pc - -# to generate environment scripts -try_preinstalled -} - -export PROCEDURE=$1; -export INSTALL_WORK=$2; -export SOURCE_DIR=$3; -export INSTALL_ROOT=$4; -export PRODUCT_SEQUENCE=$5; -export PRODUCT_TYPE=$6; -export INSTALL_PRODUCTS=$7; -shift -REMOVE_SRC_TMP=$8; -export PRODUCT="qt-3.3.3" -export PRODUCT_DIR=${INSTALL_ROOT}/${PRODUCT} -export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} -source ./common.sh -$PROCEDURE diff --git a/config_files/qt-3.3.4.sh b/config_files/qt-3.3.8.sh similarity index 91% rename from config_files/qt-3.3.4.sh rename to config_files/qt-3.3.8.sh index 3c2f015..a5a7266 100755 --- a/config_files/qt-3.3.4.sh +++ b/config_files/qt-3.3.8.sh @@ -1,7 +1,7 @@ #!/bin/bash -noprofile #################################################################################### -# File : qt-3.3.4.sh +# File : qt-3.3.8.sh # Created : Thu Dec 18 12:01:00 2002 # Author : Vadim SANDLER, Open CASCADE SAS (vadim.sandler@opencascade.com) # Project : SALOME @@ -17,7 +17,7 @@ if [ -z "$QTDIR" ]; then return 1 fi ver=`grep "QT_VERSION_STR" ${QTDIR}/include/qglobal.h | sed -e 's%^#define QT_VERSION_STR\([[:space:]]*\)%%g' -e 's%\"%%g'` -if [ "$ver" == "3.3.4" ] ; then +if [ "$ver" == "3.3.8" ] ; then return 0 fi return 1 @@ -72,21 +72,6 @@ install_source # build sources makedir ${PRODUCT_DIR} -# apply patch : fix pb of libGL loading -if [ -f patches/qt-3.3.3-load-gl.patch ] ; then - cp patches/qt-3.3.3-load-gl.patch ${PRODUCT_DIR}_SRC - ( cd ${PRODUCT_DIR}_SRC ; patch -p1 < qt-3.3.3-load-gl.patch ) - patched_for_gl="yes" -fi - -# apply patch for 64-bit platforms -if test `uname -m` = "x86_64" ; then - if [ -f patches/qt-3.3.4-lib64.patch ] ; then - cp patches/qt-3.3.4-lib64.patch ${PRODUCT_DIR}_SRC - ( cd ${PRODUCT_DIR}_SRC ; patch -p1 < qt-3.3.4-lib64.patch ) - fi -fi - cd ${PRODUCT_DIR}_SRC mv -f configure configure-orig @@ -215,7 +200,7 @@ export PRODUCT_TYPE=$6; export INSTALL_PRODUCTS=$7; shift REMOVE_SRC_TMP=$8; -export PRODUCT="qt-3.3.4" +export PRODUCT="qt-3.3.8" export PRODUCT_DIR=${INSTALL_ROOT}/${PRODUCT} export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT} source ./common.sh -- 2.39.2