Salome HOME
Join modifications from branch OCC_development_for_3_2_0a2
authorjfa <jfa@opencascade.com>
Mon, 13 Mar 2006 16:22:30 +0000 (16:22 +0000)
committerjfa <jfa@opencascade.com>
Mon, 13 Mar 2006 16:22:30 +0000 (16:22 +0000)
Makefile.in
adm_local/Makefile.in [new file with mode: 0644]
adm_local/unix/config_files/check_CALCULATOR.m4 [new file with mode: 0755]
adm_local/unix/config_files/check_med2.m4 [deleted file]
adm_local/unix/make_commence.in
build_configure
configure.in.base

index a01780158111ab47626eb3ae69923ad96cbc0f5f..48b723cd1a112a188b9b119130d6948107009e76 100644 (file)
@@ -13,7 +13,7 @@ VPATH=.:@srcdir@:@top_srcdir@/bin:@top_srcdir@/resources:./bin:@top_srcdir@/idl
 
 @COMMENCE@
 
-SUBDIRS = idl src
+SUBDIRS = idl src adm_local
 
 RESOURCES_FILES = CALCULATORCatalog.xml CALCULATOR.png CALCULATOR_en.xml \
                   ExecCALCULATOR.png config
diff --git a/adm_local/Makefile.in b/adm_local/Makefile.in
new file mode 100644 (file)
index 0000000..9b5e810
--- /dev/null
@@ -0,0 +1,41 @@
+# source path
+top_srcdir=@top_srcdir@
+top_builddir=..
+srcdir=@srcdir@
+VPATH=.:$(srcdir)/adm_local
+
+
+all: resources
+
+install:
+       cp -rf @top_srcdir@/adm_local @prefix@
+
+bin:
+
+resources :
+       cp -rf @top_srcdir@/adm_local $(top_builddir)
+
+inc:
+
+lib:
+
+depend:
+
+depend_idl:
+
+install-end:
+
+install-include:
+
+install-bin:
+
+uninstall:
+
+uninstall-idl:
+
+distclean:
+
+clean:
+
+distclean-other:
+
diff --git a/adm_local/unix/config_files/check_CALCULATOR.m4 b/adm_local/unix/config_files/check_CALCULATOR.m4
new file mode 100755 (executable)
index 0000000..49f22df
--- /dev/null
@@ -0,0 +1,52 @@
+#  Check availability of CALCULATOR binary distribution
+#
+#  Author : Marc Tajchman (CEA, 2002)
+#------------------------------------------------------------
+
+AC_DEFUN([CHECK_CALCULATOR],[
+
+AC_CHECKING(for Calculator)
+
+Calculator_ok=no
+
+AC_ARG_WITH(calc,
+           --with-calculator=DIR  root directory path of CALCULATOR build or installation,
+           CALCULATOR_DIR="$withval",CALCULATOR_DIR="")
+
+if test "x$CALCULATOR_DIR" = "x" ; then
+
+# no --with-gui-dir option used
+
+  if test "x$CALCULATOR_ROOT_DIR" != "x" ; then
+
+    # SALOME_ROOT_DIR environment variable defined
+    CALCULATOR_DIR=$CALCULATOR_ROOT_DIR
+
+  else
+
+    # search Salome binaries in PATH variable
+    AC_PATH_PROG(TEMP, libCALCULATOREngine.so)
+    if test "x$TEMP" != "x" ; then
+      CALCULATOR_DIR=`dirname $TEMP`
+    fi
+
+  fi
+
+fi
+
+if test -f ${CALCULATOR_DIR}/lib/salome/libCALCULATOREngine.so  ; then
+  Calculator_ok=yes
+  AC_MSG_RESULT(Using CALCULATOR module distribution in ${CALCULATOR_DIR})
+
+  if test "x$CALCULATOR_ROOT_DIR" == "x" ; then
+    CALCULATOR_ROOT_DIR=${CALCULATOR_DIR}
+  fi
+  AC_SUBST(CALCULATOR_ROOT_DIR)
+else
+  AC_MSG_WARN("Cannot find compiled CALCULATOR module distribution")
+fi
+  
+AC_MSG_RESULT(for CALCULATOR: $Calculator_ok)
+])dnl
diff --git a/adm_local/unix/config_files/check_med2.m4 b/adm_local/unix/config_files/check_med2.m4
deleted file mode 100644 (file)
index 82b1078..0000000
+++ /dev/null
@@ -1,114 +0,0 @@
-dnl  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-dnl  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
-dnl 
-dnl  This library is free software; you can redistribute it and/or 
-dnl  modify it under the terms of the GNU Lesser General Public 
-dnl  License as published by the Free Software Foundation; either 
-dnl  version 2.1 of the License. 
-dnl 
-dnl  This library is distributed in the hope that it will be useful, 
-dnl  but WITHOUT ANY WARRANTY; without even the implied warranty of 
-dnl  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU 
-dnl  Lesser General Public License for more details. 
-dnl 
-dnl  You should have received a copy of the GNU Lesser General Public 
-dnl  License along with this library; if not, write to the Free Software 
-dnl  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA 
-dnl 
-dnl  See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 
-dnl
-dnl
-dnl
-
-AC_DEFUN([CHECK_MED2],[
-AC_REQUIRE([AC_PROG_CC])dnl
-AC_REQUIRE([AC_PROG_CPP])dnl
-AC_REQUIRE([CHECK_HDF5])dnl
-
-AC_CHECKING(for MED2)
-
-AC_ARG_WITH(med2,
-    [  --with-med2=DIR                 root directory path to med2 installation ],
-    [MED2HOME="$withval"
-      AC_MSG_RESULT("select $withval as path to med2")
-    ])
-
-AC_SUBST(MED2_INCLUDES)
-AC_SUBST(MED2_LIBS)
-AC_SUBST(MED2_MT_LIBS)
-
-MED2_INCLUDES=""
-MED2_LIBS=""
-MED2_MT_LIBS=""
-
-med2_ok=no
-
-LOCAL_INCLUDES="$HDF5_INCLUDES"
-LOCAL_LIBS="-lmed $HDF5_LIBS"
-
-if test -z $MED2HOME
-then
-   AC_MSG_WARN(undefined MED2HOME variable which specify med2 installation directory)
-   AC_PATH_PROG(MDUMP, mdump)
-   if test "xMDUMP" != "x" ; then
-      MED2HOME=$MDUMP
-      MED2HOME=`echo ${MED2HOME} | sed -e "s,[[^/]]*$,,;s,/$,,;s,^$,.,"`
-      MED2HOME=`echo ${MED2HOME} | sed -e "s,[[^/]]*$,,;s,/$,,;s,^$,.,"`
-   fi
-fi
-if test ! -z $MED2HOME
-then
-   LOCAL_INCLUDES="$LOCAL_INCLUDES -I$MED2HOME/include"
-   if test "x$MED2HOME" = "x/usr"
-   then
-     LOCAL_LIBS="-lmed  $LOCAL_LIBS"
-   else
-     LOCAL_LIBS="-L$MED2HOME/lib $LOCAL_LIBS"
-   fi
-fi
-
-dnl check med2 header
-
-CPPFLAGS_old="$CPPFLAGS"
-dnl we must test system : linux = -DPCLINUX
-dnl we must test system : Alpha-OSF = -DOSF1
-case $host_os in
-   linux*)
-      CPPFLAGS="$CPPFLAGS -DPCLINUX $LOCAL_INCLUDES"
-      ;;
-   osf*)
-      CPPFLAGS="$CPPFLAGS -DOSF1 $LOCAL_INCLUDES"
-      ;;
-esac
-AC_CHECK_HEADER(med.h,med2_ok=yes ,med2_ok=no)
-CPPFLAGS="$CPPFLAGS_old"
-
-if  test "x$med2_ok" = "xyes"
-then
-
-dnl check med2 library
-
-  LIBS_old="$LIBS"
-  LIBS="$LIBS $LOCAL_LIBS"
-  AC_CHECK_LIB(med,MEDouvrir,med2_ok=yes,med2_ok=no)
-  LIBS="$LIBS_old"
-
-fi
-
-if  test "x$med2_ok" = "xyes"
-then
-case $host_os in
-   linux*)
-        MED2_INCLUDES="-DPCLINUX $LOCAL_INCLUDES"
-      ;;
-   osf*)
-      MED2_INCLUDES="-DOSF1 $LOCAL_INCLUDES"
-      ;;
-esac
-  MED2_LIBS="$LOCAL_LIBS"
-  MED2_MT_LIBS="$LOCAL_LIBS"
-fi
-
-AC_MSG_RESULT(for med2: $med2_ok)
-
-])dnl
index 656eb22c2c1342a5083b0abb98c66c9507dc9ab4..a381c106243939379f6ccd638043eb2ff3bdb9f8 100644 (file)
@@ -236,13 +236,23 @@ $(top_srcdir)/configure.in: $(top_srcdir)/configure.in.base
 
 
 ACLOCAL_SRC = \
