1 AC_INIT(src/evaluate/rr.c)
2 AM_INIT_AUTOMAKE(gpivtools, 0.6.0)
3 AM_CONFIG_HEADER(config.h)
14 dnl hints from autoscan START
20 dnl hints from autoscan END
23 AC_CHECK_PROG(GNUPLOT, gnuplot, true, false)
24 AM_CONDITIONAL(HAVE_GNUPLOT, $GNUPLOT, ,
25 AC_MSG_ERROR("gnuplot not installed");)
26 dnl if test x$GNUPLOT = xfalse ; then
27 dnl AC_MSG_ERROR("gnuplot not installed");
30 dnl dnl PKG_CHECK_MODULES(gpiv, glib >= 1.2.0)
31 dnl AM_PATH_GLIB(1.2.0, , AC_MSG_ERROR("glib not installed"))
32 dnl AC_CHECK_LIB(glib, g_malloc0, ,
33 dnl AC_MSG_ERROR("libglib not installed"))
34 dnl AC_CHECK_HEADER(glib-1.2/glib.h, ,
35 dnl AC_MSG_ERROR("missing glib-1.2/glib.h")
38 PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.0.0)
42 AC_CHECK_LIB(glib-2.0, g_malloc0, ,
43 AC_MSG_ERROR("libglib not installed"))
45 AC_CHECK_PROG(PERL, perl, true, false)
46 AM_CONDITIONAL(HAVE_PERL, $PERL)
47 AC_CHECK_PROG(PYTHON, python, true, false)
48 AM_CONDITIONAL(HAVE_PYTHON, $PYTHON)
49 AC_CHECK_PROG(CONVERT, convert, true, false)
50 AM_CONDITIONAL(HAVE_CONVERT, $CONVERT)
51 AC_CHECK_PROG(PLOTMTV, plotmtv, true, false)
52 AM_CONDITIONAL(HAVE_PLOTMTV, $PLOTMTV)
54 AC_CHECK_LIB(fftw3, fftw_plan_dft_r2c_2d, ,
55 AC_MSG_ERROR("libfftw3 not installed"))
57 AC_CHECK_LIB(gslcblas, main, ,
58 AC_MSG_ERROR("libgslcblas not installed"))
60 AC_CHECK_LIB(gsl, main, ,
61 AC_MSG_ERROR("libgsl not installed"))
63 dnl AC_CHECK_HEADER(gpiv.h, ,
64 dnl AC_MSG_ERROR("missing gpiv.h"))
68 dnl Enabling Message Passing Interface (MPI) for parallel computing
71 [ --enable-mpi enable Message Protocol Interface (MPI)],
72 [ENABLE_MPI="-DENABLE_MPI"]
77 if test "${ENABLE_MPI}" == '-DENABLE_MPI'; then
78 ACX_MPI(AC_MSG_WARN("libmpi HAS BEEN installed"),
79 AC_MSG_ERROR("libmpi IS NOT installed"))
84 AC_CHECK_LIB(mpi, main, ,
85 AC_MSG_ERROR("libmpi not installed"))
86 AC_CHECK_HEADER(mpi.h, ,
87 AC_MSG_ERROR("missing mpi.h"))
89 AC_CHECK_LIB(gpiv_mpi, gpiv_piv_mpi_bcast_pivpar, ,
90 AC_MSG_ERROR("gpiv_piv_mpi_bcast_pivpar is not working in libgpiv_mpi. \
91 Enable MPI in libgpiv or disable it here by leaving out --enable-mpi during ./configure"))
93 AC_CHECK_PROG(MPIPYTHON, mpipython, true, false)
96 AC_CHECK_LIB(gpiv, gpiv_warning, ,
97 AC_MSG_ERROR("libgpiv has not been installed"))
101 AC_CHECK_HEADERS([ stdlib.h string.h unistd.h \
105 dnl AC_MSG_ERROR("missing one of the required library headers")
112 [ --enable-cam enable (IEEE-1394) camera],
113 [ENABLE_CAM="-DENABLE_CAM"]
119 [ --enable-trig enable (realtime) triggering],
120 [ENABLE_TRIG="-DENABLE_TRIG"]
122 AC_SUBST(ENABLE_TRIG)
126 dnl Enabling IEEE1394 camera
128 if test "${ENABLE_CAM}" == '-DENABLE_CAM'; then
129 AC_CHECK_LIB(gpiv, gpiv_cam_get_camvar, ,
130 AC_MSG_ERROR("(IEEE-1394) camera is not working in libgpiv. \
131 Enable (IEEE-1394) camera in libgpiv or disable it here by leaving out --enable-cam during ./configure"))
133 AC_CHECK_LIB(raw1394, raw1394_destroy_handle, ,
134 AC_MSG_ERROR("libraw1394 not installed"))
136 AC_CHECK_LIB(dc1394_control, dc1394_create_handle, ,
137 AC_MSG_ERROR("libdc1394_control not installed"))
139 AC_CHECK_HEADER(libdc1394/dc1394_control.h, ,
140 AC_MSG_ERROR("missing dc1394_control.h"))
142 AC_CHECK_HEADER(libraw1394/raw1394.h, ,
143 AC_MSG_ERROR("missing raw1394.h"))
148 dnl Enabling triggering using RTL/RTAI
150 if test "${ENABLE_TRIG}" == '-DENABLE_TRIG'; then
151 AC_CHECK_LIB(gpiv, gpiv_trig_openrtfs, ,
152 AC_MSG_ERROR("(Realtime) triggering is not working in libgpiv. \
153 Enable (realtime) triggering in libgpiv or disable it here by leaving out --enable-trig during ./configure"))
157 AC_CHECK_PROG(CONTROL, gpiv_control, true, false)
158 AM_CONDITIONAL(HAVE_CONTROL, $CONTROL)
163 [ --disable-rta=RTATOPDIR place where the RTAI code \
164 resides (default /usr/lib/realtime)],
165 [RTA_TOPDIR="$enableval"],
166 [RTA_TOPDIR="/usr/lib/realtime"]
171 [ --enable-k=KTOPDIR place where the installed kernel \
172 headers resides (default /usr/src/kernel-headers-2.4.27-adeos)],
173 [K_TOPDIR="$enableval"],
174 [K_TOPDIR="/usr/src/kernel-headers-2.4.27-adeos"]
179 AM_CONDITIONAL(HAVE_MPIPYTHON, $MPIPYTHON)
180 AM_CONDITIONAL(BUILD_MPI, test "${ENABLE_MPI}" == '-DENABLE_MPI')
184 dnl Enabling Open Multi-Processing (OMP) for parallel computing
187 [ --enable-omp enable Open Multi-Processing (OMP)],
188 [ENABLE_OMP="ENABLE_OMP"]
191 if test "${ENABLE_OMP}" == 'ENABLE_OMP'; then
194 AC_CHECK_LIB(gomp, main, ,
195 AC_MSG_ERROR("libgomp not installed"))
196 AC_CHECK_HEADER(omp.h, ,
197 AC_MSG_ERROR("missing omp.h"))
199 dnl No need to use -DENABLE_OMP: gcc will do that!
209 src/evaluate/Makefile
210 src/validate/Makefile
216 echo "===================================================================="
217 if test x$PERL = xfalse ; then
218 echo "Perl has not been found on this system."
219 echo "Though, this is not provided for the building process"
220 echo "Only some independant scripts will not work"
224 if test x$CONVERT = xfalse ; then
225 echo "Convert has not been found on this system."
226 echo "Though, this is not provided for the building process"
227 echo "Only some independant scripts will not work"
231 if test x$PLOTMTV = xfalse ; then
232 echo "Plotmtv has not been found on this system."
233 echo "Though, this is not provided for the building process"
234 echo "Only some independant scripts will not work"
239 echo "Configuration succesfully finished"
240 if test $ENABLE_CAM; then
241 echo "with (IEEE-1394) camera enabled"
244 if test $ENABLE_TRIG; then
245 echo "with (realtime) triggering enabled."
246 if test x$CONTROL = xfalse ; then
247 echo "Gpiv_control has not been found on this system, and probably gpivtrig-rtl isn't"
248 echo "resident as well. This script eases to install and uninstall the gpivtrig-rtl"
249 echo "and RTAI kernel modules that are needed for the triggering of camera and lasers."
254 if test $ENABLE_MPI; then
255 echo "Using Message Passing Interface (MPI)"
256 echo "for processing on distributed memory systems"
259 if test $ENABLE_OMP; then
260 echo "Using Open Multi-Processing (OMP)"
261 echo "for processing on shared memory systems"
264 echo "Type 'make' and 'make install' to build and install the gpiv-tools."
265 echo "===================================================================="