]> SALOME platform Git repositories - tools/install.git/blob - config_files/SAMPLES.sh
Salome HOME
Fix a problem with *.la files caused by modifications in KERNEL module compilation...
[tools/install.git] / config_files / SAMPLES.sh
1 #!/bin/sh
2
3 check_version(){
4 # There is no possibility to check version number
5 return 0
6 }
7
8 print_env(){
9 cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <<EOF 
10 #$DELIM ${PRODUCT_TYPE} $DELIM
11 export DATA_DIR=\${INSTALL_ROOT}/${PRODUCT}
12 ##
13 EOF
14 (test -w ${PRODUCT_DIR} && cp ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh ${PRODUCT_DIR})
15 make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}"
16 }
17
18 # looks for the native product and collects it's environment (used by make_env())
19 try_native(){
20 check_version
21 if [ $? -eq 0 ] ; then
22     cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <<EOF 
23 #$DELIM ${PRODUCT_TYPE} $DELIM
24 export DATA_DIR=\${INSTALL_ROOT}/${PRODUCT}
25 ##
26 EOF
27     make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}"
28     return 0
29 fi
30 return 1;
31 }
32
33 try_preinstalled(){
34 try_existing ${PRODUCT_DIR} ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" ${PRODUCT_TYPE}
35 return $?
36 }
37
38 install_source()
39 {
40 make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" ${PRODUCT_TYPE}
41 source ${INSTALL_WORK}/$SHRC
42
43 check_jb tar xfz ${SOURCE_DIR}/SAMPLESsourcesV3.2.0a2.tar.gz -C ${INSTALL_ROOT}
44
45 print_env
46 }
47
48 install_binary()
49 {
50 return 1
51 }
52
53 export PROCEDURE=$1;
54 export INSTALL_WORK=$2;
55 export SOURCE_DIR=$3;
56 export INSTALL_ROOT=$4;
57 export PRODUCT_SEQUENCE=$5;
58 if [ $# == 6 ] ; then export PRODUCT_TYPE=$6 ; else export PRODUCT_TYPE="Samples" ; fi
59 export PRODUCT="SAMPLES_SRC_3.2.0a2"
60 export PRODUCT_DIR=${INSTALL_ROOT}/${PRODUCT}
61 export PRODUCT_WORK=${INSTALL_WORK}/${PRODUCT}
62 source ./common.sh
63 $PROCEDURE