1 dnl Copyright (C) 2007-2023 CEA/DEN, EDF R&D, OPEN CASCADE
3 dnl This library is free software; you can redistribute it and/or
4 dnl modify it under the terms of the GNU Lesser General Public
5 dnl License as published by the Free Software Foundation; either
6 dnl version 2.1 of the License, or (at your option) any later version.
8 dnl This library is distributed in the hope that it will be useful,
9 dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
10 dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 dnl Lesser General Public License for more details.
13 dnl You should have received a copy of the GNU Lesser General Public
14 dnl License along with this library; if not, write to the Free Software
15 dnl Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 dnl See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 AC_DEFUN([CHECK_BFT],[
22 AC_CHECKING(for BFT Library)
31 AC_CHECKING(for BFT location)
33 [ --with-bft=DIR root directory path to BFT library installation ],
35 AC_MSG_RESULT("select $withval as path to BFT library")])
37 AC_MSG_RESULT(\$BFTDIR = ${BFTDIR})
39 CPPFLAGS_old="${CPPFLAGS}"
42 if test "x${BFTDIR}" != "x" ; then
43 BFT_INCLUDES="-I${BFTDIR}/include"
44 BFT_LIBS="-L${BFTDIR}/lib -lbft"
52 AC_CHECKING(for BFT headers)
53 CPPFLAGS="${CPPFLAGS_old} ${BFT_INCLUDES} ${MPI_CPPFLAGS} ${MED_CPPFLAGS}"
55 bft_include_dir_ok=yes
56 if test "x${BFTDIR}" != "x" ; then
57 AC_CHECK_FILE(${BFTDIR}/include/bft_mem.h,
58 bft_include_dir_ok=yes,
59 bft_include_dir_ok=no)
62 if test "x${bft_include_dir_ok}" = "xyes" ; then
63 AC_TRY_COMPILE([ #include "bft_mem.h"],
69 if test "x${bft_headers_ok}" = "xno" ; then
70 BFT_INCLUDES="BFT_INCLUDES_NOT_DEFINED"
72 AC_MSG_RESULT(\$BFT_INCLUDES = ${BFT_INCLUDES})
74 AC_MSG_RESULT(for bft headers: $bft_headers_ok)
76 if test "x${bft_headers_ok}" = "xyes" ; then
78 AC_CHECKING(for BFT binaries)
80 if test "x${BFTDIR}" != "x" ; then
81 AC_CHECK_FILE(${BFTDIR}/lib/libbft.so,
88 CPPFLAGS="${CPPFLAGS_old}"
91 if test "x${bft_headers_ok}" = "xyes" ; then
92 if test "x${bft_lib_dir_ok}" = "xyes" ; then
97 AC_MSG_RESULT(for bft: $bft_ok)
99 AC_SUBST(BFT_INCLUDES)
100 AC_SUBST(BFT_LIBSUFFIX)