]> SALOME platform Git repositories - plugins/ghs3dprlplugin.git/commitdiff
Salome HOME
Fix for bug 0019977: Installation of Salome modules wihtout gui. V5_1_1a2 V5_1_1rc1
authormzn <mzn@opencascade.com>
Thu, 26 Feb 2009 07:17:40 +0000 (07:17 +0000)
committermzn <mzn@opencascade.com>
Thu, 26 Feb 2009 07:17:40 +0000 (07:17 +0000)
build_configure
configure.ac

index c0fa009bf5cfe3ce09a4467a99cd3bcf034b42b3..160bf7e9983cd4168cfc498d4f1638cc3f319687 100755 (executable)
@@ -27,7 +27,6 @@
 
 ORIG_DIR=`pwd`
 CONF_DIR=`echo $0 | sed -e "s,[^/]*$,,;s,/$,,;s,^$,.,"`
-GHS3DPRLPLUGIN_WITH_GUI="yes"
 
 ########################################################################
 # Test if the KERNEL_ROOT_DIR is set correctly
@@ -44,28 +43,6 @@ fi
 #    exit
 #fi
 
-for option
-do
-  case $option in
-      -with-gui | --with-gui)
-          GHS3DPRLPLUGIN_WITH_GUI="yes"
-          break;;
-      -without-gui | --without-gui | -with-gui=no | --with-gui=no)
-          GHS3DPRLPLUGIN_WITH_GUI="no"
-          break;;
-  esac
-done
-
-########################################################################
-# Test if the GUI_ROOT_DIR is set correctly
-
-if test ${GHS3DPRLPLUGIN_WITH_GUI} = yes; then
-    if test ! -d "${GUI_ROOT_DIR}"; then
-        echo "failed : GUI_ROOT_DIR variable is not correct !"
-        exit
-    fi
-fi
-
 ########################################################################
 # Test if the MED_ROOT_DIR is set correctly
 
@@ -94,10 +71,6 @@ cd ${CONF_DIR}
 ABS_CONF_DIR=`pwd`
 
 #######################################################################
-# Update configure.ac script: to set GHS3DPRLPLUGIN_WITH_GUI variable
-sed -e s/GHS3DPRLPLUGIN_WITH_GUI=[a-z]*/GHS3DPRLPLUGIN_WITH_GUI=${GHS3DPRLPLUGIN_WITH_GUI}/g configure.ac > configure.tmp
-mv -f configure.tmp configure.ac
-
 mkdir -p salome_adm/unix/config_files
 #cp -f ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files/* salome_adm/unix/config_files
 #cp -f ${KERNEL_ROOT_DIR}/salome_adm/unix/pythonbe.py salome_adm/unix
@@ -126,21 +99,11 @@ cp -f ${KERNEL_ROOT_DIR}/salome_adm/unix/SALOMEconfig.h.in salome_adm/unix
 #   aclocal.m4
 #   autom4te.cache (directory)
 echo "====================================================== aclocal"
-
-if test ${GHS3DPRLPLUGIN_WITH_GUI} = yes; then
-  aclocal -I adm_local/unix/config_files \
-          -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files \
-          -I ${GUI_ROOT_DIR}/adm_local/unix/config_files \
-          -I ${MED_ROOT_DIR}/adm_local/unix/config_files \
-          -I ${GEOM_ROOT_DIR}/adm_local/unix/config_files \
-          -I ${SMESH_ROOT_DIR}/adm_local/unix/config_files || exit 1
-else
-  aclocal -I adm_local/unix/config_files \
-          -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files \
-          -I ${MED_ROOT_DIR}/adm_local/unix/config_files \
-          -I ${GEOM_ROOT_DIR}/adm_local/unix/config_files \
-          -I ${SMESH_ROOT_DIR}/adm_local/unix/config_files || exit 1
-fi
+aclocal -I adm_local/unix/config_files \
+        -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files \
+        -I ${MED_ROOT_DIR}/adm_local/unix/config_files \
+        -I ${GEOM_ROOT_DIR}/adm_local/unix/config_files \
+        -I ${SMESH_ROOT_DIR}/adm_local/unix/config_files || exit 1
 
 # ____________________________________________________________________
 # libtoolize creates some configuration files (ltmain.sh,
index c6cab9cc0b35d30f73e860f9e6e78719eb5d8f41..dd5f84413d0d7512d65c24b28891bf972c962fad 100644 (file)
@@ -231,11 +231,34 @@ AC_SUBST_FILE(CORBA)
 corba=make_$ORB
 CORBA=adm_local/unix/$corba
 