-ac_cxx_bool.m4                    check_corba.m4     check_vtk.m4      \
+ac_cxx_bool.m4                    check_corba.m4                       \
 ac_cxx_depend_flag.m4             check_hdf5.m4      enable_pthreads.m4        \
 ac_cxx_mutable.m4                 check_mico.m4      libtool.m4                \
 ac_cxx_namespaces.m4              check_omniorb.m4   pyembed.m4                \
-ac_cxx_partial_specialization.m4  check_opengl.m4    python.m4         \
+ac_cxx_partial_specialization.m4  python.m4                            \
 ac_cxx_typename.m4                check_pthreads.m4  check_cas.m4      \
-ac_cc_warnings.m4                 check_qt.m4        check_swig.m4 
+ac_cc_warnings.m4                 check_swig.m4 
 
-$(top_srcdir)/aclocal.m4: $(ACLOCAL_SRC:%=@KERNEL_ROOT_DIR@/salome_adm/unix/config_files/%)
-       cd $(top_srcdir) ; aclocal --acdir=adm_local/unix/config_files -I @KERNEL_ROOT_DIR@/salome_adm/unix/config_files
+ACLOCAL_GUI = \
+check_vtk.m4                     check_opengl.m4    check_qt.m4        \
+check_GUI.m4                      check_corba_in_GUI.m4
+
+ACLOCAL_MED =                     check_Med.m4       check_Med2.m4
+
+$(top_srcdir)/aclocal.m4: $(ACLOCAL_SRC:%=@KERNEL_ROOT_DIR@/salome_adm/unix/config_files/%) \
+                          $(ACLOCAL_GUI:%=@GUI_ROOT_DIR@/adm_local/unix/config_files/%) \
+                         $(ACLOCAL_MED:%=@MED_ROOT_DIR@/adm_local/unix/config_files/%)
+       cd $(top_srcdir) ; aclocal --acdir=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
index 573a23bb35af1e8270d77d38ce2ac26d6eaea717..fc8583e77c18ede546faf7b2839df99faa382789 100755 (executable)
@@ -20,6 +20,22 @@ if test ! -d "${KERNEL_ROOT_DIR}"; then
     exit
 fi
 
