1 # Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE
3 # Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 # CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 # This library is free software; you can redistribute it and/or
7 # modify it under the terms of the GNU Lesser General Public
8 # License as published by the Free Software Foundation; either
9 # version 2.1 of the License.
11 # This library is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 # Lesser General Public License for more details.
16 # You should have received a copy of the GNU Lesser General Public
17 # License along with this library; if not, write to the Free Software
18 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 # Author : Marc Tajchman (CEA)
24 # Modified by : Patrick GOLDBRONN (CEA)
25 # Modified by : Marc Tajchman (CEA)
26 # Modified by : Alexander BORODIN (OCN) - autotools usage
27 # Created from configure.in.base
29 AC_INIT([Salome2 Project SMESH module], [5.1.2], [webmaster.salome@opencascade.com], [SalomeSMESH])
30 AC_CONFIG_AUX_DIR(adm_local/unix/config_files)
33 AM_INIT_AUTOMAKE([-Wno-portability])
35 XVERSION=`echo $VERSION | awk -F. '{printf("0x%02x%02x%02x",$1,$2,$3)}'`
38 # set up MODULE_NAME variable for dynamic construction of directories (resources, etc.)
43 echo ---------------------------------------------
44 echo Initialize source and build root directories
45 echo ---------------------------------------------
49 dnl Initialize source and build root directories
53 ROOT_SRCDIR=`echo $0 | sed -e "s,[[^/]]*$,,;s,/$,,;s,^$,.,"`
59 AC_SUBST(ROOT_BUILDDIR)
62 echo Source root directory : $ROOT_SRCDIR
63 echo Build root directory : $ROOT_BUILDDIR
67 if test -z "$AR"; then
68 AC_CHECK_PROGS(AR,ar xar,:,$PATH)
72 dnl Export the AR macro so that it will be placed in the libtool file
77 echo ---------------------------------------------
79 echo ---------------------------------------------
86 dnl libtool macro check for CC, LD, NM, LN_S, RANLIB, STRIP + pour les librairies dynamiques !
89 echo ---------------------------------------------
90 echo Coniguring production
91 echo ---------------------------------------------
96 echo ---------------------------------------------
98 echo ---------------------------------------------
100 dnl first, we set static to no!
101 dnl if we want it, use --enable-static
107 dnl Fix up the INSTALL macro if it s a relative path. We want the
108 dnl full-path to the binary instead.
111 INSTALL='\${ROOT_BUILDDIR}'/adm_local/unix/config_files/install-sh
116 echo ---------------------------------------------
118 echo ---------------------------------------------
122 dnl inutil car libtool
126 AC_CXX_TEMPLATE_OPTIONS
128 # AC_CC_WARNINGS([ansi])
132 echo ---------------------------------------------
134 echo ---------------------------------------------
139 AC_F77_LIBRARY_LDFLAGS
141 AC_FC_LIBRARY_LDFLAGS
142 if test "X$FC" != "X" ; then
147 dnl AM_CONDITIONAL( USE_GFORTRAN, [test "$F77" = "gfortran"])
152 AC_CHECK_LIB(dl,dlopen)
154 dnl add library libm :
158 dnl Well we use sstream which is not in gcc pre-2.95.3
159 dnl We must test if it exists. If not, add it in include !
165 dnl ---------------------------------------------
167 dnl ---------------------------------------------
173 echo ---------------------------------------------
174 echo testing LEX \& YACC
175 echo ---------------------------------------------
184 echo ---------------------------------------------
186 echo ---------------------------------------------
192 dnl echo ---------------------------------------------
193 dnl echo testing java
194 dnl echo ---------------------------------------------
200 echo ---------------------------------------------
202 echo ---------------------------------------------
209 echo ---------------------------------------------
211 echo ---------------------------------------------
216 if test "x${GUI_DISABLE_CORBA}" != "xyes" ; then
218 echo ---------------------------------------------
220 echo ---------------------------------------------
226 dnl echo ---------------------------------------------
227 dnl echo testing mico
228 dnl echo ---------------------------------------------
234 echo ---------------------------------------------
235 echo default ORB : omniORB
236 echo ---------------------------------------------
242 echo ---------------------------------------------
244 echo ---------------------------------------------
251 CORBA=adm_local/unix/$corba
256 echo ---------------------------------------------
258 echo ---------------------------------------------
264 if test "${SalomeGUI_need}" != "no" -a "${FullGUI_ok}" = "yes" ; then
268 AM_CONDITIONAL(SMESH_ENABLE_GUI, [test "${gui_ok}" = "yes"])
270 if test "${SalomeGUI_need}" == "yes"; then
271 if test "${FullGUI_ok}" != "yes"; then
272 AC_MSG_WARN(For configure SMESH module necessary full GUI!)
274 elif test "${SalomeGUI_need}" == "auto"; then
275 if test "${FullGUI_ok}" != "yes"; then
276 AC_MSG_WARN(Full GUI not found. Build will be done without GUI!)
278 elif test "${SalomeGUI_need}" == "no"; then
279 echo Build without GUI option has been chosen
282 if test "${gui_ok}" = "yes"; then
284 echo ---------------------------------------------
286 echo ---------------------------------------------
292 echo ---------------------------------------------
294 echo ---------------------------------------------
300 echo ---------------------------------------------
302 echo ---------------------------------------------
309 echo ---------------------------------------------
311 echo ---------------------------------------------
317 echo ---------------------------------------------
319 echo ---------------------------------------------
325 echo ---------------------------------------------
326 echo Testing OpenCascade
327 echo ---------------------------------------------
332 if test "${gui_ok}" = "yes"; then
335 echo ---------------------------------------------
337 echo ---------------------------------------------
345 echo ---------------------------------------------
346 echo Testing html generators
347 echo ---------------------------------------------
350 CHECK_HTML_GENERATORS
353 echo ---------------------------------------------
355 echo ---------------------------------------------
361 echo ---------------------------------------------
363 echo ---------------------------------------------
369 echo ---------------------------------------------
371 echo ---------------------------------------------
379 echo ---------------------------------------------
381 echo ---------------------------------------------
386 if test "${gui_ok}" = "yes"; then
387 variables="cc_ok fortran_ok boost_ok lex_yacc_ok python_ok swig_ok threads_ok OpenGL_ok qt_ok vtk_ok hdf5_ok omniORB_ok occ_ok doxygen_ok graphviz_ok qwt_ok Kernel_ok Geom_ok Med_ok gui_ok"
388 elif test "${SalomeGUI_need}" != "no"; then
389 variables="cc_ok fortran_ok boost_ok lex_yacc_ok python_ok swig_ok threads_ok hdf5_ok omniORB_ok occ_ok doxygen_ok graphviz_ok Kernel_ok Geom_ok Med_ok gui_ok"
391 variables="cc_ok fortran_ok boost_ok lex_yacc_ok python_ok swig_ok threads_ok hdf5_ok omniORB_ok occ_ok doxygen_ok graphviz_ok Kernel_ok Geom_ok Med_ok"
394 for var in $variables
396 printf " %10s : " `echo \$var | sed -e "s,_ok,,"`
401 echo "Default ORB : $DEFAULT_ORB"
404 dnl We don t need to say when we re entering directories if we re using
405 dnl GNU make becuase make does it for us.
406 if test "X$GMAKE" = "Xyes"; then
407 AC_SUBST(SETX) SETX=":"
409 AC_SUBST(SETX) SETX="set -x"
412 dnl AM_CONDITIONAL(GUI_ENABLE_CORBA, [test "$GUI_DISABLE_CORBA" = no])
413 dnl AM_CONDITIONAL(ENABLE_PYCONSOLE, [test "$DISABLE_PYCONSOLE" = no])
414 dnl AM_CONDITIONAL(ENABLE_GLVIEWER, [test "$DISABLE_GLVIEWER" = no])
415 dnl AM_CONDITIONAL(ENABLE_PLOT2DVIEWER, [test "$DISABLE_PLOT2DVIEWER" = no])
416 dnl AM_CONDITIONAL(ENABLE_SUPERVGRAPHVIEWER, [test "$DISABLE_SUPERVGRAPHVIEWER" = no])
417 dnl AM_CONDITIONAL(ENABLE_OCCVIEWER, [test "$DISABLE_OCCVIEWER" = no])
418 dnl AM_CONDITIONAL(ENABLE_VTKVIEWER, [test "$DISABLE_VTKVIEWER" = no])
419 dnl AM_CONDITIONAL(ENABLE_SALOMEOBJECT, [test "$DISABLE_SALOMEOBJECT" = no])
422 echo ---------------------------------------------
423 echo generating Makefiles and configure files
424 echo ---------------------------------------------
427 #AC_OUTPUT_COMMANDS([ \
428 # chmod +x ./bin/*; \
429 # chmod +x ./bin/salome/*; \
432 # This list is initiated using autoscan and must be updated manually
433 # when adding a new file <filename>.in to manage. When you execute
434 # autoscan, the Makefile list is generated in the output file configure.scan.
435 # This could be helpfull to update de configuration.
438 adm_local/cmake_files/Makefile \
439 adm_local/unix/Makefile \
440 adm_local/unix/config_files/Makefile \
445 doc/salome/Makefile \
446 doc/salome/gui/Makefile \
447 doc/salome/gui/SMESH/Makefile \
448 doc/salome/gui/SMESH/doxyfile \
449 doc/salome/gui/SMESH/doxyfile_py \
450 doc/salome/tui/Makefile \
451 doc/salome/tui/doxyfile \
453 src/Controls/Makefile \
454 src/Driver/Makefile \
455 src/DriverDAT/Makefile \
456 src/DriverMED/Makefile \
457 src/DriverSTL/Makefile \
458 src/DriverUNV/Makefile \
459 src/MEFISTO2/Makefile \
460 src/OBJECT/Makefile \
463 src/SMESHClient/Makefile \
464 src/SMESHDS/Makefile \
465 src/SMESHFiltersSelection/Makefile \
466 src/SMESHGUI/Makefile \
467 src/SMESH_I/Makefile \
468 src/SMESH_SWIG/Makefile \
469 src/SMESH_SWIG_WITHIHM/Makefile \
470 src/StdMeshers/Makefile \
471 src/StdMeshersGUI/Makefile \
472 src/StdMeshers_I/Makefile \
474 resources/SMESHCatalog.xml \