Salome HOME
Search runSalome.py instead of runSalome for KERNEL detection
[modules/yacs.git] / configure.in.base
1 # Copyright (C) 2006-2013  CEA/DEN, EDF R&D
2 #
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License.
7 #
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 # Lesser General Public License for more details.
12 #
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 #
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 #
19
20 # --
21 # Author : Anthony Geay (CEA)
22 # --
23 # -----------------------------------------------------------------------------
24 #
25 AC_INIT([Salome2 Project], [7.2.0], [paul.rascle@edf.fr], [SalomeYacs])
26 AC_CONFIG_AUX_DIR(adm/unix/config_files)
27 AM_INIT_AUTOMAKE([tar-pax])
28 AC_CONFIG_HEADER(yacs_config.h)
29
30 # set up MODULE_NAME variable for dynamic construction of directories (resources, etc.)
31 MODULE_NAME=yacs
32 AC_SUBST(MODULE_NAME)
33
34 SHORT_VERSION=`echo $VERSION | awk -F. '{printf("%d.%d",$1,$2)}'`
35 AC_SUBST(SHORT_VERSION)
36 XVERSION=`echo $VERSION | awk -F. '{printf("0x%02x%02x%02x",$1,$2,$3)}'`
37 AC_SUBST(XVERSION)
38 VERSION_DEV=0
39 AC_SUBST(VERSION_DEV)
40
41 RELEASE=$VERSION
42 AC_SUBST(RELEASE)
43
44 # This function return on stdout the absolute path of the filename in
45 # argument. Exemple:
46 # $ filename="../KERNEL_SRC/configure
47 # $ absfilename=`absolute_path $filename`
48 function absolute_path {
49     filename=$1
50     here=`pwd`
51     apath=`dirname $filename`
52     cd $apath
53     apath=`pwd`
54     cd $here
55     echo $apath
56 }
57
58 # Build directory, where the configure script is executed.
59 ROOT_BUILDDIR=`pwd`
60 # Source directory, where the configure script is located.
61 ROOT_SRCDIR=`absolute_path $0`
62
63 AC_SUBST(ROOT_SRCDIR)
64 AC_SUBST(ROOT_BUILDDIR)
65
66 echo
67 echo Source root directory : $ROOT_SRCDIR
68 echo Build  root directory : $ROOT_BUILDDIR
69
70 # -----------------------------------------------------------------------------
71
72 AC_ENABLE_DEBUG(yes)
73 AC_DISABLE_PRODUCTION
74
75 #Linker options
76 AC_CANONICAL_BUILD
77 AC_LINKER_OPTIONS
78
79 #Mandatory products
80 AC_PROG_CXX
81 AM_PROG_LIBTOOL
82
83 AC_CHECK_LIB(dl,dlopen)
84
85 ENABLE_PTHREADS
86
87 AM_PATH_PYTHON(2.3)
88 AC_PYTHON_DEVEL
89 python_ok=yes
90 CHECK_THREAD
91 AC_CHECK_OMNIORB
92 AC_CHECK_EXPAT
93 AC_CHECK_LIBXML
94 CHECK_BOOST
95
96 #Optional products
97 AC_PROG_SWIG(1.3.17)
98 SWIG_ENABLE_CXX
99 SWIG_PYTHON
100 CHECK_CPPUNIT
101 AC_CHECK_KERNEL
102 #CHECK_MSG2QM
103 CHECK_HTML_GENERATORS
104 CHECK_SPHINX
105
106 CHECK_GUI(SALOME_Session_Server,SALOME_Session_Server)
107
108 I2_CHECK_QT4
109 I2_CHECK_QSCINTILLA
110
111 AM_CONDITIONAL([PYTHON_API], [test "x$swig_ok" == "xyes"])
112 AM_CONDITIONAL([SALOME_KERNEL], [test "x$KERNEL_ROOT_DIR" != "x"])
113 AM_CONDITIONAL([DSC_PORTS], [test -f $KERNEL_ROOT_DIR/idl/salome/DSC_Engines.idl])
114
115 AM_CONDITIONAL(WINDOWS, [ test ])
116
117 echo
118 echo
119 echo
120 echo "------------------------------------------------------------------------"
121 echo "$PACKAGE $VERSION"
122 echo "------------------------------------------------------------------------"
123 echo
124 echo "Configuration Options Summary:"
125 echo
126 echo "Mandatory products:"
127 echo "  Threads ................ : $thread_ok"
128 echo "  Boost .................. : $boost_ok"
129 echo "  OmniOrb (CORBA) ........ : $omniORB_ok"
130 echo "  OmniOrbpy (CORBA) ...... : $omniORBpy_ok"
131 echo "  Python ................. : $python_ok"
132 echo "  Expat .................. : $expat_ok"
133 echo "  libxml ................. : $libxml_ok"
134 echo
135 echo "Optional products:"
136 echo "  swig (python wrapper)... : $swig_ok"
137 echo "  SALOME KERNEL .......... : $Kernel_ok"
138 echo "  DSC extension .......... : $dsc_ok"
139 echo "  Cppunit (make check).... : $cppunit_ok"
140 echo "  Qt4 (graphic interface)  : $qt_ok"
141 echo "  QScintilla ............. : $qscintilla_ok"
142 #echo "  msq2qm ................. : $msg2qm_ok"
143 echo "  SALOME GUI ............. : $SalomeGUI_ok"
144 echo "  Sphinx (user doc) ...... : $sphinx_ok"
145 echo
146 echo "------------------------------------------------------------------------"
147 echo
148
149 if test "x$thread_ok" = "xno"; then
150   AC_MSG_ERROR([Thread is required],1)
151 fi
152 if test "x$omniORB_ok" = "xno"; then
153   AC_MSG_ERROR([OmniOrb is required],1)
154 fi
155 if test "x$python_ok" = "xno"; then
156   AC_MSG_ERROR([Python is required],1)
157 fi
158 if test "x$omniORBpy_ok" = "xno"; then
159   AC_MSG_ERROR([OmniOrbpy is required],1)
160 fi
161 if test "x$expat_ok" = "xno"; then
162   AC_MSG_ERROR([Expat is required],1)
163 fi
164 if test "x$libxml_ok" = "xno"; then
165   AC_MSG_ERROR([Libxml is required],1)
166 fi
167
168
169 AC_OUTPUT([ \
170   Makefile \
171   YACS_version.h \
172   Demo/Makefile \
173   doc/Makefile \
174   idl/Makefile \
175   src/Makefile \
176   src/bases/Makefile \
177   src/bases/Test/Makefile \
178   src/engine/Makefile \
179   src/engine/Plugin/Makefile \
180   src/engine/Test/Makefile \
181   src/engine_swig/Makefile \
182   src/hmi/Makefile \
183   src/pyqt/Makefile \
184   src/runtime/Makefile \
185   src/runtime/Test/Makefile \
186   src/runtime_swig/Makefile \
187   src/genericgui/Makefile \
188   src/salomewrap/Makefile \
189   src/salomegui/Makefile \
190   src/salomegui_swig/Makefile \
191   src/salomeloader/Makefile \
192   src/salomeloader/testSalomeLoader.py \
193   src/wrappergen/Makefile \
194   src/wrappergen/src/Makefile \
195   src/yacsloader/Makefile \
196   src/yacsloader/Test/Makefile \
197   src/yacsloader/Test/YacsLoaderTest.sh \
198   src/yacsloader/Test/YacsLoaderInSessionTest.sh \
199   src/yacsloader/Test/display.sh \
200   src/yacsloader/Test/config_appli.xml \
201   src/yacsloader_swig/Makefile \
202   src/yacsloader_swig/Test/Makefile \
203   src/yacsloader_swig/Test/YacsLoaderTest.sh \
204   src/yacsloader_swig/Test/YacsLoaderInSessionTest.sh \
205   src/yacsloader_swig/Test/config_appli.xml \
206   src/yacsorb/Makefile \
207   src/salomegui/resources/YACSCatalog.xml \
208   src/salomegui/resources/SalomeApp.xml \
209   doc/Doxyfile \
210   doc/conf.py \
211   doc/sources/header.html \
212 ])
213