/ Hex Artifact Content
Login
SQLite training in Houston TX on 2019-11-05 (details)
Part of the 2019 Tcl Conference

Artifact 72a5e42beb090b32bca580285dc0ab3c4670adb8:


0000: 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  .#--------------
0010: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0020: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0030: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0040: 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 23 20 53 75 70 70  ---------.# Supp
0050: 6f 72 74 73 20 74 68 65 20 66 6f 6c 6c 6f 77 69  orts the followi
0060: 6e 67 20 6e 6f 6e 2d 73 74 61 6e 64 61 72 64 20  ng non-standard 
0070: 73 77 69 74 63 68 65 73 2e 0a 23 0a 23 20 20 20  switches..#.#   
0080: 2d 2d 65 6e 61 62 6c 65 2d 74 68 72 65 61 64 73  --enable-threads
0090: 61 66 65 0a 23 20 20 20 2d 2d 65 6e 61 62 6c 65  afe.#   --enable
00a0: 2d 72 65 61 64 6c 69 6e 65 0a 23 20 20 20 2d 2d  -readline.#   --
00b0: 65 6e 61 62 6c 65 2d 65 64 69 74 6c 69 6e 65 0a  enable-editline.
00c0: 23 20 20 20 2d 2d 65 6e 61 62 6c 65 2d 73 74 61  #   --enable-sta
00d0: 74 69 63 2d 73 68 65 6c 6c 0a 23 20 20 20 2d 2d  tic-shell.#   --
00e0: 65 6e 61 62 6c 65 2d 64 79 6e 61 6d 69 63 2d 65  enable-dynamic-e
00f0: 78 74 65 6e 73 69 6f 6e 73 0a 23 0a 0a 41 43 5f  xtensions.#..AC_
0100: 50 52 45 52 45 51 28 32 2e 36 31 29 0a 41 43 5f  PREREQ(2.61).AC_
0110: 49 4e 49 54 28 73 71 6c 69 74 65 2c 20 2d 2d 53  INIT(sqlite, --S
0120: 51 4c 49 54 45 2d 56 45 52 53 49 4f 4e 2d 2d 2c  QLITE-VERSION--,
0130: 20 68 74 74 70 3a 2f 2f 77 77 77 2e 73 71 6c 69   http://www.sqli
0140: 74 65 2e 6f 72 67 29 0a 41 43 5f 43 4f 4e 46 49  te.org).AC_CONFI
0150: 47 5f 53 52 43 44 49 52 28 5b 73 71 6c 69 74 65  G_SRCDIR([sqlite
0160: 33 2e 63 5d 29 0a 0a 23 20 55 73 65 20 61 75 74  3.c])..# Use aut
0170: 6f 6d 61 6b 65 2e 0a 41 4d 5f 49 4e 49 54 5f 41  omake..AM_INIT_A
0180: 55 54 4f 4d 41 4b 45 28 5b 66 6f 72 65 69 67 6e  UTOMAKE([foreign
0190: 5d 29 0a 0a 41 43 5f 53 59 53 5f 4c 41 52 47 45  ])..AC_SYS_LARGE
01a0: 46 49 4c 45 0a 0a 23 20 43 68 65 63 6b 20 66 6f  FILE..# Check fo
01b0: 72 20 72 65 71 75 69 72 65 64 20 70 72 6f 67 72  r required progr
01c0: 61 6d 73 2e 0a 41 43 5f 50 52 4f 47 5f 43 43 0a  ams..AC_PROG_CC.
01d0: 41 43 5f 50 52 4f 47 5f 4c 49 42 54 4f 4f 4c 0a  AC_PROG_LIBTOOL.
01e0: 41 43 5f 50 52 4f 47 5f 4d 4b 44 49 52 5f 50 0a  AC_PROG_MKDIR_P.
01f0: 0a 23 20 43 68 65 63 6b 20 66 6f 72 20 6c 69 62  .# Check for lib
0200: 72 61 72 79 20 66 75 6e 63 74 69 6f 6e 73 20 74  rary functions t
0210: 68 61 74 20 53 51 4c 69 74 65 20 63 61 6e 20 6f  hat SQLite can o
0220: 70 74 69 6f 6e 61 6c 6c 79 20 75 73 65 2e 0a 41  ptionally use..A
0230: 43 5f 43 48 45 43 4b 5f 46 55 4e 43 53 28 5b 66  C_CHECK_FUNCS([f
0240: 64 61 74 61 73 79 6e 63 20 75 73 6c 65 65 70 20  datasync usleep 
0250: 66 75 6c 6c 66 73 79 6e 63 20 6c 6f 63 61 6c 74  fullfsync localt
0260: 69 6d 65 5f 72 20 67 6d 74 69 6d 65 5f 72 5d 29  ime_r gmtime_r])
0270: 0a 41 43 5f 46 55 4e 43 5f 53 54 52 45 52 52 4f  .AC_FUNC_STRERRO
0280: 52 5f 52 0a 0a 41 43 5f 43 4f 4e 46 49 47 5f 46  R_R..AC_CONFIG_F
0290: 49 4c 45 53 28 5b 4d 61 6b 65 66 69 6c 65 20 73  ILES([Makefile s
02a0: 71 6c 69 74 65 33 2e 70 63 5d 29 0a 41 43 5f 53  qlite3.pc]).AC_S
02b0: 55 42 53 54 28 42 55 49 4c 44 5f 43 46 4c 41 47  UBST(BUILD_CFLAG
02c0: 53 29 0a 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  S)..#-----------
02d0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
02e0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
02f0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0300: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 23 20 20  ------------.#  
0310: 20 2d 2d 65 6e 61 62 6c 65 2d 65 64 69 74 6c 69   --enable-editli
0320: 6e 65 0a 23 20 20 20 2d 2d 65 6e 61 62 6c 65 2d  ne.#   --enable-
0330: 72 65 61 64 6c 69 6e 65 0a 23 0a 41 43 5f 41 52  readline.#.AC_AR
0340: 47 5f 45 4e 41 42 4c 45 28 65 64 69 74 6c 69 6e  G_ENABLE(editlin
0350: 65 2c 20 5b 41 53 5f 48 45 4c 50 5f 53 54 52 49  e, [AS_HELP_STRI
0360: 4e 47 28 0a 20 20 5b 2d 2d 65 6e 61 62 6c 65 2d  NG(.  [--enable-
0370: 65 64 69 74 6c 69 6e 65 5d 2c 20 0a 20 20 5b 75  editline], .  [u
0380: 73 65 20 42 53 44 20 6c 69 62 65 64 69 74 5d 29  se BSD libedit])
0390: 5d 2c 20 0a 20 20 5b 5d 2c 20 5b 65 6e 61 62 6c  ], .  [], [enabl
03a0: 65 5f 65 64 69 74 6c 69 6e 65 3d 79 65 73 5d 29  e_editline=yes])
03b0: 0a 41 43 5f 41 52 47 5f 45 4e 41 42 4c 45 28 72  .AC_ARG_ENABLE(r
03c0: 65 61 64 6c 69 6e 65 2c 20 5b 41 53 5f 48 45 4c  eadline, [AS_HEL
03d0: 50 5f 53 54 52 49 4e 47 28 0a 20 20 5b 2d 2d 65  P_STRING(.  [--e
03e0: 6e 61 62 6c 65 2d 72 65 61 64 6c 69 6e 65 5d 2c  nable-readline],
03f0: 20 0a 20 20 5b 75 73 65 20 72 65 61 64 6c 69 6e   .  [use readlin
0400: 65 5d 29 5d 2c 20 0a 20 20 5b 5d 2c 20 5b 65 6e  e])], .  [], [en
0410: 61 62 6c 65 5f 72 65 61 64 6c 69 6e 65 3d 6e 6f  able_readline=no
0420: 5d 29 0a 69 66 20 74 65 73 74 20 78 22 24 65 6e  ]).if test x"$en
0430: 61 62 6c 65 5f 65 64 69 74 6c 69 6e 65 22 20 21  able_editline" !
0440: 3d 20 78 6e 6f 20 3b 20 74 68 65 6e 0a 20 20 73  = xno ; then.  s
0450: 4c 49 42 53 3d 24 4c 49 42 53 0a 20 20 4c 49 42  LIBS=$LIBS.  LIB
0460: 53 3d 22 22 0a 20 20 41 43 5f 53 45 41 52 43 48  S="".  AC_SEARCH
0470: 5f 4c 49 42 53 28 5b 72 65 61 64 6c 69 6e 65 5d  _LIBS([readline]
0480: 2c 5b 65 64 69 74 5d 2c 5b 65 6e 61 62 6c 65 5f  ,[edit],[enable_
0490: 72 65 61 64 6c 69 6e 65 3d 6e 6f 5d 2c 5b 65 6e  readline=no],[en
04a0: 61 62 6c 65 5f 65 64 69 74 6c 69 6e 65 3d 6e 6f  able_editline=no
04b0: 5d 29 0a 20 20 52 45 41 44 4c 49 4e 45 5f 4c 49  ]).  READLINE_LI
04c0: 42 53 3d 24 4c 49 42 53 0a 20 20 69 66 20 74 65  BS=$LIBS.  if te
04d0: 73 74 20 78 22 24 4c 49 42 53 22 20 21 3d 20 22  st x"$LIBS" != "
04e0: 78 22 3b 20 74 68 65 6e 0a 20 20 20 20 20 41 43  x"; then.     AC
04f0: 5f 44 45 46 49 4e 45 28 5b 48 41 56 45 5f 45 44  _DEFINE([HAVE_ED
0500: 49 54 4c 49 4e 45 5d 2c 31 2c 44 65 66 69 6e 65  ITLINE],1,Define
0510: 20 74 6f 20 75 73 65 20 42 53 44 20 65 64 69 74   to use BSD edit
0520: 6c 69 6e 65 29 0a 20 20 65 6c 73 65 0a 20 20 20  line).  else.   
0530: 20 75 6e 73 65 74 20 61 63 5f 63 76 5f 73 65 61   unset ac_cv_sea
0540: 72 63 68 5f 72 65 61 64 6c 69 6e 65 0a 20 20 66  rch_readline.  f
0550: 69 0a 20 20 4c 49 42 53 3d 24 73 4c 49 42 53 0a  i.  LIBS=$sLIBS.
0560: 66 69 0a 69 66 20 74 65 73 74 20 78 22 24 65 6e  fi.if test x"$en
0570: 61 62 6c 65 5f 72 65 61 64 6c 69 6e 65 22 20 21  able_readline" !
0580: 3d 20 78 6e 6f 20 3b 20 74 68 65 6e 0a 20 20 73  = xno ; then.  s
0590: 4c 49 42 53 3d 24 4c 49 42 53 0a 20 20 4c 49 42  LIBS=$LIBS.  LIB
05a0: 53 3d 22 22 0a 20 20 41 43 5f 53 45 41 52 43 48  S="".  AC_SEARCH
05b0: 5f 4c 49 42 53 28 74 67 65 74 65 6e 74 2c 20 63  _LIBS(tgetent, c
05c0: 75 72 73 65 73 20 6e 63 75 72 73 65 73 20 6e 63  urses ncurses nc
05d0: 75 72 73 65 73 77 2c 20 5b 5d 2c 20 5b 5d 29 0a  ursesw, [], []).
05e0: 20 20 41 43 5f 53 45 41 52 43 48 5f 4c 49 42 53    AC_SEARCH_LIBS
05f0: 28 72 65 61 64 6c 69 6e 65 2c 20 72 65 61 64 6c  (readline, readl
0600: 69 6e 65 2c 20 5b 5d 2c 20 5b 65 6e 61 62 6c 65  ine, [], [enable
0610: 5f 72 65 61 64 6c 69 6e 65 3d 6e 6f 5d 29 0a 20  _readline=no]). 
0620: 20 41 43 5f 43 48 45 43 4b 5f 46 55 4e 43 53 28   AC_CHECK_FUNCS(
0630: 72 65 61 64 6c 69 6e 65 2c 20 5b 5d 2c 20 5b 5d  readline, [], []
0640: 29 0a 20 20 52 45 41 44 4c 49 4e 45 5f 4c 49 42  ).  READLINE_LIB
0650: 53 3d 24 4c 49 42 53 0a 20 20 4c 49 42 53 3d 24  S=$LIBS.  LIBS=$
0660: 73 4c 49 42 53 0a 66 69 0a 41 43 5f 53 55 42 53  sLIBS.fi.AC_SUBS
0670: 54 28 52 45 41 44 4c 49 4e 45 5f 4c 49 42 53 29  T(READLINE_LIBS)
0680: 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  .#--------------
0690: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
06a0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
06b0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
06c0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 23 2d 2d 2d 2d  ---------..#----
06d0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
06e0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
06f0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0700: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0710: 2d 2d 2d 0a 23 20 20 20 2d 2d 65 6e 61 62 6c 65  ---.#   --enable
0720: 2d 74 68 72 65 61 64 73 61 66 65 0a 23 0a 41 43  -threadsafe.#.AC
0730: 5f 41 52 47 5f 45 4e 41 42 4c 45 28 74 68 72 65  _ARG_ENABLE(thre
0740: 61 64 73 61 66 65 2c 20 5b 41 53 5f 48 45 4c 50  adsafe, [AS_HELP
0750: 5f 53 54 52 49 4e 47 28 0a 20 20 5b 2d 2d 65 6e  _STRING(.  [--en
0760: 61 62 6c 65 2d 74 68 72 65 61 64 73 61 66 65 5d  able-threadsafe]
0770: 2c 20 5b 62 75 69 6c 64 20 61 20 74 68 72 65 61  , [build a threa
0780: 64 2d 73 61 66 65 20 6c 69 62 72 61 72 79 20 5b  d-safe library [
0790: 64 65 66 61 75 6c 74 3d 79 65 73 5d 5d 29 5d 2c  default=yes]])],
07a0: 20 0a 20 20 5b 5d 2c 20 5b 65 6e 61 62 6c 65 5f   .  [], [enable_
07b0: 74 68 72 65 61 64 73 61 66 65 3d 79 65 73 5d 29  threadsafe=yes])
07c0: 0a 54 48 52 45 41 44 53 41 46 45 5f 46 4c 41 47  .THREADSAFE_FLAG
07d0: 53 3d 2d 44 53 51 4c 49 54 45 5f 54 48 52 45 41  S=-DSQLITE_THREA
07e0: 44 53 41 46 45 3d 30 0a 69 66 20 74 65 73 74 20  DSAFE=0.if test 
07f0: 78 22 24 65 6e 61 62 6c 65 5f 74 68 72 65 61 64  x"$enable_thread
0800: 73 61 66 65 22 20 21 3d 20 22 78 6e 6f 22 3b 20  safe" != "xno"; 
0810: 74 68 65 6e 0a 20 20 54 48 52 45 41 44 53 41 46  then.  THREADSAF
0820: 45 5f 46 4c 41 47 53 3d 22 2d 44 5f 52 45 45 4e  E_FLAGS="-D_REEN
0830: 54 52 41 4e 54 3d 31 20 2d 44 53 51 4c 49 54 45  TRANT=1 -DSQLITE
0840: 5f 54 48 52 45 41 44 53 41 46 45 3d 31 22 0a 20  _THREADSAFE=1". 
0850: 20 41 43 5f 53 45 41 52 43 48 5f 4c 49 42 53 28   AC_SEARCH_LIBS(
0860: 70 74 68 72 65 61 64 5f 63 72 65 61 74 65 2c 20  pthread_create, 
0870: 70 74 68 72 65 61 64 29 0a 20 20 41 43 5f 53 45  pthread).  AC_SE
0880: 41 52 43 48 5f 4c 49 42 53 28 70 74 68 72 65 61  ARCH_LIBS(pthrea
0890: 64 5f 6d 75 74 65 78 61 74 74 72 5f 69 6e 69 74  d_mutexattr_init
08a0: 2c 20 70 74 68 72 65 61 64 29 0a 66 69 0a 41 43  , pthread).fi.AC
08b0: 5f 53 55 42 53 54 28 54 48 52 45 41 44 53 41 46  _SUBST(THREADSAF
08c0: 45 5f 46 4c 41 47 53 29 0a 23 2d 2d 2d 2d 2d 2d  E_FLAGS).#------
08d0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
08e0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
08f0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0900: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0910: 2d 0a 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  -..#------------
0920: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0930: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0940: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0950: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 23 20 20 20  -----------.#   
0960: 2d 2d 65 6e 61 62 6c 65 2d 64 79 6e 61 6d 69 63  --enable-dynamic
0970: 2d 65 78 74 65 6e 73 69 6f 6e 73 0a 23 0a 41 43  -extensions.#.AC
0980: 5f 41 52 47 5f 45 4e 41 42 4c 45 28 64 79 6e 61  _ARG_ENABLE(dyna
0990: 6d 69 63 2d 65 78 74 65 6e 73 69 6f 6e 73 2c 20  mic-extensions, 
09a0: 5b 41 53 5f 48 45 4c 50 5f 53 54 52 49 4e 47 28  [AS_HELP_STRING(
09b0: 0a 20 20 5b 2d 2d 65 6e 61 62 6c 65 2d 64 79 6e  .  [--enable-dyn
09c0: 61 6d 69 63 2d 65 78 74 65 6e 73 69 6f 6e 73 5d  amic-extensions]
09d0: 2c 20 5b 73 75 70 70 6f 72 74 20 6c 6f 61 64 61  , [support loada
09e0: 62 6c 65 20 65 78 74 65 6e 73 69 6f 6e 73 20 5b  ble extensions [
09f0: 64 65 66 61 75 6c 74 3d 79 65 73 5d 5d 29 5d 2c  default=yes]])],
0a00: 20 0a 20 20 5b 5d 2c 20 5b 65 6e 61 62 6c 65 5f   .  [], [enable_
0a10: 64 79 6e 61 6d 69 63 5f 65 78 74 65 6e 73 69 6f  dynamic_extensio
0a20: 6e 73 3d 79 65 73 5d 29 0a 69 66 20 74 65 73 74  ns=yes]).if test
0a30: 20 78 22 24 65 6e 61 62 6c 65 5f 64 79 6e 61 6d   x"$enable_dynam
0a40: 69 63 5f 65 78 74 65 6e 73 69 6f 6e 73 22 20 21  ic_extensions" !
0a50: 3d 20 22 78 6e 6f 22 3b 20 74 68 65 6e 0a 20 20  = "xno"; then.  
0a60: 41 43 5f 53 45 41 52 43 48 5f 4c 49 42 53 28 64  AC_SEARCH_LIBS(d
0a70: 6c 6f 70 65 6e 2c 20 64 6c 29 0a 65 6c 73 65 0a  lopen, dl).else.
0a80: 20 20 44 59 4e 41 4d 49 43 5f 45 58 54 45 4e 53    DYNAMIC_EXTENS
0a90: 49 4f 4e 5f 46 4c 41 47 53 3d 2d 44 53 51 4c 49  ION_FLAGS=-DSQLI
0aa0: 54 45 5f 4f 4d 49 54 5f 4c 4f 41 44 5f 45 58 54  TE_OMIT_LOAD_EXT
0ab0: 45 4e 53 49 4f 4e 3d 31 0a 66 69 0a 41 43 5f 4d  ENSION=1.fi.AC_M
0ac0: 53 47 5f 43 48 45 43 4b 49 4e 47 28 5b 66 6f 72  SG_CHECKING([for
0ad0: 20 77 68 65 74 68 65 72 20 74 6f 20 73 75 70 70   whether to supp
0ae0: 6f 72 74 20 64 79 6e 61 6d 69 63 20 65 78 74 65  ort dynamic exte
0af0: 6e 73 69 6f 6e 73 5d 29 0a 41 43 5f 4d 53 47 5f  nsions]).AC_MSG_
0b00: 52 45 53 55 4c 54 28 24 65 6e 61 62 6c 65 5f 64  RESULT($enable_d
0b10: 79 6e 61 6d 69 63 5f 65 78 74 65 6e 73 69 6f 6e  ynamic_extension
0b20: 73 29 0a 41 43 5f 53 55 42 53 54 28 44 59 4e 41  s).AC_SUBST(DYNA
0b30: 4d 49 43 5f 45 58 54 45 4e 53 49 4f 4e 5f 46 4c  MIC_EXTENSION_FL
0b40: 41 47 53 29 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  AGS).#----------
0b50: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0b60: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0b70: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0b80: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 23  -------------..#
0b90: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0ba0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0bb0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0bc0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0bd0: 2d 2d 2d 2d 2d 2d 2d 0a 23 20 20 20 2d 2d 65 6e  -------.#   --en
0be0: 61 62 6c 65 2d 66 74 73 35 0a 23 0a 41 43 5f 41  able-fts5.#.AC_A
0bf0: 52 47 5f 45 4e 41 42 4c 45 28 66 74 73 35 2c 20  RG_ENABLE(fts5, 
0c00: 5b 41 53 5f 48 45 4c 50 5f 53 54 52 49 4e 47 28  [AS_HELP_STRING(
0c10: 0a 20 20 5b 2d 2d 65 6e 61 62 6c 65 2d 66 74 73  .  [--enable-fts
0c20: 35 5d 2c 20 5b 69 6e 63 6c 75 64 65 20 66 74 73  5], [include fts
0c30: 35 20 73 75 70 70 6f 72 74 20 5b 64 65 66 61 75  5 support [defau
0c40: 6c 74 3d 6e 6f 5d 5d 29 5d 2c 20 0a 20 20 5b 5d  lt=no]])], .  []
0c50: 2c 20 5b 65 6e 61 62 6c 65 5f 66 74 73 35 3d 6e  , [enable_fts5=n
0c60: 6f 5d 29 0a 69 66 20 74 65 73 74 20 78 22 24 65  o]).if test x"$e
0c70: 6e 61 62 6c 65 5f 66 74 73 35 22 20 3d 3d 20 22  nable_fts5" == "
0c80: 78 79 65 73 22 3b 20 74 68 65 6e 0a 20 20 41 43  xyes"; then.  AC
0c90: 5f 53 45 41 52 43 48 5f 4c 49 42 53 28 6c 6f 67  _SEARCH_LIBS(log
0ca0: 2c 20 6d 29 0a 20 20 46 54 53 35 5f 46 4c 41 47  , m).  FTS5_FLAG
0cb0: 53 3d 2d 44 53 51 4c 49 54 45 5f 45 4e 41 42 4c  S=-DSQLITE_ENABL
0cc0: 45 5f 46 54 53 35 0a 66 69 0a 41 43 5f 53 55 42  E_FTS5.fi.AC_SUB
0cd0: 53 54 28 46 54 53 35 5f 46 4c 41 47 53 29 0a 23  ST(FTS5_FLAGS).#
0ce0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0cf0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0d00: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0d10: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0d20: 2d 2d 2d 2d 2d 2d 2d 0a 0a 23 2d 2d 2d 2d 2d 2d  -------..#------
0d30: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0d40: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0d50: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0d60: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0d70: 2d 0a 23 20 20 20 2d 2d 65 6e 61 62 6c 65 2d 6a  -.#   --enable-j
0d80: 73 6f 6e 31 0a 23 0a 41 43 5f 41 52 47 5f 45 4e  son1.#.AC_ARG_EN
0d90: 41 42 4c 45 28 6a 73 6f 6e 31 2c 20 5b 41 53 5f  ABLE(json1, [AS_
0da0: 48 45 4c 50 5f 53 54 52 49 4e 47 28 0a 20 20 5b  HELP_STRING(.  [
0db0: 2d 2d 65 6e 61 62 6c 65 2d 6a 73 6f 6e 31 5d 2c  --enable-json1],
0dc0: 20 5b 69 6e 63 6c 75 64 65 20 6a 73 6f 6e 31 20   [include json1 
0dd0: 73 75 70 70 6f 72 74 20 5b 64 65 66 61 75 6c 74  support [default
0de0: 3d 6e 6f 5d 5d 29 5d 2c 20 0a 20 20 5b 5d 2c 20  =no]])], .  [], 
0df0: 5b 65 6e 61 62 6c 65 5f 6a 73 6f 6e 31 3d 6e 6f  [enable_json1=no
0e00: 5d 29 0a 69 66 20 74 65 73 74 20 78 22 24 65 6e  ]).if test x"$en
0e10: 61 62 6c 65 5f 6a 73 6f 6e 31 22 20 3d 3d 20 22  able_json1" == "
0e20: 78 79 65 73 22 3b 20 74 68 65 6e 0a 20 20 4a 53  xyes"; then.  JS
0e30: 4f 4e 31 5f 46 4c 41 47 53 3d 2d 44 53 51 4c 49  ON1_FLAGS=-DSQLI
0e40: 54 45 5f 45 4e 41 42 4c 45 5f 4a 53 4f 4e 31 0a  TE_ENABLE_JSON1.
0e50: 66 69 0a 41 43 5f 53 55 42 53 54 28 4a 53 4f 4e  fi.AC_SUBST(JSON
0e60: 31 5f 46 4c 41 47 53 29 0a 23 2d 2d 2d 2d 2d 2d  1_FLAGS).#------
0e70: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0e80: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0e90: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0ea0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0eb0: 2d 0a 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  -..#------------
0ec0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0ed0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0ee0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0ef0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 23 20 20 20  -----------.#   
0f00: 2d 2d 65 6e 61 62 6c 65 2d 73 74 61 74 69 63 2d  --enable-static-
0f10: 73 68 65 6c 6c 0a 23 0a 41 43 5f 41 52 47 5f 45  shell.#.AC_ARG_E
0f20: 4e 41 42 4c 45 28 73 74 61 74 69 63 2d 73 68 65  NABLE(static-she
0f30: 6c 6c 2c 20 5b 41 53 5f 48 45 4c 50 5f 53 54 52  ll, [AS_HELP_STR
0f40: 49 4e 47 28 0a 20 20 5b 2d 2d 65 6e 61 62 6c 65  ING(.  [--enable
0f50: 2d 73 74 61 74 69 63 2d 73 68 65 6c 6c 5d 2c 20  -static-shell], 
0f60: 0a 20 20 5b 73 74 61 74 69 63 61 6c 6c 79 20 6c  .  [statically l
0f70: 69 6e 6b 20 6c 69 62 73 71 6c 69 74 65 33 20 69  ink libsqlite3 i
0f80: 6e 74 6f 20 73 68 65 6c 6c 20 74 6f 6f 6c 20 5b  nto shell tool [
0f90: 64 65 66 61 75 6c 74 3d 79 65 73 5d 5d 29 5d 2c  default=yes]])],
0fa0: 20 0a 20 20 5b 5d 2c 20 5b 65 6e 61 62 6c 65 5f   .  [], [enable_
0fb0: 73 74 61 74 69 63 5f 73 68 65 6c 6c 3d 79 65 73  static_shell=yes
0fc0: 5d 29 0a 69 66 20 74 65 73 74 20 78 22 24 65 6e  ]).if test x"$en
0fd0: 61 62 6c 65 5f 73 74 61 74 69 63 5f 73 68 65 6c  able_static_shel
0fe0: 6c 22 20 3d 3d 20 22 78 79 65 73 22 3b 20 74 68  l" == "xyes"; th
0ff0: 65 6e 0a 20 20 45 58 54 52 41 5f 53 48 45 4c 4c  en.  EXTRA_SHELL
1000: 5f 4f 42 4a 3d 73 71 6c 69 74 65 33 2e 24 4f 42  _OBJ=sqlite3.$OB
1010: 4a 45 58 54 0a 65 6c 73 65 0a 20 20 45 58 54 52  JEXT.else.  EXTR
1020: 41 5f 53 48 45 4c 4c 5f 4f 42 4a 3d 6c 69 62 73  A_SHELL_OBJ=libs
1030: 71 6c 69 74 65 33 2e 6c 61 0a 66 69 0a 41 43 5f  qlite3.la.fi.AC_
1040: 53 55 42 53 54 28 45 58 54 52 41 5f 53 48 45 4c  SUBST(EXTRA_SHEL
1050: 4c 5f 4f 42 4a 29 0a 23 2d 2d 2d 2d 2d 2d 2d 2d  L_OBJ).#--------
1060: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1070: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1080: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1090: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a  ---------------.
10a0: 0a 41 43 5f 43 48 45 43 4b 5f 46 55 4e 43 53 28  .AC_CHECK_FUNCS(
10b0: 70 6f 73 69 78 5f 66 61 6c 6c 6f 63 61 74 65 29  posix_fallocate)
10c0: 0a 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ..#-------------
10d0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
10e0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
10f0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1100: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 23 20 55 50 44  ----------.# UPD
1110: 41 54 45 3a 20 4d 61 79 62 65 20 69 74 27 73 20  ATE: Maybe it's 
1120: 62 65 74 74 65 72 20 69 66 20 75 73 65 72 73 20  better if users 
1130: 6a 75 73 74 20 73 65 74 20 43 46 4c 41 47 53 20  just set CFLAGS 
1140: 62 65 66 6f 72 65 20 69 6e 76 6f 6b 69 6e 67 0a  before invoking.
1150: 23 20 63 6f 6e 66 69 67 75 72 65 2e 20 54 68 69  # configure. Thi
1160: 73 20 6f 70 74 69 6f 6e 20 64 6f 65 73 6e 27 74  s option doesn't
1170: 20 72 65 61 6c 6c 79 20 61 64 64 20 6d 75 63 68   really add much
1180: 2e 2e 2e 0a 23 0a 23 20 20 20 2d 2d 65 6e 61 62  ....#.#   --enab
1190: 6c 65 2d 74 65 6d 70 73 74 6f 72 65 0a 23 0a 23  le-tempstore.#.#
11a0: 20 41 43 5f 41 52 47 5f 45 4e 41 42 4c 45 28 74   AC_ARG_ENABLE(t
11b0: 65 6d 70 73 74 6f 72 65 2c 20 5b 41 53 5f 48 45  empstore, [AS_HE
11c0: 4c 50 5f 53 54 52 49 4e 47 28 0a 23 20 20 20 5b  LP_STRING(.#   [
11d0: 2d 2d 65 6e 61 62 6c 65 2d 74 65 6d 70 73 74 6f  --enable-tempsto
11e0: 72 65 5d 2c 20 0a 23 20 20 20 5b 69 6e 2d 6d 65  re], .#   [in-me
11f0: 6d 6f 72 79 20 74 65 6d 70 6f 72 61 72 79 20 74  mory temporary t
1200: 61 62 6c 65 73 20 28 6e 65 76 65 72 2c 20 6e 6f  ables (never, no
1210: 2c 20 79 65 73 2c 20 61 6c 77 61 79 73 29 20 5b  , yes, always) [
1220: 64 65 66 61 75 6c 74 3d 6e 6f 5d 5d 29 5d 2c 20  default=no]])], 
1230: 0a 23 20 20 20 5b 5d 2c 20 5b 65 6e 61 62 6c 65  .#   [], [enable
1240: 5f 74 65 6d 70 73 74 6f 72 65 3d 6e 6f 5d 29 0a  _tempstore=no]).
1250: 23 20 41 43 5f 4d 53 47 5f 43 48 45 43 4b 49 4e  # AC_MSG_CHECKIN
1260: 47 28 5b 66 6f 72 20 77 68 65 74 68 65 72 20 6f  G([for whether o
1270: 72 20 6e 6f 74 20 74 6f 20 73 74 6f 72 65 20 74  r not to store t
1280: 65 6d 70 20 74 61 62 6c 65 73 20 69 6e 2d 6d 65  emp tables in-me
1290: 6d 6f 72 79 5d 29 0a 23 20 63 61 73 65 20 22 24  mory]).# case "$
12a0: 65 6e 61 62 6c 65 5f 74 65 6d 70 73 74 6f 72 65  enable_tempstore
12b0: 22 20 69 6e 0a 23 20 20 20 6e 65 76 65 72 20 29  " in.#   never )
12c0: 20 20 54 45 4d 50 5f 53 54 4f 52 45 3d 30 20 3b    TEMP_STORE=0 ;
12d0: 3b 0a 23 20 20 20 6e 6f 20 29 20 20 20 20 20 54  ;.#   no )     T
12e0: 45 4d 50 5f 53 54 4f 52 45 3d 31 20 3b 3b 0a 23  EMP_STORE=1 ;;.#
12f0: 20 20 20 61 6c 77 61 79 73 20 29 20 54 45 4d 50     always ) TEMP
1300: 5f 53 54 4f 52 45 3d 33 20 3b 3b 0a 23 20 20 20  _STORE=3 ;;.#   
1310: 79 65 73 20 29 20 20 20 20 54 45 4d 50 5f 53 54  yes )    TEMP_ST
1320: 4f 52 45 3d 33 20 3b 3b 0a 23 20 20 20 2a 20 29  ORE=3 ;;.#   * )
1330: 0a 23 20 20 20 20 20 54 45 4d 50 5f 53 54 4f 52  .#     TEMP_STOR
1340: 45 3d 31 0a 23 20 20 20 20 20 65 6e 61 62 6c 65  E=1.#     enable
1350: 5f 74 65 6d 70 73 74 6f 72 65 3d 79 65 73 0a 23  _tempstore=yes.#
1360: 20 20 20 3b 3b 0a 23 20 65 73 61 63 0a 23 20 41     ;;.# esac.# A
1370: 43 5f 4d 53 47 5f 52 45 53 55 4c 54 28 24 65 6e  C_MSG_RESULT($en
1380: 61 62 6c 65 5f 74 65 6d 70 73 74 6f 72 65 29 0a  able_tempstore).
1390: 23 20 41 43 5f 53 55 42 53 54 28 54 45 4d 50 5f  # AC_SUBST(TEMP_
13a0: 53 54 4f 52 45 29 0a 23 2d 2d 2d 2d 2d 2d 2d 2d  STORE).#--------
13b0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
13c0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
13d0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
13e0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a  ---------------.
13f0: 0a 41 43 5f 4f 55 54 50 55 54 0a                 .AC_OUTPUT.