X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=config_files%2Fbuild.sh;h=7ac3871cc6f39184d91954e84238fac6b15ccc48;hb=84c37a8987289d79dba5f06f68571c21dcc695c6;hp=6705db0ae80a8df281a244e6dbe7a5e94fb4277e;hpb=7328684db23e6b73fd52a53ad7188bcb3398d963;p=tools%2Finstall.git diff --git a/config_files/build.sh b/config_files/build.sh index 6705db0..7ac3871 100755 --- a/config_files/build.sh +++ b/config_files/build.sh @@ -84,7 +84,7 @@ inst_with_gui=1 is_delete=0 verbose_level=2 params="" -modules="KERNEL GUI GEOM MED SMESH VISU YACS NETGENPLUGIN GHS3DPLUGIN BLSURFPLUGIN HexoticPLUGIN GHS3DPRLPLUGIN COMPONENT PYCALCULATOR CALCULATOR HELLO PYHELLO LIGHT PYLIGHT SIERPINSKY RANDOMIZER" +modules="KERNEL GUI GEOM MED SMESH VISU PARAVIS YACS NETGENPLUGIN GHS3DPLUGIN BLSURFPLUGIN HexoticPLUGIN GHS3DPRLPLUGIN COMPONENT PYCALCULATOR CALCULATOR HELLO PYHELLO LIGHT PYLIGHT SIERPINSKY RANDOMIZER HEXABLOCK HEXABLOCKPLUGIN ATOMIC ATOMGEN ATOMSOLV HOMARD JOBMANAGER" optim="" is_install=1 is_tui=0 @@ -229,7 +229,7 @@ for module in ${modules}; do # check if configure script exists ######################################################### cfg_exist=0 - if [ -e ${module_src}/configure ] ; then + if [ -e ${module_src}/configure ] || [ -e ${module_src}/CMakeLists.txt ] ; then cfg_exist=1 fi ######################################################### @@ -241,9 +241,12 @@ for module in ${modules}; do ######################################################### # check if build_configure script exists ######################################################### - if [ ! -e ${module_src}/build_configure ] ; then + if [ ! -e ${module_src}/build_configure ] && [ "${module}" != "PARAVIS" ] ; then echo '!!! Warning !!! Cannot find build_configure script in '${module_src}'.' else + if [ "${module}" == "PARAVIS" ]; then + echo '!!! Warning !!! build_configure step is not executed for '${module}'.' + else ######################################################### # call build_configure ######################################################### @@ -260,6 +263,7 @@ for module in ${modules}; do cat ${LOG_DIR}/build_configure_${module}.log | grep -E "(failed|: error:)" >&2 fi fi + fi fi ######################################################### # deleting build directory if -d flag is given @@ -299,12 +303,6 @@ for module in ${modules}; do # previous launch ######################################################### opts_changed=0 -## if [ -f ${module_build}/config.log ] ; then -## old_prefix=`grep -e '^prefix=' ${module_build}/config.log | sed -e "s%^prefix='\(.*\)'%\1%"` -## if [ "$old_prefix" != "$prefix" ] ; then -## opts_changed=1 -## fi -## fi ######################################################### # define installation directory (by using module's version # number); default is a build directory @@ -317,17 +315,17 @@ for module in ${modules}; do if [ "$vx" == "" ] ; then vx=`grep -e "^AC_INIT" ${module_src}/configure.in.base | sed -e "s%.*\[\([[:digit:].]*\)\].*%\1%g"` fi + elif [ -e ${module_src}/CMakeLists.txt ] ; then + ver_maj=`cat ${module_src}/CMakeLists.txt | grep SET\(VERSION_MAJOR | sed -e "s%[A-Z_() ]%%g"` + ver_min=`cat ${module_src}/CMakeLists.txt | grep SET\(VERSION_MINOR | sed -e "s%[A-Z_() ]%%g"` + ver_maintenance=`cat ${module_src}/CMakeLists.txt | grep SET\(VERSION_MAINTENANCE | sed -e "s%[A-Z_() ]%%g"` + vx="${ver_maj}.${ver_min}.${ver_maintenance}" fi if [ "$vx" != "" ] ; then vx="_$vx" fi if [ "$prefix" == "" ] ; then - #module_root_dir=`printenv ${module}_ROOT_DIR` - #if [ "$module_root_dir" != "" ] ; then - # px=$module_root_dir - #else px=${BUILD_DIR}${def_install_dir}/${module}${vx} - #fi else px=$prefix/${module}${vx} fi @@ -340,7 +338,7 @@ for module in ${modules}; do ######################################################### # check if configure script exists ######################################################### - if [ ! -e ${module_src}/configure ] ; then + if [ ! -e ${module_src}/configure ] && [ "${module}" != "PARAVIS" ] ; then echo echo '!!! Warning !!! Can not find configure script in '${module_src}'.' echo @@ -355,7 +353,13 @@ for module in ${modules}; do if [ "${module}" == "NETGENPLUGIN" ] && [ "$NETGENHOME" != "" ] ; then myconf_keys="${myconf_keys} --with-netgen=${NETGENHOME}" fi + + if [ "${module}" == "PARAVIS" ] ; then + cd ${module_build}; cmake ${module_src} -DCMAKE_INSTALL_PREFIX=$px >& ${LOG_DIR}/configure_${module}.log + else ${module_src}/configure --prefix=$px ${optim} ${myconf_keys} >& ${LOG_DIR}/configure_${module}.log + fi + ######################################################### # echo possible errors #########################################################