| OLD | NEW |
| 1 # | 1 # |
| 2 # The build process allows for using a cross-compiler. But the default | 2 # The build process allows for using a cross-compiler. But the default |
| 3 # action is to target the same platform that we are running on. The | 3 # action is to target the same platform that we are running on. The |
| 4 # configure script needs to discover the following properties of the | 4 # configure script needs to discover the following properties of the |
| 5 # build and target systems: | 5 # build and target systems: |
| 6 # | 6 # |
| 7 # srcdir | 7 # srcdir |
| 8 # | 8 # |
| 9 # The is the name of the directory that contains the | 9 # The is the name of the directory that contains the |
| 10 # "configure" shell script. All source files are | 10 # "configure" shell script. All source files are |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 # | 62 # |
| 63 # This variables define the directory that contain header | 63 # This variables define the directory that contain header |
| 64 # files for the readline library. If the compiler is able | 64 # files for the readline library. If the compiler is able |
| 65 # to find <readline.h> on its own, then this can be blank. | 65 # to find <readline.h> on its own, then this can be blank. |
| 66 # | 66 # |
| 67 # TARGET_EXEEXT | 67 # TARGET_EXEEXT |
| 68 # | 68 # |
| 69 # The filename extension for executables on the | 69 # The filename extension for executables on the |
| 70 # target platform. "" for Unix and ".exe" for windows. | 70 # target platform. "" for Unix and ".exe" for windows. |
| 71 # | 71 # |
| 72 # The generated configure script will make an attempt to guess | |
| 73 # at all of the above parameters. You can override any of | |
| 74 # the guesses by setting the environment variable named | |
| 75 # "config_AAAA" where "AAAA" is the name of the parameter | |
| 76 # described above. (Exception: srcdir cannot be set this way.) | |
| 77 # If you have a file that sets one or more of these environment | |
| 78 # variables, you can invoke configure as follows: | |
| 79 # | |
| 80 # configure --with-hints=FILE | |
| 81 # | |
| 82 # where FILE is the name of the file that sets the environment | |
| 83 # variables. FILE should be an absolute pathname. | |
| 84 # | |
| 85 # This configure.in file is easy to reuse on other projects. Just | 72 # This configure.in file is easy to reuse on other projects. Just |
| 86 # change the argument to AC_INIT(). And disable any features that | 73 # change the argument to AC_INIT(). And disable any features that |
| 87 # you don't need (for example BLT) by erasing or commenting out | 74 # you don't need (for example BLT) by erasing or commenting out |
| 88 # the corresponding code. | 75 # the corresponding code. |
| 89 # | 76 # |
| 90 AC_INIT(sqlite, m4_esyscmd([cat VERSION | tr -d '\n'])) | 77 AC_INIT(sqlite, m4_esyscmd([cat VERSION | tr -d '\n'])) |
| 91 | 78 |
| 92 dnl Make sure the local VERSION file matches this configure script | 79 dnl Make sure the local VERSION file matches this configure script |
| 93 sqlite_version_sanity_check=`cat $srcdir/VERSION | tr -d '\n'` | 80 sqlite_version_sanity_check=`cat $srcdir/VERSION | tr -d '\n'` |
| 94 if test "$PACKAGE_VERSION" != "$sqlite_version_sanity_check" ; then | 81 if test "$PACKAGE_VERSION" != "$sqlite_version_sanity_check" ; then |
| 95 AC_MSG_ERROR([configure script is out of date: | 82 AC_MSG_ERROR([configure script is out of date: |
| 96 configure \$PACKAGE_VERSION = $PACKAGE_VERSION | 83 configure \$PACKAGE_VERSION = $PACKAGE_VERSION |
| 97 top level VERSION file = $sqlite_version_sanity_check | 84 top level VERSION file = $sqlite_version_sanity_check |
| 98 please regen with autoconf]) | 85 please regen with autoconf]) |
| 99 fi | 86 fi |
| 100 | 87 |
| 101 dnl Put the RCS revision string after AC_INIT so that it will also | |
| 102 dnl show in in configure. | |
| 103 # The following RCS revision string applies to configure.in | |
| 104 # $Revision: 1.56 $ | |
| 105 | |
| 106 ######### | 88 ######### |
| 107 # Programs needed | 89 # Programs needed |
| 108 # | 90 # |
| 109 AC_PROG_LIBTOOL | 91 AC_PROG_LIBTOOL |
| 110 AC_PROG_INSTALL | 92 AC_PROG_INSTALL |
| 111 AC_PROG_AWK | |
| 112 | 93 |
| 113 ######### | 94 ######### |
| 114 # Enable large file support (if special flags are necessary) | 95 # Enable large file support (if special flags are necessary) |
| 115 # | 96 # |
| 116 AC_SYS_LARGEFILE | 97 AC_SYS_LARGEFILE |
| 117 | 98 |
| 118 ######### | 99 ######### |
| 119 # Check for needed/wanted data types | 100 # Check for needed/wanted data types |
| 120 AC_CHECK_TYPES([int8_t, int16_t, int32_t, int64_t, intptr_t, uint8_t, | 101 AC_CHECK_TYPES([int8_t, int16_t, int32_t, int64_t, intptr_t, uint8_t, |
| 121 uint16_t, uint32_t, uint64_t, uintptr_t]) | 102 uint16_t, uint32_t, uint64_t, uintptr_t]) |
| 122 | 103 |
| 123 ######### | 104 ######### |
| 124 # Check for needed/wanted headers | 105 # Check for needed/wanted headers |
| 125 AC_CHECK_HEADERS([sys/types.h stdlib.h stdint.h inttypes.h malloc.h]) | 106 AC_CHECK_HEADERS([sys/types.h stdlib.h stdint.h inttypes.h malloc.h]) |
| 126 | 107 |
| 127 ######### | 108 ######### |
| 128 # Figure out whether or not we have these functions | 109 # Figure out whether or not we have these functions |
| 129 # | 110 # |
| 130 AC_CHECK_FUNCS([usleep fdatasync localtime_r gmtime_r localtime_s utime malloc_u
sable_size]) | 111 AC_CHECK_FUNCS([fdatasync gmtime_r isnan localtime_r localtime_s malloc_usable_s
ize strchrnul usleep utime]) |
| 131 | 112 |
| 132 ######### | 113 ######### |
| 133 # By default, we use the amalgamation (this may be changed below...) | 114 # By default, we use the amalgamation (this may be changed below...) |
| 134 # | 115 # |
| 135 USE_AMALGAMATION=1 | 116 USE_AMALGAMATION=1 |
| 136 | 117 |
| 137 ######### | 118 ######### |
| 138 # See whether we can run specific tclsh versions known to work well; | 119 # See whether we can run specific tclsh versions known to work well; |
| 139 # if not, then we fall back to plain tclsh. | 120 # if not, then we fall back to plain tclsh. |
| 140 # TODO: try other versions before falling back? | 121 # TODO: try other versions before falling back? |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 174 RELEASE=`cat $srcdir/VERSION` | 155 RELEASE=`cat $srcdir/VERSION` |
| 175 AC_MSG_NOTICE(Release set to $RELEASE) | 156 AC_MSG_NOTICE(Release set to $RELEASE) |
| 176 AC_SUBST(RELEASE) | 157 AC_SUBST(RELEASE) |
| 177 VERSION_NUMBER=[`cat $srcdir/VERSION \ | 158 VERSION_NUMBER=[`cat $srcdir/VERSION \ |
| 178 | sed 's/[^0-9]/ /g' \ | 159 | sed 's/[^0-9]/ /g' \ |
| 179 | awk '{printf "%d%03d%03d",$1,$2,$3}'`] | 160 | awk '{printf "%d%03d%03d",$1,$2,$3}'`] |
| 180 AC_MSG_NOTICE(Version number set to $VERSION_NUMBER) | 161 AC_MSG_NOTICE(Version number set to $VERSION_NUMBER) |
| 181 AC_SUBST(VERSION_NUMBER) | 162 AC_SUBST(VERSION_NUMBER) |
| 182 | 163 |
| 183 ######### | 164 ######### |
| 184 # Check to see if the --with-hints=FILE option is used. If there is none, | |
| 185 # then check for a files named "$host.hints" and ../$hosts.hints where | |
| 186 # $host is the hostname of the build system. If still no hints are | |
| 187 # found, try looking in $system.hints and ../$system.hints where | |
| 188 # $system is the result of uname -s. | |
| 189 # | |
| 190 AC_ARG_WITH(hints, | |
| 191 AC_HELP_STRING([--with-hints=FILE],[Read configuration options from FILE]), | |
| 192 hints=$withval) | |
| 193 if test "$hints" = ""; then | |
| 194 host=`hostname | sed 's/\..*//'` | |
| 195 if test -r $host.hints; then | |
| 196 hints=$host.hints | |
| 197 else | |
| 198 if test -r ../$host.hints; then | |
| 199 hints=../$host.hints | |
| 200 fi | |
| 201 fi | |
| 202 fi | |
| 203 if test "$hints" = ""; then | |
| 204 sys=`uname -s` | |
| 205 if test -r $sys.hints; then | |
| 206 hints=$sys.hints | |
| 207 else | |
| 208 if test -r ../$sys.hints; then | |
| 209 hints=../$sys.hints | |
| 210 fi | |
| 211 fi | |
| 212 fi | |
| 213 if test "$hints" != ""; then | |
| 214 AC_MSG_RESULT(reading hints from $hints) | |
| 215 . $hints | |
| 216 fi | |
| 217 | |
| 218 ######### | |
| 219 # Locate a compiler for the build machine. This compiler should | 165 # Locate a compiler for the build machine. This compiler should |
| 220 # generate command-line programs that run on the build machine. | 166 # generate command-line programs that run on the build machine. |
| 221 # | 167 # |
| 222 if test x"$cross_compiling" = xno; then | 168 if test x"$cross_compiling" = xno; then |
| 223 BUILD_CC=$CC | 169 BUILD_CC=$CC |
| 224 BUILD_CFLAGS=$CFLAGS | 170 BUILD_CFLAGS=$CFLAGS |
| 225 else | 171 else |
| 226 if test "${BUILD_CC+set}" != set; then | 172 if test "${BUILD_CC+set}" != set; then |
| 227 AC_CHECK_PROGS(BUILD_CC, gcc cc cl) | 173 AC_CHECK_PROGS(BUILD_CC, gcc cc cl) |
| 228 fi | 174 fi |
| 229 if test "${BUILD_CFLAGS+set}" != set; then | 175 if test "${BUILD_CFLAGS+set}" != set; then |
| 230 BUILD_CFLAGS="-g" | 176 BUILD_CFLAGS="-g" |
| 231 fi | 177 fi |
| 232 fi | 178 fi |
| 233 AC_SUBST(BUILD_CC) | 179 AC_SUBST(BUILD_CC) |
| 234 | 180 |
| 235 ########## | 181 ########## |
| 236 # Do we want to support multithreaded use of sqlite | 182 # Do we want to support multithreaded use of sqlite |
| 237 # | 183 # |
| 238 AC_ARG_ENABLE(threadsafe, | 184 AC_ARG_ENABLE(threadsafe, |
| 239 AC_HELP_STRING([--enable-threadsafe],[Support threadsafe operation]),,enable_thr
eadsafe=yes) | 185 AC_HELP_STRING([--disable-threadsafe],[Disable mutexing]),,enable_threadsafe=yes
) |
| 240 AC_MSG_CHECKING([whether to support threadsafe operation]) | 186 AC_MSG_CHECKING([whether to support threadsafe operation]) |
| 241 if test "$enable_threadsafe" = "no"; then | 187 if test "$enable_threadsafe" = "no"; then |
| 242 SQLITE_THREADSAFE=0 | 188 SQLITE_THREADSAFE=0 |
| 243 AC_MSG_RESULT([no]) | 189 AC_MSG_RESULT([no]) |
| 244 else | 190 else |
| 245 SQLITE_THREADSAFE=1 | 191 SQLITE_THREADSAFE=1 |
| 246 AC_MSG_RESULT([yes]) | 192 AC_MSG_RESULT([yes]) |
| 247 fi | 193 fi |
| 248 AC_SUBST(SQLITE_THREADSAFE) | 194 AC_SUBST(SQLITE_THREADSAFE) |
| 249 | 195 |
| 250 if test "$SQLITE_THREADSAFE" = "1"; then | 196 if test "$SQLITE_THREADSAFE" = "1"; then |
| 251 AC_SEARCH_LIBS(pthread_create, pthread) | 197 AC_SEARCH_LIBS(pthread_create, pthread) |
| 252 fi | 198 fi |
| 253 | 199 |
| 254 ########## | 200 ########## |
| 255 # Do we want to allow a connection created in one thread to be used | |
| 256 # in another thread. This does not work on many Linux systems (ex: RedHat 9) | |
| 257 # due to bugs in the threading implementations. This is thus off by default. | |
| 258 # | |
| 259 AC_ARG_ENABLE(cross-thread-connections, | |
| 260 AC_HELP_STRING([--enable-cross-thread-connections],[Allow connection sharing acr
oss threads]),,enable_xthreadconnect=no) | |
| 261 AC_MSG_CHECKING([whether to allow connections to be shared across threads]) | |
| 262 if test "$enable_xthreadconnect" = "no"; then | |
| 263 XTHREADCONNECT='' | |
| 264 AC_MSG_RESULT([no]) | |
| 265 else | |
| 266 XTHREADCONNECT='-DSQLITE_ALLOW_XTHREAD_CONNECT=1' | |
| 267 AC_MSG_RESULT([yes]) | |
| 268 fi | |
| 269 AC_SUBST(XTHREADCONNECT) | |
| 270 | |
| 271 ########## | |
| 272 # Do we want to support release | 201 # Do we want to support release |
| 273 # | 202 # |
| 274 AC_ARG_ENABLE(releasemode, | 203 AC_ARG_ENABLE(releasemode, |
| 275 AC_HELP_STRING([--enable-releasemode],[Support libtool link to release mode]),,e
nable_releasemode=no) | 204 AC_HELP_STRING([--enable-releasemode],[Support libtool link to release mode]),,e
nable_releasemode=no) |
| 276 AC_MSG_CHECKING([whether to support shared library linked as release mode or not
]) | 205 AC_MSG_CHECKING([whether to support shared library linked as release mode or not
]) |
| 277 if test "$enable_releasemode" = "no"; then | 206 if test "$enable_releasemode" = "no"; then |
| 278 ALLOWRELEASE="" | 207 ALLOWRELEASE="" |
| 279 AC_MSG_RESULT([no]) | 208 AC_MSG_RESULT([no]) |
| 280 else | 209 else |
| 281 ALLOWRELEASE="-release `cat $srcdir/VERSION`" | 210 ALLOWRELEASE="-release `cat $srcdir/VERSION`" |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 383 for i in `echo 'puts stdout $auto_path' | ${TCLSH_CMD}` | 312 for i in `echo 'puts stdout $auto_path' | ${TCLSH_CMD}` |
| 384 do | 313 do |
| 385 if test -f "$i/tclConfig.sh" ; then | 314 if test -f "$i/tclConfig.sh" ; then |
| 386 ac_cv_c_tclconfig="$i" | 315 ac_cv_c_tclconfig="$i" |
| 387 break | 316 break |
| 388 fi | 317 fi |
| 389 done | 318 done |
| 390 fi | 319 fi |
| 391 fi | 320 fi |
| 392 | 321 |
| 322 # On ubuntu 14.10, $auto_path on tclsh is not quite correct. |
| 323 # So try again after applying corrections. |
| 324 if test x"${ac_cv_c_tclconfig}" = x ; then |
| 325 if test x"$cross_compiling" = xno; then |
| 326 for i in `echo 'puts stdout $auto_path' | ${TCLSH_CMD} | sed 's,/tcltk/t
cl,/tcl,g'` |
| 327 do |
| 328 if test -f "$i/tclConfig.sh" ; then |
| 329 ac_cv_c_tclconfig="$i" |
| 330 break |
| 331 fi |
| 332 done |
| 333 fi |
| 334 fi |
| 335 |
| 393 # then check for a private Tcl installation | 336 # then check for a private Tcl installation |
| 394 if test x"${ac_cv_c_tclconfig}" = x ; then | 337 if test x"${ac_cv_c_tclconfig}" = x ; then |
| 395 for i in \ | 338 for i in \ |
| 396 ../tcl \ | 339 ../tcl \ |
| 397 `ls -dr ../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \ | 340 `ls -dr ../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \ |
| 398 `ls -dr ../tcl[[8-9]].[[0-9]] 2>/dev/null` \ | 341 `ls -dr ../tcl[[8-9]].[[0-9]] 2>/dev/null` \ |
| 399 `ls -dr ../tcl[[8-9]].[[0-9]]* 2>/dev/null` \ | 342 `ls -dr ../tcl[[8-9]].[[0-9]]* 2>/dev/null` \ |
| 400 ../../tcl \ | 343 ../../tcl \ |
| 401 `ls -dr ../../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \ | 344 `ls -dr ../../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \ |
| 402 `ls -dr ../../tcl[[8-9]].[[0-9]] 2>/dev/null` \ | 345 `ls -dr ../../tcl[[8-9]].[[0-9]] 2>/dev/null` \ |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 493 AC_SUBST(TCL_SRC_DIR) | 436 AC_SUBST(TCL_SRC_DIR) |
| 494 AC_SUBST(TCL_INCLUDE_SPEC) | 437 AC_SUBST(TCL_INCLUDE_SPEC) |
| 495 | 438 |
| 496 AC_SUBST(TCL_LIB_FILE) | 439 AC_SUBST(TCL_LIB_FILE) |
| 497 AC_SUBST(TCL_LIB_FLAG) | 440 AC_SUBST(TCL_LIB_FLAG) |
| 498 AC_SUBST(TCL_LIB_SPEC) | 441 AC_SUBST(TCL_LIB_SPEC) |
| 499 | 442 |
| 500 AC_SUBST(TCL_STUB_LIB_FILE) | 443 AC_SUBST(TCL_STUB_LIB_FILE) |
| 501 AC_SUBST(TCL_STUB_LIB_FLAG) | 444 AC_SUBST(TCL_STUB_LIB_FLAG) |
| 502 AC_SUBST(TCL_STUB_LIB_SPEC) | 445 AC_SUBST(TCL_STUB_LIB_SPEC) |
| 446 AC_SUBST(TCL_SHLIB_SUFFIX) |
| 503 fi | 447 fi |
| 504 fi | 448 fi |
| 505 if test "${use_tcl}" = "no" ; then | 449 if test "${use_tcl}" = "no" ; then |
| 506 HAVE_TCL="" | 450 HAVE_TCL="" |
| 507 else | 451 else |
| 508 HAVE_TCL=1 | 452 HAVE_TCL=1 |
| 509 fi | 453 fi |
| 510 AC_SUBST(HAVE_TCL) | 454 AC_SUBST(HAVE_TCL) |
| 511 | 455 |
| 512 ########## | 456 ########## |
| 513 # Figure out what C libraries are required to compile programs | 457 # Figure out what C libraries are required to compile programs |
| 514 # that use "readline()" library. | 458 # that use "readline()" library. |
| 515 # | 459 # |
| 516 TARGET_READLINE_LIBS="" | 460 TARGET_READLINE_LIBS="" |
| 517 TARGET_READLINE_INC="" | 461 TARGET_READLINE_INC="" |
| 518 TARGET_HAVE_READLINE=0 | 462 TARGET_HAVE_READLINE=0 |
| 463 TARGET_HAVE_EDITLINE=0 |
| 464 AC_ARG_ENABLE([editline], |
| 465 [AC_HELP_STRING([--enable-editline],[enable BSD editline support])], |
| 466 [with_editline=$enableval], |
| 467 [with_editline=auto]) |
| 519 AC_ARG_ENABLE([readline], | 468 AC_ARG_ENABLE([readline], |
| 520 » [AC_HELP_STRING([--disable-readline],[disable readline support [default=
detect]])], | 469 » [AC_HELP_STRING([--disable-readline],[disable readline support])], |
| 521 [with_readline=$enableval], | 470 [with_readline=$enableval], |
| 522 [with_readline=auto]) | 471 [with_readline=auto]) |
| 523 | 472 |
| 473 if test x"$with_editline" != xno; then |
| 474 sLIBS=$LIBS |
| 475 LIBS="" |
| 476 TARGET_HAVE_EDITLINE=1 |
| 477 AC_SEARCH_LIBS(readline,edit,[with_readline=no],[TARGET_HAVE_EDITLINE=0]
) |
| 478 TARGET_READLINE_LIBS=$LIBS |
| 479 LIBS=$sLIBS |
| 480 fi |
| 524 if test x"$with_readline" != xno; then | 481 if test x"$with_readline" != xno; then |
| 525 found="yes" | 482 found="yes" |
| 526 | 483 |
| 527 AC_ARG_WITH([readline-lib], | 484 AC_ARG_WITH([readline-lib], |
| 528 [AC_HELP_STRING([--with-readline-lib],[specify readline library]
)], | 485 [AC_HELP_STRING([--with-readline-lib],[specify readline library]
)], |
| 529 [with_readline_lib=$withval], | 486 [with_readline_lib=$withval], |
| 530 [with_readline_lib="auto"]) | 487 [with_readline_lib="auto"]) |
| 531 if test "x$with_readline_lib" = xauto; then | 488 if test "x$with_readline_lib" = xauto; then |
| 532 save_LIBS="$LIBS" | 489 save_LIBS="$LIBS" |
| 533 LIBS="" | 490 LIBS="" |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 568 TARGET_READLINE_INC="" | 525 TARGET_READLINE_INC="" |
| 569 TARGET_HAVE_READLINE=0 | 526 TARGET_HAVE_READLINE=0 |
| 570 else | 527 else |
| 571 TARGET_HAVE_READLINE=1 | 528 TARGET_HAVE_READLINE=1 |
| 572 fi | 529 fi |
| 573 fi | 530 fi |
| 574 | 531 |
| 575 AC_SUBST(TARGET_READLINE_LIBS) | 532 AC_SUBST(TARGET_READLINE_LIBS) |
| 576 AC_SUBST(TARGET_READLINE_INC) | 533 AC_SUBST(TARGET_READLINE_INC) |
| 577 AC_SUBST(TARGET_HAVE_READLINE) | 534 AC_SUBST(TARGET_HAVE_READLINE) |
| 535 AC_SUBST(TARGET_HAVE_EDITLINE) |
| 578 | 536 |
| 579 ########## | 537 ########## |
| 580 # Figure out what C libraries are required to compile programs | 538 # Figure out what C libraries are required to compile programs |
| 581 # that use "fdatasync()" function. | 539 # that use "fdatasync()" function. |
| 582 # | 540 # |
| 583 AC_SEARCH_LIBS(fdatasync, [rt]) | 541 AC_SEARCH_LIBS(fdatasync, [rt]) |
| 584 | 542 |
| 585 ######### | 543 ######### |
| 586 # check for debug enabled | 544 # check for debug enabled |
| 587 AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug],[enable debugging & verbose
explain]), | 545 AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug],[enable debugging & verbose
explain]), |
| (...skipping 10 matching lines...) Expand all Loading... |
| 598 AC_ARG_ENABLE(amalgamation, AC_HELP_STRING([--disable-amalgamation], | 556 AC_ARG_ENABLE(amalgamation, AC_HELP_STRING([--disable-amalgamation], |
| 599 [Disable the amalgamation and instead build all files separately]), | 557 [Disable the amalgamation and instead build all files separately]), |
| 600 [use_amalgamation=$enableval],[use_amalgamation=yes]) | 558 [use_amalgamation=$enableval],[use_amalgamation=yes]) |
| 601 if test "${use_amalgamation}" != "yes" ; then | 559 if test "${use_amalgamation}" != "yes" ; then |
| 602 USE_AMALGAMATION=0 | 560 USE_AMALGAMATION=0 |
| 603 fi | 561 fi |
| 604 AC_SUBST(USE_AMALGAMATION) | 562 AC_SUBST(USE_AMALGAMATION) |
| 605 | 563 |
| 606 ######### | 564 ######### |
| 607 # See whether we should allow loadable extensions | 565 # See whether we should allow loadable extensions |
| 608 AC_ARG_ENABLE(load-extension, AC_HELP_STRING([--enable-load-extension], | 566 AC_ARG_ENABLE(load-extension, AC_HELP_STRING([--disable-load-extension], |
| 609 [Enable loading of external extensions]), | 567 [Disable loading of external extensions]), |
| 610 [use_loadextension=$enableval],[use_loadextension=no]) | 568 [use_loadextension=$enableval],[use_loadextension=yes]) |
| 611 if test "${use_loadextension}" = "yes" ; then | 569 if test "${use_loadextension}" = "yes" ; then |
| 612 OPT_FEATURE_FLAGS="" | 570 OPT_FEATURE_FLAGS="" |
| 613 AC_SEARCH_LIBS(dlopen, dl) | 571 AC_SEARCH_LIBS(dlopen, dl) |
| 614 else | 572 else |
| 615 OPT_FEATURE_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1" | 573 OPT_FEATURE_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1" |
| 616 fi | 574 fi |
| 617 | 575 |
| 618 ######### | 576 ######### |
| 577 # See whether we should enable Full Text Search extensions |
| 578 AC_ARG_ENABLE(fts3, AC_HELP_STRING([--enable-fts3], |
| 579 [Enable the FTS3 extension]), |
| 580 [enable_fts3=yes],[enable_fts3=no]) |
| 581 if test "${enable_fts3}" = "yes" ; then |
| 582 OPT_FEATURE_FLAGS+=" -DSQLITE_ENABLE_FTS3" |
| 583 fi |
| 584 AC_ARG_ENABLE(fts4, AC_HELP_STRING([--enable-fts4], |
| 585 [Enable the FTS4 extension]), |
| 586 [enable_fts4=yes],[enable_fts4=no]) |
| 587 if test "${enable_fts4}" = "yes" ; then |
| 588 OPT_FEATURE_FLAGS+=" -DSQLITE_ENABLE_FTS4" |
| 589 AC_SEARCH_LIBS([log],[m]) |
| 590 fi |
| 591 AC_ARG_ENABLE(fts5, AC_HELP_STRING([--enable-fts5], |
| 592 [Enable the FTS5 extension]), |
| 593 [enable_fts5=yes],[enable_fts5=no]) |
| 594 if test "${enable_fts5}" = "yes" ; then |
| 595 OPT_FEATURE_FLAGS+=" -DSQLITE_ENABLE_FTS5" |
| 596 AC_SEARCH_LIBS([log],[m]) |
| 597 fi |
| 598 |
| 599 ######### |
| 600 # See whether we should enable JSON1 |
| 601 AC_ARG_ENABLE(json1, AC_HELP_STRING([--enable-json1], |
| 602 [Enable the JSON1 extension]), |
| 603 [enable_json1=yes],[enable_json1=no]) |
| 604 if test "${enable_json1}" = "yes" ; then |
| 605 OPT_FEATURE_FLAGS+=" -DSQLITE_ENABLE_JSON1" |
| 606 fi |
| 607 |
| 608 ######### |
| 609 # See whether we should enable RTREE |
| 610 AC_ARG_ENABLE(rtree, AC_HELP_STRING([--enable-rtree], |
| 611 [Enable the RTREE extension]), |
| 612 [enable_rtree=yes],[enable_rtree=no]) |
| 613 if test "${enable_rtree}" = "yes" ; then |
| 614 OPT_FEATURE_FLAGS+=" -DSQLITE_ENABLE_RTREE" |
| 615 fi |
| 616 |
| 617 ######### |
| 619 # attempt to duplicate any OMITS and ENABLES into the $(OPT_FEATURE_FLAGS) param
eter | 618 # attempt to duplicate any OMITS and ENABLES into the $(OPT_FEATURE_FLAGS) param
eter |
| 620 for option in $CFLAGS $CPPFLAGS | 619 for option in $CFLAGS $CPPFLAGS |
| 621 do | 620 do |
| 622 case $option in | 621 case $option in |
| 623 -DSQLITE_OMIT*) OPT_FEATURE_FLAGS="$OPT_FEATURE_FLAGS $option";; | 622 -DSQLITE_OMIT*) OPT_FEATURE_FLAGS="$OPT_FEATURE_FLAGS $option";; |
| 624 -DSQLITE_ENABLE*) OPT_FEATURE_FLAGS="$OPT_FEATURE_FLAGS $option";; | 623 -DSQLITE_ENABLE*) OPT_FEATURE_FLAGS="$OPT_FEATURE_FLAGS $option";; |
| 625 esac | 624 esac |
| 626 done | 625 done |
| 627 AC_SUBST(OPT_FEATURE_FLAGS) | 626 AC_SUBST(OPT_FEATURE_FLAGS) |
| 628 | 627 |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 684 AC_CONFIG_HEADERS(config.h) | 683 AC_CONFIG_HEADERS(config.h) |
| 685 | 684 |
| 686 ######### | 685 ######### |
| 687 # Generate the output files. | 686 # Generate the output files. |
| 688 # | 687 # |
| 689 AC_SUBST(BUILD_CFLAGS) | 688 AC_SUBST(BUILD_CFLAGS) |
| 690 AC_OUTPUT([ | 689 AC_OUTPUT([ |
| 691 Makefile | 690 Makefile |
| 692 sqlite3.pc | 691 sqlite3.pc |
| 693 ]) | 692 ]) |
| OLD | NEW |