1 # Check availability of COMPONENT module binary distribution
3 # Author : Marc Tajchman (CEA, 2002)
4 #------------------------------------------------------------
6 AC_DEFUN([CHECK_COMPONENT],[
8 AC_CHECKING(for Component)
13 --with-component=DIR root directory path of COMPONENT module installation,
14 COMPONENT_DIR="$withval",COMPONENT_DIR="")
16 if test "x$COMPONENT_DIR" = "x" ; then
18 # no --with-component option used
20 if test "x$COMPONENT_ROOT_DIR" != "x" ; then
22 # COMPONENT_ROOT_DIR environment variable defined
23 COMPONENT_DIR=$COMPONENT_ROOT_DIR
27 # search component binaries in PATH variable
28 AC_PATH_PROG(TEMP, libCalculatorEngine.so)
29 if test "x$TEMP" != "x" ; then
30 COMPONENT_DIR=`dirname $TEMP`
37 if test -f ${COMPONENT_DIR}/lib/salome/libCalculatorEngine.so ; then
39 AC_MSG_RESULT(Using COMPONENT module distribution in ${COMPONENT_DIR})
41 if test "x$COMPONENT_ROOT_DIR" == "x" ; then
42 COMPONENT_ROOT_DIR=${COMPONENT_DIR}
44 AC_SUBST(COMPONENT_ROOT_DIR)
46 AC_MSG_WARN("Cannot find compiled COMPONENT module distribution")
49 AC_MSG_RESULT(for COMPONENT: $Component_ok)