+########################################################################
+# Test if the GUI_ROOT_DIR is set correctly
+
+if test ! -d "${GUI_ROOT_DIR}"; then
+    echo "failed : GUI_ROOT_DIR variable is not correct !"
+    exit
+fi
+
+########################################################################
+# Test if the MED_ROOT_DIR is set correctly
+
+if test ! -d "${MED_ROOT_DIR}"; then
+    echo "failed : MED_ROOT_DIR variable is not correct !"
+    exit
+fi
+
 ########################################################################
 # find_in - utility function
 #
@@ -49,6 +65,7 @@ find_in()
 
   case $1 in
     */CVS) return ;;
+    */adm_local/*) return ;;
     *) ;;
   esac
 
@@ -128,9 +145,9 @@ echo "./salome_adm/unix/make_module \\" >> configure.in_tmp1
 touch configure.in_tmp2
 find_in . configure.in_tmp2
 
-sed -e '/^.\/salome_adm/d'    \
+sed -e '/^...salome_adm/d'    \
     -e '/configure.in/d'      \
-    -e '/^.\/adm_local/d'   \
+    -e '/^...adm_local/d'   \
     -e 's/.in / /'            \
     configure.in_tmp2  >>  configure.in_tmp1
 
@@ -194,7 +211,9 @@ else
        echo -n "Creating 'configure' script ...  "
 fi
 
-aclocal --acdir=adm_local/unix/config_files -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files
+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
 if autoconf
 then
        echo "done"
index 28b17b27c0d260ffa4498a8c9ea33b3f60e60bd0..eba7c7f46974187c6245dd6c18daaecec56114c8 100644 (file)
@@ -135,6 +135,15 @@ echo
 
 CHECK_MED2
 
+
+echo
+echo ---------------------------------------------
+echo testing MED
+echo ---------------------------------------------
+echo
+
+CHECK_MED
+
 dnl For the sake of $MACHINE needed for MED Wrapper
 AC_DEPEND_FLAG
 
@@ -153,6 +162,26 @@ AC_SUBST_FILE(CORBA)
 corba=make_$ORB
 CORBA=adm_local/unix/$corba
 
+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 CALCULATOR module necessary full GUI !"
+  exit
+fi
+
 echo
 echo ---------------------------------------------
 echo Testing Kernel