]> SALOME platform Git repositories - plugins/blsurfplugin.git/commitdiff
Salome HOME
Implement --with[out]-gui option.
authorjfa <jfa@opencascade.com>
Thu, 22 May 2008 08:26:29 +0000 (08:26 +0000)
committerjfa <jfa@opencascade.com>
Thu, 22 May 2008 08:26:29 +0000 (08:26 +0000)
adm_local/unix/make_commence.in
build_configure
configure.in.base
src/Makefile.in

index afa9ef585cd5b489854340a484f8e6d1eeb3319c..ed5162bdb8119ed6bb850791841fc7dd7e8a293d 100644 (file)
@@ -265,20 +265,32 @@ ac_cxx_partial_specialization.m4  python.m4                               \
 ac_cxx_typename.m4                check_pthreads.m4  check_cas.m4      \
 ac_cc_warnings.m4                 check_swig.m4             check_boost.m4 
 
-ACLOCAL_GUI = \
-check_vtk.m4                      check_opengl.m4    check_qt.m4       \
-check_GUI.m4                      check_corba_in_GUI.m4
-
 ACLOCAL_GEOM =                    check_GEOM.m4
 
 ACLOCAL_SMESH =                   check_SMESH.m4
 
+ifeq ($(BLSURFPLUGIN_WITH_GUI),yes)
+ACLOCAL_GUI = \
+check_vtk.m4                      check_opengl.m4    check_qt.m4       \
+check_GUI.m4                      check_corba_in_GUI.m4
+
 $(top_srcdir)/aclocal.m4: $(ACLOCAL_KERNEL%=@KERNEL_ROOT_DIR@/salome_adm/unix/config_files/%) \
                           $(ACLOCAL_GUI:%=@GUI_ROOT_DIR@/adm_local/unix/config_files/%) \
                           $(ACLOCAL_GEOM:%=@GEOM_ROOT_DIR@/adm_local/unix/config_files/%) \
                           $(ACLOCAL_SMESH:%=@SMESH_ROOT_DIR@/adm_local/unix/config_files/%)
-       cd $(top_srcdir) ; 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 @GEOM_ROOT_DIR@/adm_local/unix/config_files \
-                                                                       -I @SMESH_ROOT_DIR@/adm_local/unix/config_files
-                                                              
+       cd $(top_srcdir) ; 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 @GEOM_ROOT_DIR@/adm_local/unix/config_files \
+                                   -I @SMESH_ROOT_DIR@/adm_local/unix/config_files
+endif
+
+ifeq ($(BLSURFPLUGIN_WITH_GUI),no)
+$(top_srcdir)/aclocal.m4: $(ACLOCAL_KERNEL%=@KERNEL_ROOT_DIR@/salome_adm/unix/config_files/%) \
+                          $(ACLOCAL_GEOM:%=@GEOM_ROOT_DIR@/adm_local/unix/config_files/%) \
+                          $(ACLOCAL_SMESH:%=@SMESH_ROOT_DIR@/adm_local/unix/config_files/%)
+       cd $(top_srcdir) ; aclocal -I adm_local/unix/config_files \
+                                  -I @KERNEL_ROOT_DIR@/salome_adm/unix/config_files \
+                                   -I @GEOM_ROOT_DIR@/adm_local/unix/config_files \
+                                   -I @SMESH_ROOT_DIR@/adm_local/unix/config_files
+endif
index 249463d86dbe0028e9c974e8c03bb8aed8f98b95..3c2ee24c4221a99f47c362a2389d176a08c57c7c 100755 (executable)
@@ -10,6 +10,7 @@
 
 ORIG_DIR=`pwd`
 CONF_DIR=`echo $0 | sed -e "s,[^/]*$,,;s,/$,,;s,^$,.,"`
+BLSURFPLUGIN_WITH_GUI="yes"
 
 ########################################################################
 # Test if the KERNEL_ROOT_DIR is set correctly
@@ -25,12 +26,27 @@ fi
 #    echo "failed : KERNEL_SRC variable is not correct !"
 #    exit
 #fi
