blob: d95fa36b131883b0bc933e8a8bfc90daa31f873d [file] [log] [blame]
drh71eb93e2001-09-28 01:34:43 +00001#
2# This file describes a "configure" script that is used to build
3# makefiles for a particular platform. Process this file using
4# Autoconf version 1.13 in order to generate that script. All
5# lines of this file up to the AC_INIT macro are ignored.
6#
7# The build process allows for using a cross-compiler. But the default
8# action is to target the same platform that we are running on. The
9# configure script needs to discover the following properties of the
10# build and target systems:
11#
12# srcdir
13#
14# The is the name of the directory that contains the
15# "configure" shell script. All source files are
16# located relative to this directory.
17#
18# bindir
19#
20# The name of the directory where executables should be
21# written by the "install" target of the makefile.
22#
23# program_prefix
24#
25# Add this prefix to the names of all executables that run
26# on the target machine. Default: ""
27#
28# ENABLE_SHARED
29#
30# True if shared libraries should be generated.
31#
32# BUILD_CC
33#
34# The name of a command that is used to convert C
35# source files into executables that run on the build
36# platform.
37#
38# BUILD_CFLAGS
39#
40# Switches that the build compiler needs in order to construct
41# command-line programs.
42#
43# BUILD_LIBS
44#
45# Libraries that the build compiler needs in order to construct
46# command-line programs.
47#
48# BUILD_EXEEXT
49#
50# The filename extension for executables on the build
51# platform. "" for Unix and ".exe" for Windows.
52#
53# TARGET_CC
54#
55# The name of a command that runs on the build platform
56# and converts C source files into *.o files for the
57# target platform. In other words, the cross-compiler.
58#
59# TARGET_CFLAGS
60#
61# Switches that the target compiler needs to turn C source files
62# into *.o files. Do not include TARGET_TCL_INC in this list.
63# Makefiles might add additional switches such as "-I.".
64#
drh7b5717e2004-11-25 13:50:01 +000065# TCL_*
drh71eb93e2001-09-28 01:34:43 +000066#
drh7b5717e2004-11-25 13:50:01 +000067# Lots of values are read in from the tclConfig.sh script,
68# if that script is available.
drh71eb93e2001-09-28 01:34:43 +000069#
70# TARGET_READLINE_LIBS
71#
72# This is the library directives passed to the target linker
73# that cause the executable to link against the readline library.
74# This might be a switch like "-lreadline" or pathnames of library
75# file like "../../src/libreadline.a".
76#
77# TARGET_READLINE_INC
78#
79# This variables define the directory that contain header
80# files for the readline library. If the compiler is able
81# to find <readline.h> on its own, then this can be blank.
82#
83# TARGET_LINK
84#
85# The name of the linker that combines *.o files generated
86# by TARGET_CC into executables for the target platform.
87#
88# TARGET_LIBS
89#
90# Additional libraries or other switch that the target linker needs
91# to build an executable on the target. Do not include
92# on this list any libraries in TARGET_TCL_LIBS and
93# TARGET_READLINE_LIBS, etc.
94#
95# TARGET_EXEEXT
96#
97# The filename extension for executables on the
98# target platform. "" for Unix and ".exe" for windows.
99#
100# The generated configure script will make an attempt to guess
101# at all of the above parameters. You can override any of
102# the guesses by setting the environment variable named
103# "config_AAAA" where "AAAA" is the name of the parameter
104# described above. (Exception: srcdir cannot be set this way.)
105# If you have a file that sets one or more of these environment
106# variables, you can invoke configure as follows:
107#
108# configure --with-hints=FILE
109#
110# where FILE is the name of the file that sets the environment
111# variables. FILE should be an absolute pathname.
112#
drh71eb93e2001-09-28 01:34:43 +0000113# This configure.in file is easy to reuse on other projects. Just
114# change the argument to AC_INIT(). And disable any features that
115# you don't need (for example BLT) by erasing or commenting out
116# the corresponding code.
117#
118AC_INIT(src/sqlite.h.in)
119
120dnl Put the RCS revision string after AC_INIT so that it will also
121dnl show in in configure.
122# The following RCS revision string applies to configure.in
drh7b5717e2004-11-25 13:50:01 +0000123# $Revision: 1.12 $
drh71eb93e2001-09-28 01:34:43 +0000124
125#########
126# Programs needed
127#
128AC_PROG_LIBTOOL
129AC_PROG_INSTALL
130
131#########
132# Set up an appropriate program prefix
133#
134if test "$program_prefix" = "NONE"; then
135 program_prefix=""
136fi
137AC_SUBST(program_prefix)
138
a.rottmannc7e93832003-03-24 09:39:32 +0000139if test -f VERSION; then
140 VERSION=`cat VERSION`
141 echo "Version set to $VERSION"
142fi
143AC_SUBST(VERSION)
144
drh71eb93e2001-09-28 01:34:43 +0000145#########
146# Check to see if the --with-hints=FILE option is used. If there is none,
147# then check for a files named "$host.hints" and ../$hosts.hints where
148# $host is the hostname of the build system. If still no hints are
149# found, try looking in $system.hints and ../$system.hints where
150# $system is the result of uname -s.
151#
152AC_ARG_WITH(hints,
153 [ --with-hints=FILE Read configuration options from FILE],
154 hints=$withval)
155if test "$hints" = ""; then
156 host=`hostname | sed 's/\..*//'`
157 if test -r $host.hints; then
158 hints=$host.hints
159 else
160 if test -r ../$host.hints; then
161 hints=../$host.hints
162 fi
163 fi
164fi
165if test "$hints" = ""; then
166 sys=`uname -s`
167 if test -r $sys.hints; then
168 hints=$sys.hints
169 else
170 if test -r ../$sys.hints; then
171 hints=../$sys.hints
172 fi
173 fi
174fi
175if test "$hints" != ""; then
176 AC_MSG_RESULT(reading hints from $hints)
177 . $hints
178fi
179
180#########
181# Locate a compiler for the build machine. This compiler should
182# generate command-line programs that run on the build machine.
183#
184default_build_cflags="-g"
185if test "$config_BUILD_CC" = ""; then
186 AC_PROG_CC
187 if test "$cross_compiling" = "yes"; then
188 AC_MSG_ERROR([unable to find a compiler for building build tools])
189 fi
190 BUILD_CC=$CC
191 default_build_cflags=$CFLAGS
192else
193 BUILD_CC=$config_BUILD_CC
194 AC_MSG_CHECKING([host compiler])
195 CC=$BUILD_CC
196 AC_MSG_RESULT($BUILD_CC)
197fi
198AC_MSG_CHECKING([switches for the host compiler])
199if test "$config_BUILD_CFLAGS" != ""; then
200 CFLAGS=$config_BUILD_CFLAGS
201 BUILD_CFLAGS=$config_BUILD_CFLAGS
202else
203 BUILD_CFLAGS=$default_build_cflags
204fi
205AC_MSG_RESULT($BUILD_CFLAGS)
206if test "$config_BUILD_LIBS" != ""; then
207 BUILD_LIBS=$config_BUILD_LIBS
208fi
209AC_SUBST(BUILD_CC)
210AC_SUBST(BUILD_CFLAGS)
211AC_SUBST(BUILD_LIBS)
212
213##########
214# Locate a compiler that converts C code into *.o files that run on
215# the target machine.
216#
217AC_MSG_CHECKING([target compiler])
218if test "$config_TARGET_CC" != ""; then
219 TARGET_CC=$config_TARGET_CC
220else
221 TARGET_CC=$BUILD_CC
222fi
223AC_MSG_RESULT($TARGET_CC)
224AC_MSG_CHECKING([switches on the target compiler])
225if test "$config_TARGET_CFLAGS" != ""; then
226 TARGET_CFLAGS=$config_TARGET_CFLAGS
227else
228 TARGET_CFLAGS=$BUILD_CFLAGS
229fi
230AC_MSG_RESULT($TARGET_CFLAGS)
231AC_MSG_CHECKING([target linker])
232if test "$config_TARGET_LINK" = ""; then
233 TARGET_LINK=$TARGET_CC
234else
235 TARGET_LINK=$config_TARGET_LINK
236fi
237AC_MSG_RESULT($TARGET_LINK)
238AC_MSG_CHECKING([switches on the target compiler])
239if test "$config_TARGET_TFLAGS" != ""; then
240 TARGET_TFLAGS=$config_TARGET_TFLAGS
241else
242 TARGET_TFLAGS=$BUILD_CFLAGS
243fi
244if test "$config_TARGET_RANLIB" != ""; then
245 TARGET_RANLIB=$config_TARGET_RANLIB
246else
247 AC_PROG_RANLIB
248 TARGET_RANLIB=$RANLIB
249fi
250if test "$config_TARGET_AR" != ""; then
251 TARGET_AR=$config_TARGET_AR
252else
253 TARGET_AR='ar cr'
254fi
255AC_MSG_RESULT($TARGET_TFLAGS)
256AC_SUBST(TARGET_CC)
257AC_SUBST(TARGET_CFLAGS)
258AC_SUBST(TARGET_LINK)
259AC_SUBST(TARGET_LFLAGS)
260AC_SUBST(TARGET_RANLIB)
261AC_SUBST(TARGET_AR)
262
263# Set the $cross variable if we are cross-compiling. Make
264# it 0 if we are not.
265#
266AC_MSG_CHECKING([if host and target compilers are the same])
267if test "$BUILD_CC" = "$TARGET_CC"; then
268 cross=0
269 AC_MSG_RESULT(yes)
270else
271 cross=1
272 AC_MSG_RESULT(no)
273fi
274
275##########
dougcurrie0f290bf2004-06-21 18:57:29 +0000276# Do we want to support multithreaded use of sqlite
drh71eb93e2001-09-28 01:34:43 +0000277#
dougcurrie0f290bf2004-06-21 18:57:29 +0000278AC_ARG_ENABLE(threadsafe,
279[ --enable-threadsafe Support threadsafe operation],,enable_threadsafe=no)
280AC_MSG_CHECKING([whether to support threadsafe operation])
281if test "$enable_threadsafe" = "no"; then
282 THREADSAFE=0
paulb0208cc2003-04-13 18:26:49 +0000283 AC_MSG_RESULT([no])
284else
dougcurrie0f290bf2004-06-21 18:57:29 +0000285 THREADSAFE=1
paulb0208cc2003-04-13 18:26:49 +0000286 AC_MSG_RESULT([yes])
287fi
dougcurrie0f290bf2004-06-21 18:57:29 +0000288AC_SUBST(THREADSAFE)
paulb0208cc2003-04-13 18:26:49 +0000289
dougcurrie65623c72004-09-20 14:57:23 +0000290if test "$THREADSAFE" = "1"; then
291 LIBS=""
292 AC_CHECK_LIB(pthread, pthread_create)
293 TARGET_THREAD_LIB="$LIBS"
294 LIBS=""
295else
296 TARGET_THREAD_LIB=""
297fi
298AC_SUBST(TARGET_THREAD_LIB)
299
paulb0208cc2003-04-13 18:26:49 +0000300##########
xdong3b5543c2003-09-23 00:36:50 +0000301# Do we want to support release
302#
303AC_ARG_ENABLE(releasemode,
304[ --enable-releasemode Support libtool link to release mode],,enable_releasemode=no)
305AC_MSG_CHECKING([whether to support shared library linked as release mode or not])
306if test "$enable_releasemode" = "no"; then
307 ALLOWRELEASE=""
308 AC_MSG_RESULT([no])
309else
310 ALLOWRELEASE="-release `cat VERSION`"
311 AC_MSG_RESULT([yes])
312fi
313AC_SUBST(ALLOWRELEASE)
314
315##########
paulb0208cc2003-04-13 18:26:49 +0000316# Do we want temporary databases in memory
317#
dougcurrie0f290bf2004-06-21 18:57:29 +0000318AC_ARG_ENABLE(tempstore,
319[ --enable-tempstore Use an in-ram database for temporary tables (never,no,yes,always)],,enable_tempstore=yes)
paulb0208cc2003-04-13 18:26:49 +0000320AC_MSG_CHECKING([whether to use an in-ram database for temporary tables])
dougcurrie0f290bf2004-06-21 18:57:29 +0000321case "$enable_tempstore" in
paulb0208cc2003-04-13 18:26:49 +0000322 never )
paul2dc96f92003-04-20 11:46:34 +0000323 TEMP_STORE=0
paulb0208cc2003-04-13 18:26:49 +0000324 AC_MSG_RESULT([never])
325 ;;
326 no )
paul2dc96f92003-04-20 11:46:34 +0000327 TEMP_STORE=1
paulb0208cc2003-04-13 18:26:49 +0000328 AC_MSG_RESULT([no])
329 ;;
330 always )
dougcurrie0f290bf2004-06-21 18:57:29 +0000331 TEMP_STORE=3
paulb0208cc2003-04-13 18:26:49 +0000332 AC_MSG_RESULT([always])
333 ;;
334 * )
paul2dc96f92003-04-20 11:46:34 +0000335 TEMP_STORE=2
paulb0208cc2003-04-13 18:26:49 +0000336 AC_MSG_RESULT([yes])
337 ;;
338esac
paul2dc96f92003-04-20 11:46:34 +0000339
paul2dc96f92003-04-20 11:46:34 +0000340AC_SUBST(TEMP_STORE)
paulb0208cc2003-04-13 18:26:49 +0000341
drh71eb93e2001-09-28 01:34:43 +0000342###########
343# Lots of things are different if we are compiling for Windows using
344# the CYGWIN environment. So check for that special case and handle
345# things accordingly.
346#
347AC_MSG_CHECKING([if executables have the .exe suffix])
348if test "$config_BUILD_EXEEXT" = ".exe"; then
349 CYGWIN=yes
350 AC_MSG_RESULT(yes)
351else
352 AC_MSG_RESULT(unknown)
353fi
354if test "$CYGWIN" != "yes"; then
355 AC_CYGWIN
356fi
357if test "$CYGWIN" = "yes"; then
358 BUILD_EXEEXT=.exe
359else
dougcurrie6194a5f2003-12-19 20:09:51 +0000360 BUILD_EXEEXT=$EXEEXT
drh71eb93e2001-09-28 01:34:43 +0000361fi
362if test "$cross" = "0"; then
363 TARGET_EXEEXT=$BUILD_EXEEXT
364else
365 TARGET_EXEEXT=$config_TARGET_EXEEXT
366fi
367if test "$TARGET_EXEEXT" = ".exe"; then
368 OS_UNIX=0
369 OS_WIN=1
370 tclsubdir=win
dougcurrie0f290bf2004-06-21 18:57:29 +0000371 TARGET_CFLAGS="$TARGET_CFLAGS -DOS_WIN=1"
drh71eb93e2001-09-28 01:34:43 +0000372else
373 OS_UNIX=1
374 OS_WIN=0
375 tclsubdir=unix
dougcurrie0f290bf2004-06-21 18:57:29 +0000376 TARGET_CFLAGS="$TARGET_CFLAGS -DOS_UNIX=1"
drh71eb93e2001-09-28 01:34:43 +0000377fi
drh71eb93e2001-09-28 01:34:43 +0000378
379AC_SUBST(BUILD_EXEEXT)
380AC_SUBST(OS_UNIX)
381AC_SUBST(OS_WIN)
382AC_SUBST(TARGET_EXEEXT)
383
384##########
385# Extract generic linker options from the environment.
386#
387if test "$config_TARGET_LIBS" != ""; then
388 TARGET_LIBS=$config_TARGET_LIBS
389else
390 TARGET_LIBS=""
391fi
392AC_SUBST(TARGET_LIBS)
393
394##########
drh7b5717e2004-11-25 13:50:01 +0000395# Figure out all the parameters needed to compile against Tcl.
drh71eb93e2001-09-28 01:34:43 +0000396#
drh7b5717e2004-11-25 13:50:01 +0000397# This code is derived from the SC_PATH_TCLCONFIG and SC_LOAD_TCLCONFIG
398# macros in the in the tcl.m4 file of the standard TCL distribution.
399# Those macros could not be used directly since we have to make some
400# minor changes to accomodate systems that do not have TCL installed.
drh71eb93e2001-09-28 01:34:43 +0000401#
drh7b5717e2004-11-25 13:50:01 +0000402AC_ARG_ENABLE(tcl, [ --disable-tcl do not build TCL extension],
403 [use_tcl=$enableval],[use_tcl=yes])
404if test "${use_tcl}" = "yes" ; then
405 AC_ARG_WITH(tcl, [ --with-tcl directory containing tcl configuration (tclConfig.sh)], with_tclconfig=${withval})
406 AC_MSG_CHECKING([for Tcl configuration])
407 AC_CACHE_VAL(ac_cv_c_tclconfig,[
408 # First check to see if --with-tcl was specified.
409 if test x"${with_tclconfig}" != x ; then
410 if test -f "${with_tclconfig}/tclConfig.sh" ; then
411 ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
412 else
413 AC_MSG_ERROR([${with_tclconfig} directory doesn't contain tclConfig.sh])
414 fi
drh71eb93e2001-09-28 01:34:43 +0000415 fi
drh7b5717e2004-11-25 13:50:01 +0000416 # then check for a private Tcl installation
417 if test x"${ac_cv_c_tclconfig}" = x ; then
418 for i in \
419 ../tcl \
420 `ls -dr ../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
421 `ls -dr ../tcl[[8-9]].[[0-9]] 2>/dev/null` \
422 `ls -dr ../tcl[[8-9]].[[0-9]]* 2>/dev/null` \
423 ../../tcl \
424 `ls -dr ../../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
425 `ls -dr ../../tcl[[8-9]].[[0-9]] 2>/dev/null` \
426 `ls -dr ../../tcl[[8-9]].[[0-9]]* 2>/dev/null` \
427 ../../../tcl \
428 `ls -dr ../../../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
429 `ls -dr ../../../tcl[[8-9]].[[0-9]] 2>/dev/null` \
430 `ls -dr ../../../tcl[[8-9]].[[0-9]]* 2>/dev/null`
431 do
432 if test -f "$i/unix/tclConfig.sh" ; then
433 ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
434 break
435 fi
436 done
437 fi
438
439 # check in a few common install locations
440 if test x"${ac_cv_c_tclconfig}" = x ; then
441 for i in \
442 `ls -d ${libdir} 2>/dev/null` \
443 `ls -d /usr/local/lib 2>/dev/null` \
444 `ls -d /usr/contrib/lib 2>/dev/null` \
445 `ls -d /usr/lib 2>/dev/null`
446 do
447 if test -f "$i/tclConfig.sh" ; then
448 ac_cv_c_tclconfig=`(cd $i; pwd)`
449 break
450 fi
451 done
452 fi
453
454 # check in a few other private locations
455 if test x"${ac_cv_c_tclconfig}" = x ; then
456 for i in \
457 ${srcdir}/../tcl \
458 `ls -dr ${srcdir}/../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
459 `ls -dr ${srcdir}/../tcl[[8-9]].[[0-9]] 2>/dev/null` \
460 `ls -dr ${srcdir}/../tcl[[8-9]].[[0-9]]* 2>/dev/null`
461 do
462 if test -f "$i/unix/tclConfig.sh" ; then
463 ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
464 break
465 fi
466 done
467 fi
468 ])
469
470 if test x"${ac_cv_c_tclconfig}" = x ; then
471 use_tcl=no
472 AC_MSG_WARN(Can't find Tcl configuration definitions)
473 AC_MSG_WARN(*** Without Tcl the regression tests cannot be executed ***)
474 AC_MSG_WARN(*** Consider using --with-tcl=... to define location of Tcl ***)
475 else
476 TCL_BIN_DIR=${ac_cv_c_tclconfig}
477 AC_MSG_RESULT(found $TCL_BIN_DIR/tclConfig.sh)
478
479 AC_MSG_CHECKING([for existence of $TCL_BIN_DIR/tclConfig.sh])
480 if test -f "$TCL_BIN_DIR/tclConfig.sh" ; then
481 AC_MSG_RESULT([loading])
482 . $TCL_BIN_DIR/tclConfig.sh
483 else
484 AC_MSG_RESULT([file not found])
485 fi
486
487 #
488 # If the TCL_BIN_DIR is the build directory (not the install directory),
489 # then set the common variable name to the value of the build variables.
490 # For example, the variable TCL_LIB_SPEC will be set to the value
491 # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
492 # instead of TCL_BUILD_LIB_SPEC since it will work with both an
493 # installed and uninstalled version of Tcl.
494 #
495
496 if test -f $TCL_BIN_DIR/Makefile ; then
497 TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
498 TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
499 TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
500 fi
501
502 #
503 # eval is required to do the TCL_DBGX substitution
504 #
505
506 eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
507 eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
508 eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
509
510 eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
511 eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
512 eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
513
514 AC_SUBST(TCL_VERSION)
515 AC_SUBST(TCL_BIN_DIR)
516 AC_SUBST(TCL_SRC_DIR)
517 AC_SUBST(TCL_LIBS)
518 AC_SUBST(TCL_INCLUDE_SPEC)
519
520 AC_SUBST(TCL_LIB_FILE)
521 AC_SUBST(TCL_LIB_FLAG)
522 AC_SUBST(TCL_LIB_SPEC)
523
524 AC_SUBST(TCL_STUB_LIB_FILE)
525 AC_SUBST(TCL_STUB_LIB_FLAG)
526 AC_SUBST(TCL_STUB_LIB_SPEC)
527 fi
drh71eb93e2001-09-28 01:34:43 +0000528fi
drh7b5717e2004-11-25 13:50:01 +0000529if test "${use_tcl}" = "no" ; then
530 HAVE_TCL=""
531else
532 HAVE_TCL=1
drh71eb93e2001-09-28 01:34:43 +0000533fi
drh7b5717e2004-11-25 13:50:01 +0000534AC_SUBST(HAVE_TCL)
drh71eb93e2001-09-28 01:34:43 +0000535
536##########
537# Figure out what C libraries are required to compile programs
538# that use "readline()" library.
539#
540if test "$config_TARGET_READLINE_LIBS" != ""; then
541 TARGET_READLINE_LIBS="$config_TARGET_READLINE_LIBS"
542else
543 CC=$TARGET_CC
544 LIBS=""
paul38372372003-04-22 08:04:49 +0000545 AC_SEARCH_LIBS(tgetent, [readline ncurses curses termcap])
546 AC_CHECK_LIB([readline], [readline])
drh71eb93e2001-09-28 01:34:43 +0000547 TARGET_READLINE_LIBS="$LIBS"
548fi
549AC_SUBST(TARGET_READLINE_LIBS)
550
551##########
552# Figure out where to get the READLINE header files.
553#
554AC_MSG_CHECKING([readline header files])
555found=no
556if test "$config_TARGET_READLINE_INC" != ""; then
557 TARGET_READLINE_INC=$config_TARGET_READLINE_INC
558 found=yes
559fi
560if test "$found" = "yes"; then
561 AC_MSG_RESULT($TARGET_READLINE_INC)
562else
563 AC_MSG_RESULT(not specified: still searching...)
564 AC_CHECK_HEADER(readline.h, [found=yes])
565fi
566if test "$found" = "no"; then
dougcurrie6194a5f2003-12-19 20:09:51 +0000567 for dir in /usr /usr/local /usr/local/readline /usr/contrib /mingw; do
drh71eb93e2001-09-28 01:34:43 +0000568 AC_CHECK_FILE($dir/include/readline.h, found=yes)
569 if test "$found" = "yes"; then
570 TARGET_READLINE_INC="-I$dir/include"
571 break
572 fi
573 AC_CHECK_FILE($dir/include/readline/readline.h, found=yes)
574 if test "$found" = "yes"; then
575 TARGET_READLINE_INC="-I$dir/include/readline"
576 break
577 fi
578 done
579fi
580if test "$found" = "yes"; then
581 if test "$TARGET_READLINE_LIBS" = ""; then
582 TARGET_HAVE_READLINE=0
583 else
584 TARGET_HAVE_READLINE=1
585 fi
586else
587 TARGET_HAVE_READLINE=0
588fi
589AC_SUBST(TARGET_READLINE_INC)
590AC_SUBST(TARGET_HAVE_READLINE)
591
592#########
593# Figure out whether or not we have a "usleep()" function.
594#
595AC_CHECK_FUNC(usleep, [TARGET_CFLAGS="$TARGET_CFLAGS -DHAVE_USLEEP=1"])
596
597#########
598# Generate the output files.
599#
a.rottmannc7e93832003-03-24 09:39:32 +0000600AC_OUTPUT([
601Makefile
dougcurrie12b34442004-07-19 03:24:59 +0000602sqlite3.pc
a.rottmannc7e93832003-03-24 09:39:32 +0000603])