+dnl Copyright (C) 2004-2008 CEA/DEN, EDF R&D
+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.salome-platform.org/ or email : webmaster.salome@opencascade.com
+dnl
AC_DEFUN([CHECK_GHS3D],[
-AC_REQUIRE([AC_PROG_CXX])dnl
-AC_REQUIRE([AC_PROG_CXXCPP])dnl
+GHS3D_ok=no
-AC_CHECKING(for GHS3D executable)
+AC_EXEEXT
+AC_CHECK_PROG(GHS3D, ghs3d$EXEEXT,found)
-AC_LANG_SAVE
+if test "x$GHS3D" == x ; then
+ AC_MSG_WARN(ghs3d program not found in PATH variable)
+else
+ GHS3D_ok=yes
+fi
-AC_ARG_WITH(ghs3d,
- [ --with-ghs3d=DIR root directory path of GHS33D installation],
- GHS3D_HOME=$withval,GHS3D_HOME="")
-
-GHS3D_ok=yes
-GHS3D_HOME="/dn05/salome/GHS3D/"
-GHS3D="/misc/dn05/salome/GHS3D/ghs3d3.1-1/bin/Linux/ghs3dV3.1-1"
-
-#if test "x$GHS3D_HOME" == "x" ; then
-#
-## no --with-ghs3d option used
-# if test "x$GHS3DHOME" != "x" ; then
-#
-# # GHS3DHOME environment variable defined
-# GHS3D_HOME=$GHS3DHOME
-#
-# fi
-#fi
-
-
- if test "x$GHS3D_ok" == xno ; then
- AC_MSG_RESULT(no)
- AC_MSG_WARN(GHS3D libraries not found or not properly installed)
- else
- AC_MSG_RESULT(yes)
- fi
-#fi
+AC_MSG_RESULT(for GHS3D: $GHS3D_ok)
])dnl