+
+for option
+do
+  case $option in
+      -with-gui | --with-gui)
+          BLSURFPLUGIN_WITH_GUI="yes"
+          break;;
+      -without-gui | --without-gui | -with-gui=no | --with-gui=no)
+          BLSURFPLUGIN_WITH_GUI="no"
+          break;;
+  esac
+done
+
 ########################################################################
 # Test if the GUI_ROOT_DIR is set correctly
 
-if test ! -d "${GUI_ROOT_DIR}"; then
+if test ${BLSURFPLUGIN_WITH_GUI} = yes; then
+  if test ! -d "${GUI_ROOT_DIR}"; then
     echo "failed : GUI_ROOT_DIR variable is not correct !"
     exit
+  fi
 fi
 
 ########################################################################
@@ -234,12 +250,23 @@ else
        echo -n "Creating 'configure' script ...  "
 fi
 
-aclocal -I adm_local/unix/config_files -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files \
-                                       -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files/DEPRECATED \
-                                       -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 
+if test ${BLSURFPLUGIN_WITH_GUI} = yes; then
+  aclocal -I adm_local/unix/config_files \
+          -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files \
+          -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files/DEPRECATED \
+          -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 
+else
+  aclocal -I adm_local/unix/config_files \
+          -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files \
+          -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files/DEPRECATED \
+          -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 
+fi
+
 if autoconf
 then
        echo "done"
index 2dd3674dac0e0a5b1191e0d21a5b17ec7a73fa9e..4903ec746e8ae2b69cac62d45f2758f16b530ef9 100644 (file)
@@ -193,37 +193,68 @@ AC_SUBST_FILE(CORBA)
 corba=make_$ORB
 CORBA=adm_local/unix/$corba
 
-echo
-echo ---------------------------------------------
-echo testing openGL
-echo ---------------------------------------------
-echo
+dnl
+dnl ---------------------------------------------
+dnl testing WITHGUI
+dnl ---------------------------------------------
+dnl
 
-CHECK_OPENGL
+CHECK_WITHGUI
 
-echo
-echo ---------------------------------------------
-echo testing QT
-echo ---------------------------------------------
-echo
+if test "X$WITHGUI" = "Xyes"; then
 
-CHECK_QT
+   echo
+   echo ---------------------------------------------
+   echo testing openGL
+   echo ---------------------------------------------
+   echo
 
-echo
-echo ---------------------------------------------
-echo testing MSG2QM
-echo ---------------------------------------------
-echo
+   CHECK_OPENGL
 
-CHECK_MSG2QM
+   echo
+   echo ---------------------------------------------
+   echo testing QT
+   echo ---------------------------------------------
+   echo
 
-echo
-echo ---------------------------------------------
-echo testing VTK
-echo ---------------------------------------------
-echo
+   CHECK_QT
+
+   echo
+   echo ---------------------------------------------
+   echo testing MSG2QM
+   echo ---------------------------------------------
+   echo
+
+   CHECK_MSG2QM
+
+   echo
+   echo ---------------------------------------------
+   echo testing VTK
+   echo ---------------------------------------------
+   echo
 
-CHECK_VTK
+   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 BLSURFPLUGIN module necessary full GUI !"
+     exit
+   fi
+fi
 
 echo
 echo ---------------------------------------------
@@ -257,26 +288,6 @@ echo
 
 CHECK_HTML_GENERATORS
 
-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 BLSURFPLUGIN module necessary full GUI !"
-  exit
-fi
-
 echo
 echo ---------------------------------------------
 echo Testing Kernel
@@ -324,7 +335,14 @@ echo ---------------------------------------------
 echo
 
 echo Configure
+
+if test "X$WITHGUI" = "Xyes"; 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 SMesh_ok BLSURF_ok"
+fi
+
+if test "X$WITHGUI" = "Xno"; 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 SMesh_ok BLSURF_ok"
+fi
 
 for var in $variables
 do
index eb2857b79d905286852f98cbcf9ea1fd90a92c02..c38ea7485fa6343926f50a94bf6852c61318a14f 100644 (file)
@@ -30,6 +30,10 @@ VPATH=.:@srcdir@
 
 @COMMENCE@
 
-SUBDIRS = BLSURFPlugin GUI
+SUBDIRS = BLSURFPlugin
+
+ifeq (@WITHIHM@,yes)
+  SUBDIRS += GUI
+endif
 
 @MODULE@