-GHS3DPRLPLUGIN_WITH_GUI=yes
+echo
+echo ---------------------------------------------
+echo Testing GUI
+echo ---------------------------------------------
+echo
+
+CHECK_GUI_MODULE
 
-AM_CONDITIONAL(GHS3DPRLPLUGIN_ENABLE_GUI, [test "${GHS3DPRLPLUGIN_WITH_GUI}" = "yes"])
+gui_ok=no
+if test "${SalomeGUI_need}" != "no" -a "${FullGUI_ok}" = "yes" ; then 
+  gui_ok=yes
+fi
 
-if test "${GHS3DPRLPLUGIN_WITH_GUI}" = "yes"; then
+AM_CONDITIONAL(GHS3DPRLPLUGIN_ENABLE_GUI, [test "${gui_ok}" = "yes"])
+
+if test "${SalomeGUI_need}" == "yes"; then
+  if test "${FullGUI_ok}" != "yes"; then
+    AC_MSG_WARN(For configure GHS3DPRLPLUGIN module necessary full GUI!)
+  fi
+elif test "${SalomeGUI_need}" == "auto"; then
+  if test "${FullGUI_ok}" != "yes"; then
+    AC_MSG_WARN(Full GUI not found. Build will be done without GUI!)
+  fi
+elif test "${SalomeGUI_need}" == "no"; then
+  echo Build without GUI option has been chosen
+fi
+
+if test "${gui_ok}" = "yes"; then
     echo
     echo ---------------------------------------------
     echo testing openGL
@@ -259,26 +282,6 @@ if test "${GHS3DPRLPLUGIN_WITH_GUI}" = "yes"; then
     echo
 
     CHECK_VTK
-
-    echo
-    echo ---------------------------------------------
-    echo Testing GUI
-    echo ---------------------------------------------
-    echo
-
-    CHECK_SALOME_GUI
-
-    echo
-    echo ---------------------------------------------
-    echo Testing full GUI
-    echo ---------------------------------------------
-    echo
-
-    CHECK_CORBA_IN_GUI
-    if test "x${CORBA_IN_GUI}" != "xyes"; then
-      echo "failed : For configure GHS3DPRLPLUGIN module necessary full GUI !"
-      exit
-    fi
 fi
 
 echo
@@ -362,13 +365,15 @@ echo
 
 #AM_CONDITIONAL( USE_GFORTRAN, [test "$F77" = "gfortran"])
 
-if test "${GHS3DPRLPLUGIN_WITH_GUI}" = "yes"; then
-variables="cc_ok boost_ok lex_yacc_ok python_ok swig_ok threads_ok OpenGL_ok qt_ok vtk_ok hdf5_ok omniORB_ok occ_ok doxygen_ok graphviz_ok Kernel_ok Geom_ok Med_ok SMesh_ok SalomeGUI_ok libxml_ok"
-opt_variables="GHS3DPRL_ok"
-fi
-if test "${GHS3DPRLPLUGIN_WITH_GUI}" = "no"; then
-variables="cc_ok boost_ok lex_yacc_ok python_ok swig_ok threads_ok hdf5_ok omniORB_ok occ_ok doxygen_ok graphviz_ok Kernel_ok Geom_ok Med_ok SMesh_ok libxml_ok"
-opt_variables="GHS3DPRL_ok"
+if test "${gui_ok}" = "yes"; then
+  variables="cc_ok boost_ok lex_yacc_ok python_ok swig_ok threads_ok OpenGL_ok qt_ok vtk_ok hdf5_ok omniORB_ok occ_ok doxygen_ok graphviz_ok Kernel_ok Geom_ok Med_ok SMesh_ok gui_ok libxml_ok"
+  opt_variables="GHS3DPRL_ok"
+elif test "${SalomeGUI_need}" != "no"; then
+  variables="cc_ok boost_ok lex_yacc_ok python_ok swig_ok threads_ok hdf5_ok omniORB_ok occ_ok doxygen_ok graphviz_ok Kernel_ok Geom_ok Med_ok SMesh_ok gui_ok libxml_ok"
+  opt_variables="GHS3DPRL_ok"
+else
+  variables="cc_ok boost_ok lex_yacc_ok python_ok swig_ok threads_ok hdf5_ok omniORB_ok occ_ok doxygen_ok graphviz_ok Kernel_ok Geom_ok Med_ok SMesh_ok libxml_ok"
+  opt_variables="GHS3DPRL_ok"
 fi
 
 echo