]> SALOME platform Git repositories - tools/install.git/commitdiff
Salome HOME
SALOME 6.5.0 preparation: update script for freeimage (3.14.1)
authorvsr <vsr@opencascade.com>
Tue, 3 Apr 2012 19:14:15 +0000 (19:14 +0000)
committervsr <vsr@opencascade.com>
Tue, 3 Apr 2012 19:14:15 +0000 (19:14 +0000)
13 files changed:
config_CentOS_5.5_64bit.xml
config_Debian_4.0.xml
config_Debian_4.0_64bit.xml
config_Debian_5.0_64bit.xml
config_Debian_6.0_64bit.xml
config_Mandriva_2008.0.xml
config_Mandriva_2008.0_64bit.xml
config_Mandriva_2010.0.xml
config_Mandriva_2010.0_64bit.xml
config_Red_Hat_Enterprise_WS_4_64bit.xml
config_Scientific_SL_5.1_64bit.xml
config_files/freeimage-3.14.1.sh [deleted file]
config_files/freeimage.sh [new file with mode: 0755]

index 55d5affb997c559683198000d4f80ab98449dec6..8f16f471d7cc6fafc986e51a7f58a23b0c84f9ff 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index 076be2979e44062158d3c62a4a311fcacb967ca3..a1ca3ab1a926dda3d58e0a2fc140e1cd87f34b02 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index 05f0c7d46a06d61d6e2d5dcf083f08e8030199c5..f509ecfdbe2f9e2d373672861621737fbf2cc72f 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index 455ebdbb805da0c5806ed25c0be2b7fca09986b5..0e645c9d42e02d1e333735ef0750cfdf840373df 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index 2411c1b1540541e981aeebe7bca373555e8a415a..76d87290cd7b3f42bee25f56e8143a7cdfa7c7cd 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index f90277ff3f31e02823d1f4c71a0092f41d38f8ec..5b40ce92e7307b3d0b4bd35472e204b0bee76b1e 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index 88086573e1b6c27e2016e873fcf2fe7bd3475dcc..4e43ee63eee6ab9b90ff183321d0e6b43c732d5c 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index 73370416e6f2b32190e7a03eac4d51d9214cda56..488480d0ebeea2e220bbac36d155711fee66ff06 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index 101a5fd33b77fa5cee0902df13e8933f4f0f186f..68170151a89123476307fc6c033a9580f598cc32 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index 9e177cf66d94dcc1235901260248bd2b98b867a3..f65a4e9efe1cefbc9da1967b3a1f1ccf1dd88ef8 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
index fa08bb33ab64ddfd3b29123f54c15dd423157396..fc15abc09902c7fa9d006bb5272f34f4cf937b6c 100755 (executable)
                     version="3.14.1" 
                    disable="false"
                    installdiskspace="86460,273932,478152"
-                   script="freeimage-3.14.1.sh"/>
+                   script="freeimage.sh"/>
     </product>
     <product name="cmake"
             type="prerequisite"
