1 dnl Copyright (C) 2004-2008 CEA/DEN, EDF R&D
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.
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
19 # Check availability of GHS3DPLUGIN binary distribution
21 # Author : Marc Tajchman (CEA, 2002)
22 #------------------------------------------------------------
24 AC_DEFUN([CHECK_GHS3DPLUGIN],[
26 GHS3DPLUGIN_LDFLAGS=""
27 GHS3DPLUGIN_CXXFLAGS=""
29 AC_CHECKING(for GHS3dPlugin)
34 --with-ghs3dPlugin=DIR root directory path of GHS3DPLUGIN build or installation,
35 GHS3DPLUGIN_DIR="$withval",GHS3DPLUGIN_DIR="")
37 if test "x$GHS3DPLUGIN_DIR" = "x" ; then
39 # no --with-gui-dir option used
41 if test "x$GHS3DPLUGIN_ROOT_DIR" != "x" ; then
43 # SALOME_ROOT_DIR environment variable defined
44 GHS3DPLUGIN_DIR=$GHS3DPLUGIN_ROOT_DIR
48 # search Salome binaries in PATH variable
49 AC_PATH_PROG(TEMP, libGHS3DEngine.so)
50 if test "x$TEMP" != "x" ; then
51 GHS3DPLUGIN_DIR=`dirname $TEMP`
58 if test -f ${GHS3DPLUGIN_DIR}/lib/salome/libGHS3DEngine.so ; then
60 AC_MSG_RESULT(Using GHS3DPLUGIN module distribution in ${GHS3DPLUGIN_DIR})
62 if test "x$GHS3DPLUGIN_ROOT_DIR" == "x" ; then
63 GHS3DPLUGIN_ROOT_DIR=${GHS3DPLUGIN_DIR}
65 GHS3DPLUGIN_CXXFLAGS+=-I${GHS3DPLUGIN_ROOT_DIR}/include/salome
66 GHS3DPLUGIN_LDFLAGS+=-L${GHS3DPLUGIN_ROOT_DIR}/lib${LIB_LOCATION_SUFFIX}/salome
67 AC_SUBST(GHS3DPLUGIN_ROOT_DIR)
68 AC_SUBST(GHS3DPLUGIN_LDFLAGS)
69 AC_SUBST(GHS3DPLUGIN_CXXFLAGS)
71 AC_MSG_WARN("Cannot find compiled GHS3DPLUGIN module distribution")
74 AC_MSG_RESULT(for GHS3DPLUGIN: $GHS3dPlugin_ok)