Finalisation de la partie swig.
dnl lsf_ok is set to yes by CHECK_LSF
echo lsf = $lsf_ok
+echo testing Local batch system
+echo --------------------------
+localbatch_ok=no
+CHECK_LOCAL
+dnl localbatch_ok is set to yes by CHECK_LOCAL
+
WITH_BATCH=no
-test x$openpbs_ok = xyes || test x$lsf_ok = xyes && WITH_BATCH=yes
+test x$openpbs_ok = xyes || test x$lsf_ok = xyes || test x$localbatch_ok = xyes && WITH_BATCH=yes
AC_SUBST(WITH_BATCH)
-
+AM_CONDITIONAL(WITH_BATCH, [test x"$WITH_BATCH" = xyes])
echo
echo ---------------------------------------------
#define @MACHINE@
#endif
+
+/* A path to a rcp-like command */
+#define RCP "@RCP@"
+
+/* A path to a rm-like command */
+#define RM "@RM@"
+
+/* A path to a cp-like command */
+#define CP "@CP@"
+
+/* A path to a rsh-like command */
+#define RSH "@RSH@"
+
+/* A path to a scp-like command */
+#define SCP "@SCP@"
+
+/* A path to a sh-like command */
+#define SH "@SH@"
+
+/* A path to a ssh-like command */
+#define SSH "@SSH@"
+
#endif
--- /dev/null
+# Check for Local
+AC_DEFUN([CHECK_LOCAL],
+[
+ dnl AC_ARG_VAR([LOCAL], [])
+ AC_ARG_WITH([local],
+ AC_HELP_STRING([--with-local],
+ [tell configure script to use local submission. Default is --with-local.]),
+ [],
+ [withval=yes])
+
+ AC_MSG_CHECKING([for Local])
+
+ if test "x$withval" = "xyes"
+ then
+ WITH_LOCAL=yes
+
+ AC_MSG_RESULT([$withval])
+
+ AC_ARG_VAR([RM], [A path to a rm-like command])
+ AC_PATH_PROG([RM], [rm], [/bin/false])
+ AC_DEFINE_UNQUOTED(RM, "$RM", [A path to a rm-like command])
+
+ AC_ARG_VAR([SH], [A path to a sh-like command])
+ AC_PATH_PROG([SH], [sh], [/bin/false])
+ AC_DEFINE_UNQUOTED(SH, "$SH", [A path to a sh-like command])
+ AC_ARG_VAR([CP], [A path to a cp-like command])
+ AC_PATH_PROG([CP], [cp], [/bin/false])
+ AC_DEFINE_UNQUOTED(CP, "$CP", [A path to a cp-like command])
+
+ AC_ARG_VAR([RSH], [A path to a rsh-like command])
+ AC_PATH_PROG([RSH], [rsh], [/bin/false])
+ AC_DEFINE_UNQUOTED(RSH, "$RSH", [A path to a rsh-like command])
+ AC_ARG_VAR([RCP], [A path to a rcp-like command])
+ AC_PATH_PROG([RCP], [rcp], [/bin/false])
+ AC_DEFINE_UNQUOTED(RCP, "$RCP", [A path to a rcp-like command])
+
+ AC_ARG_VAR([SSH], [A path to a ssh-like command])
+ AC_PATH_PROG([SSH], [ssh], [/bin/false])
+ AC_DEFINE_UNQUOTED(SSH, "$SSH", [A path to a ssh-like command])
+ AC_ARG_VAR([SCP], [A path to a scp-like command])
+ AC_PATH_PROG([SCP], [scp], [/bin/false])
+ AC_DEFINE_UNQUOTED(SCP, "$SCP", [A path to a scp-like command])
+
+
+ else
+ WITH_LOCAL=no
+
+ AC_MSG_RESULT([no])
+
+ fi
+
+ AM_CONDITIONAL(WITH_LOCAL, test $WITH_LOCAL = yes)
+
+ localbatch_ok=$WITH_LOCAL
+ AC_SUBST(WITH_LOCAL)
+ AC_SUBST(RM)
+ AC_SUBST(SH)
+ AC_SUBST(CP)
+ AC_SUBST(RSH)
+ AC_SUBST(RCP)
+ AC_SUBST(SSH)
+ AC_SUBST(SCP)
+
+ dnl _CS_gbo Pour forcer l'utilisation du config.h, inclu
+ dnl par les fichiers Batch_BatchManager_Local_*.cxx
+ dnl OWN_CONFIG_H=yes
+ dnl AC_SUBST(OWN_CONFIG_H)
+])
+
fi
- dnl AM_CONDITIONAL(WITH_LSF, test $WITH_LSF = 1)
+ AM_CONDITIONAL(WITH_LSF, test $WITH_LSF = yes)
lsf_ok=$WITH_LSF
if test $lsf_ok = no ; then
AC_SUBST(MPI_INCLUDES)
AC_SUBST(MPI_LIBS)
AC_SUBST(mpi_ok)
+AM_CONDITIONAL(MPI_IS_OK, [test x"$mpi_ok" = xyes])
])dnl
fi
AC_SUBST(WITHOPENPBS)
+ AM_CONDITIONAL(WITH_OPENPBS, test $WITHOPENPBS = yes)
+
])
--- /dev/null
+# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+#
+#
+#
+# File : Makefile.am
+# Author : Guillaume Boulant (CSSI)
+# Module : KERNEL
+# $Header$
+
+
+include $(top_srcdir)/salome_adm/unix/make_common_starter.am
+
+#
+# ===============================================================
+# Swig targets
+# ===============================================================
+# (cf. http://www.geocities.com/foetsch/python/swig_linux.htm)
+#
+# Step 1: build the wrapping source files with swig
+#
+# libBatch_Swig.i -- swig --> swig_wrap.cpp
+# libBatch_Swig.py
+#
+# Step 2: build the dynamic library from cpp built source files and
+# dependant libraries.
+#
+# swig_wrap.cpp -- gcc --> swig_wrap.o |-- link --> _libBatch_Swig.la
+# + |
+# dependant libs |
+#
+# The file libBatch_Swig.py will be installed in
+# <prefix>/lib/python<version>/site-package/salome.
+# The library will be installed in the common place.
+#
+
+BUILT_SOURCES = swig_wrap.cpp
+
+SWIG_FLAGS = @SWIG_FLAGS@ -I$(srcdir) -I$(srcdir)/../Batch
+SWIG_SOURCES = libBatch_Swig.i libBatch_Swig_exception.i libBatch_Swig_typemap.i
+
+pkgpython_PYTHON = libBatch_Swig.py
+pkgpyexec_LTLIBRARIES = _libBatch_Swig.la
+_libBatch_Swig_la_SOURCES = $(BUILT_SOURCES) $(SWIG_SOURCES)
+_libBatch_Swig_la_CPPFLAGS = @PYTHON_INCLUDES@ -I$(srcdir) -I$(srcdir)/../Batch
+_libBatch_Swig_la_LDFLAGS = -module
+_libBatch_Swig_la_LIBADD = ../Batch/libSalomeBatch.la @PYTHON_LIBS@
+
+if WITH_OPENPBS
+_libBatch_Swig_la_CPPFLAGS += @OPENPBS_INCLUDES@
+_libBatch_Swig_la_LIBADD += @OPENPBS_LIBDIR@ @OPENPBS_LIBS@
+endif
+
+swig_wrap.cpp : $(SWIG_SOURCES)
+ $(SWIG) $(SWIG_FLAGS) -o $@ $<
+
+CLEANFILES = swig_wrap.cpp
+
+
+#
+# ===============================================================
+# Files to be installed
+# ===============================================================
+#
+
+# Scripts to be installed.
+salomescript_SCRIPTS = Batch_test.py
+
+# You don't need to specify libBatch_Swig.py. It is automatically
+# installed by means of the swig target pkgpython_PYTHON.
+++ /dev/null
-# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-#
-# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
-#
-#
-#
-# File : Makefile.in
-# Author : Paul RASCLE, EDF
-# Module : SALOME
-# $Header$
-
-top_srcdir=@top_srcdir@
-top_builddir=../..
-srcdir=@srcdir@
-VPATH=.:@srcdir@:@top_srcdir@/idl
-
-
-@COMMENCE@
-
-# Libraries targets
-
-LIB = libBatch_Swigcmodule.la
-LIB_SRC =
-
-SWIG_DEF = libBatch_Swig.i
-EXPORT_PYSCRIPTS = libBatch_Swig.py Batch_test.py
-
-CPPFLAGS += $(PYTHON_INCLUDES) $(OPENPBS_INCLUDES)
-
-LDFLAGS += $(OPENPBS_LIBDIR)
-
-LIBS += $(PYTHON_LIBS) $(OPENPBS_LIBS) -lSalomeBatch
-
-@CONCLUDE@
ModuleGenerator \
Communication
+#
+# The following packages are built under conditions.
+# A condition is defined using the macro AM_CONDITIONAL (see the
+# check_cppunit for example with CPPUNIT_IS_OK.
+#
if CPPUNIT_IS_OK
SUBDIRS+= \
LifeCycleCORBA/Test \
UnitTests
endif
+
+
+if MPI_IS_OK
+ SUBDIRS+= MPIContainer TestMPIContainer
+endif
+
+if WITH_BATCH
+ SUBDIRS += Batch Batch_SWIG
+endif
+
+