diff --git a/config_files/freeimage-3.14.1.sh b/config_files/freeimage-3.14.1.sh
deleted file mode 100755 (executable)
index b2ee2e7..0000000
+++ /dev/null
@@ -1,153 +0,0 @@
-#!/bin/bash -noprofile
-
-####################################################################################
-#  File      : freeimage-3.14.1.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.
-#
-####################################################################################
-
-FREEIMAGE_REF_VERSION="3.14.1"
-
-check_version()
-{
-# check existance of freeimage and its version
-if [ -n ${FREEIMAGEDIR} ]; then
-  return 0
-fi
-ver_major=`cat ${PRODUCT_SRC_DIR}/FreeImage.rc | grep PRODUCTVERSION | sed -e "s%[A-Z0 ]%%g" | sed -e "s%[,]% %g" | awk '{ print $1}'`
-ver_minor=`cat ${PRODUCT_SRC_DIR}/FreeImage.rc | grep PRODUCTVERSION | sed -e "s%[A-Z0 ]%%g" | sed -e "s%[,]% %g" | awk '{ print $2}'`
-ver_maint=`cat ${PRODUCT_SRC_DIR}/FreeImage.rc | grep PRODUCTVERSION | sed -e "s%[A-Z0 ]%%g" | sed -e "s%[,]% %g" | awk '{ print $3}'`
-ver="$ver_major.$ver_minor.$ver_maint"
-if [ "$ver" == "${FREEIMAGE_REF_VERSION}" ] ; then
-    return 0
-fi
-return 1
-}
-
-print_env_bin()
-{
-cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <<EOF 
-#$DELIM ${PRODUCT_TYPE} $DELIM
-export FREEIMAGEDIR=\${INST_ROOT}/${SINGLE_DIR:-${PRODUCT}}
-export PATH=\${FREEIMAGEDIR}/bin:\$PATH 
-export LD_LIBRARY_PATH=\${FREEIMAGEDIR}/lib:\${LD_LIBRARY_PATH}
-##
-EOF
-(test -w ${PRODUCT_DIR} && cp ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh ${PRODUCT_DIR})
-make_env ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}"
-}
-
-print_env_src()
-{
-cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}_src.sh <<EOF
-# nothing to do
-##
-EOF
-(test -w ${PRODUCT_SRC_DIR} && cp ${INSTALL_WORK}/env_${PRODUCT_TYPE}_src.sh ${PRODUCT_SRC_DIR})
-make_env ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}"
-}
-
-try_preinstalled(){
-try_existing ${PRODUCT_DIR} ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE}
-try_existing ${PRODUCT_SRC_DIR} ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE}_src
-return $?
-}
-
-install_source()
-{
-make_env ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE}_src
-source ${INSTALL_WORK}/$SHRC
-
-# unpack
-check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}.tar.gz -C ${INST_ROOT}
-
-# to generate environment scripts
-try_preinstalled
-}
-
-install_source_and_build()
-{
-# install sources
-install_source
-
-# build sources
-test -z ${SINGLE_DIR} && makedir ${PRODUCT_DIR} || mkdir -p ${PRODUCT_DIR}
-
-cd ${PRODUCT_SRC_DIR}
-
-## building FreeImage library
-
-# compile
-#check_job ${PRODUCT_DIR}/MAKE.LOG 
-check_job ${PRODUCT_DIR}/MAKE.LOG make -f Makefile.gnu
-
-# install
-#check_job ${PRODUCT_DIR}/INSTALL.LOG 
-check_job ${PRODUCT_DIR}/INSTALL.LOG make -f Makefile.gnu DESTDIR=${PRODUCT_DIR} install 
-
-#clean temporary files. 
-make -f Makefile.fip clean 
-
-## building FreeImagePlus library
-
-# compile
-#check_job ${PRODUCT_DIR}/MAKE.LOG 
-check_job ${PRODUCT_DIR}/MAKEPLUS.LOG make -f Makefile.fip 
-
-# install
-#check_job ${PRODUCT_DIR}/INSTALL.LOG 
-check_job ${PRODUCT_DIR}/INSTALLPLUS.LOG make -f Makefile.fip DESTDIR=${PRODUCT_DIR} install 
-
-#clean temporary files. 
-make -f Makefile.fip clean 
-
-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}
-
-### modifing la files
-cd ${PRODUCT_DIR}/lib
-
-# 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="freeimage-${FREEIMAGE_REF_VERSION}"
-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/freeimage.sh b/config_files/freeimage.sh
new file mode 100755 (executable)
index 0000000..a514768
--- /dev/null
@@ -0,0 +1,151 @@
+#!/bin/bash -noprofile
+
+####################################################################################
+#  File      : freeimage.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-2012 CEA
+#
+#  This script is the part of the SALOME installation procedure.
+#
+####################################################################################
+
+#
+# freeimage version
+#
+FREEIMAGE_VERSION=3.14.1
+
+check_version()
+{
+# check existance of freeimage and its version
+if [ "${FREEIMAGEDIR}" != "" ] && [ -f ${FREEIMAGEDIR}/include/FreeImage.h ] ; then
+    ver_major=`grep "#define FREEIMAGE_MAJOR_VERSION"  ${FREEIMAGEDIR}/include/FreeImage.h | awk '{print $3}'`
+    ver_minor=`grep "#define FREEIMAGE_MINOR_VERSION"  ${FREEIMAGEDIR}/include/FreeImage.h | awk '{print $3}'`
+    ver_maint=`grep "#define FREEIMAGE_RELEASE_SERIAL" ${FREEIMAGEDIR}/include/FreeImage.h | awk '{print $3}'`
+    ver="$ver_major.$ver_minor.$ver_maint"
+    if [ "$ver" == "${FREEIMAGE_VERSION}" ] ; then
+        return 0
+    fi
+fi
+return 1
+}
+
+print_env_bin()
+{
+cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <<EOF 
+#$DELIM ${PRODUCT_TYPE} $DELIM
+export FREEIMAGEDIR=\${INST_ROOT}/${SINGLE_DIR:-${PRODUCT}}
+export PATH=\${FREEIMAGEDIR}/bin:\$PATH 
+export LD_LIBRARY_PATH=\${FREEIMAGEDIR}/lib:\${LD_LIBRARY_PATH}
+##
+EOF
+(test -w ${PRODUCT_DIR} && cp ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh ${PRODUCT_DIR})
+make_env ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}"
+}
+
+print_env_src()
+{
+cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}_src.sh <<EOF
+# nothing to do
+##
+EOF
+(test -w ${PRODUCT_SRC_DIR} && cp ${INSTALL_WORK}/env_${PRODUCT_TYPE}_src.sh ${PRODUCT_SRC_DIR})
+make_env ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}"
+}
+
+try_preinstalled(){
+try_existing ${PRODUCT_DIR} ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE}
+try_existing ${PRODUCT_SRC_DIR} ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE}_src
+return $?
+}
+
+install_source()
+{
+make_env ${INST_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" "${INSTALL_PRODUCTS}" ${PRODUCT_TYPE}_src
+source ${INSTALL_WORK}/$SHRC
+
+# unpack
+check_jb tar xfz ${SOURCE_DIR}/${PRODUCT}.tar.gz -C ${INST_ROOT}
+
+# to generate environment scripts
+try_preinstalled
+}
+
+install_source_and_build()
+{
+# install sources
+install_source
+
+# build sources
+test -z ${SINGLE_DIR} && makedir ${PRODUCT_DIR} || mkdir -p ${PRODUCT_DIR}
+
+cd ${PRODUCT_SRC_DIR}
+
+## building FreeImage library
+
+# compile
+check_job ${PRODUCT_DIR}/MAKE.LOG make -f Makefile.gnu
+
+# install
+check_job ${PRODUCT_DIR}/INSTALL.LOG make -f Makefile.gnu DESTDIR=${PRODUCT_DIR} install 
+
+# clean temporary files. 
+make -f Makefile.fip clean 
+
+## building FreeImagePlus library
+
+# compile
+check_job ${PRODUCT_DIR}/MAKEPLUS.LOG make -f Makefile.fip 
+
+# install
+check_job ${PRODUCT_DIR}/INSTALLPLUS.LOG make -f Makefile.fip DESTDIR=${PRODUCT_DIR} install 
+
+# clean temporary files. 
+make -f Makefile.fip clean 
+
+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}
+
+### modifing la files
+cd ${PRODUCT_DIR}/lib
+
+# 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="freeimage-${FREEIMAGE_VERSION}"
+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