Skip to content

Commit 2efaf98

Browse files
committed
Merge sqlite-release(3.33.0) into prerelease-integration
2 parents d7fb2c0 + 56e5656 commit 2efaf98

File tree

188 files changed

+8868
-1894
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

188 files changed

+8868
-1894
lines changed

Makefile.in

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -465,6 +465,7 @@ TESTSRC += \
465465
$(TOP)/ext/misc/carray.c \
466466
$(TOP)/ext/misc/closure.c \
467467
$(TOP)/ext/misc/csv.c \
468+
$(TOP)/ext/misc/decimal.c \
468469
$(TOP)/ext/misc/eval.c \
469470
$(TOP)/ext/misc/explain.c \
470471
$(TOP)/ext/misc/fileio.c \
@@ -1104,6 +1105,12 @@ parse.c: $(TOP)/src/parse.y lemon$(BEXE)
11041105
sqlite3.h: $(TOP)/src/sqlite.h.in $(TOP)/manifest mksourceid$(BEXE) $(TOP)/VERSION
11051106
$(TCLSH_CMD) $(TOP)/tool/mksqlite3h.tcl $(TOP) >sqlite3.h
11061107

1108+
sqlite3rc.h: $(TOP)/src/sqlite3.rc $(TOP)/VERSION
1109+
echo '#ifndef SQLITE_RESOURCE_VERSION' >$@
1110+
echo -n '#define SQLITE_RESOURCE_VERSION ' >>$@
1111+
cat $(TOP)/VERSION | $(TCLSH_CMD) $(TOP)/tool/replace.tcl exact . , >>$@
1112+
echo '#endif' >>sqlite3rc.h
1113+
11071114
keywordhash.h: $(TOP)/tool/mkkeywordhash.c
11081115
$(BCC) -o mkkeywordhash$(BEXE) $(OPT_FEATURE_FLAGS) $(OPTS) $(TOP)/tool/mkkeywordhash.c
11091116
./mkkeywordhash$(BEXE) >keywordhash.h
@@ -1112,9 +1119,11 @@ keywordhash.h: $(TOP)/tool/mkkeywordhash.c
11121119
SHELL_SRC = \
11131120
$(TOP)/src/shell.c.in \
11141121
$(TOP)/ext/misc/appendvfs.c \
1115-
$(TOP)/ext/misc/shathree.c \
1116-
$(TOP)/ext/misc/fileio.c \
11171122
$(TOP)/ext/misc/completion.c \
1123+
$(TOP)/ext/misc/decimal.c \
1124+
$(TOP)/ext/misc/fileio.c \
1125+
$(TOP)/ext/misc/ieee754.c \
1126+
$(TOP)/ext/misc/shathree.c \
11181127
$(TOP)/ext/misc/sqlar.c \
11191128
$(TOP)/ext/misc/uint.c \
11201129
$(TOP)/ext/expert/sqlite3expert.c \
@@ -1323,6 +1332,9 @@ valgrindtest: $(TESTPROGS) valgrindfuzz
13231332
smoketest: $(TESTPROGS) fuzzcheck$(TEXE)
13241333
./testfixture$(TEXE) $(TOP)/test/main.test $(TESTOPTS)
13251334

1335+
shelltest: $(TESTPROGS)
1336+
./testfixture$(TEXT) $(TOP)/test/permutations.test shell
1337+
13261338
sqlite3_analyzer.c: sqlite3.c $(TOP)/src/tclsqlite.c $(TOP)/tool/spaceanal.tcl $(TOP)/tool/mkccode.tcl $(TOP)/tool/sqlite3_analyzer.c.in
13271339
$(TCLSH_CMD) $(TOP)/tool/mkccode.tcl $(TOP)/tool/sqlite3_analyzer.c.in >sqlite3_analyzer.c
13281340

@@ -1425,10 +1437,10 @@ checksymbols: sqlite3.o
14251437
# a tarball named for the version number. Ex: sqlite-autoconf-3110000.tar.gz.
14261438
# The snapshot-tarball target builds a tarball named by the SHA1 hash
14271439
#
1428-
amalgamation-tarball: sqlite3.c
1440+
amalgamation-tarball: sqlite3.c sqlite3rc.h
14291441
TOP=$(TOP) sh $(TOP)/tool/mkautoconfamal.sh --normal
14301442

1431-
snapshot-tarball: sqlite3.c
1443+
snapshot-tarball: sqlite3.c sqlite3rc.h
14321444
TOP=$(TOP) sh $(TOP)/tool/mkautoconfamal.sh --snapshot
14331445

14341446
# The next two rules are used to support the "threadtest" target. Building

Makefile.msc

Lines changed: 28 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1503,7 +1503,7 @@ SRC12 =
15031503

15041504
# All source code files.
15051505
#
1506-
SRC = $(SRC00) $(SRC01) $(SRC03) $(SRC04) $(SRC05) $(SRC06) $(SRC07) $(SRC08) $(SRC09) $(SRC10) $(SRC11)
1506+
SRC = $(SRC00) $(SRC01) $(SRC03) $(SRC04) $(SRC05) $(SRC06) $(SRC07) $(SRC08) $(SRC09) $(SRC10) $(SRC11) $(SRC12)
15071507

15081508
# Source code to the test files.
15091509
#
@@ -1568,6 +1568,7 @@ TESTEXT = \
15681568
$(TOP)\ext\misc\carray.c \
15691569
$(TOP)\ext\misc\closure.c \
15701570
$(TOP)\ext\misc\csv.c \
1571+
$(TOP)\ext\misc\decimal.c \
15711572
$(TOP)\ext\misc\eval.c \
15721573
$(TOP)\ext\misc\explain.c \
15731574
$(TOP)\ext\misc\fileio.c \
@@ -1854,15 +1855,16 @@ mptest: mptester.exe
18541855
for %i in ($(SRC11)) do copy /Y %i tsrc
18551856
for %i in ($(SRC12)) do copy /Y %i tsrc
18561857
copy /Y fts5.c tsrc
1858+
copy /B tsrc\fts5.c +,,
18571859
copy /Y fts5.h tsrc
1860+
copy /B tsrc\fts5.h +,,
18581861
del /Q tsrc\sqlite.h.in tsrc\parse.y 2>NUL
18591862
$(TCLSH_CMD) $(TOP)\tool\vdbe-compress.tcl $(OPTS) < tsrc\vdbe.c > vdbe.new
18601863
move vdbe.new tsrc\vdbe.c
18611864
echo > .target_source
18621865

1863-
sqlite3.c: .target_source sqlite3ext.h $(MKSQLITE3C_TOOL)
1866+
sqlite3.c: .target_source sqlite3ext.h sqlite3session.h $(MKSQLITE3C_TOOL)
18641867
$(TCLSH_CMD) $(MKSQLITE3C_TOOL) $(MKSQLITE3C_ARGS)
1865-
copy $(TOP)\ext\session\sqlite3session.h .
18661868

18671869
sqlite3-all.c: sqlite3.c $(TOP)\tool\split-sqlite3c.tcl
18681870
$(TCLSH_CMD) $(TOP)\tool\split-sqlite3c.tcl
@@ -1877,7 +1879,8 @@ sqlite3.lo: $(SQLITE3C)
18771879
# Rules to build the LEMON compiler generator
18781880
#
18791881
lempar.c: $(TOP)\tool\lempar.c
1880-
copy $(TOP)\tool\lempar.c .
1882+
copy /Y $(TOP)\tool\lempar.c .
1883+
copy /B lempar.c +,,
18811884

18821885
lemon.exe: $(TOP)\tool\lemon.c lempar.c
18831886
$(BCC) $(NO_WARN) -Daccess=_access \
@@ -2177,7 +2180,8 @@ parse.h: parse.c
21772180

21782181
parse.c: $(TOP)\src\parse.y lemon.exe
21792182
del /Q parse.y parse.h parse.h.temp 2>NUL
2180-
copy $(TOP)\src\parse.y .
2183+
copy /Y $(TOP)\src\parse.y .
2184+
copy /B parse.y +,,
21812185
.\lemon.exe $(REQ_FEATURE_FLAGS) $(OPT_FEATURE_FLAGS) $(EXT_FEATURE_FLAGS) $(OPTS) -S parse.y
21822186

21832187
$(SQLITE3H): $(TOP)\src\sqlite.h.in $(TOP)\manifest mksourceid.exe $(TOP)\VERSION
@@ -2190,8 +2194,13 @@ sqlite3ext.h: .target_source
21902194
copy /Y sqlite3ext.h tsrc\sqlite3ext.h
21912195
!ELSE
21922196
copy /Y tsrc\sqlite3ext.h sqlite3ext.h
2197+
copy /B sqlite3ext.h +,,
21932198
!ENDIF
21942199

2200+
sqlite3session.h: $(TOP)\ext\session\sqlite3session.h
2201+
copy /Y $(TOP)\ext\session\sqlite3session.h .
2202+
copy /B sqlite3session.h +,,
2203+
21952204
mkkeywordhash.exe: $(TOP)\tool\mkkeywordhash.c
21962205
$(BCC) $(NO_WARN) -Fe$@ $(REQ_FEATURE_FLAGS) $(OPT_FEATURE_FLAGS) $(EXT_FEATURE_FLAGS) $(OPTS) \
21972206
$(TOP)\tool\mkkeywordhash.c /link $(LDFLAGS) $(NLTLINKOPTS) $(NLTLIBPATHS)
@@ -2203,10 +2212,12 @@ keywordhash.h: $(TOP)\tool\mkkeywordhash.c mkkeywordhash.exe
22032212
SHELL_SRC = \
22042213
$(TOP)\src\shell.c.in \
22052214
$(TOP)\ext\misc\appendvfs.c \
2206-
$(TOP)\ext\misc\shathree.c \
2207-
$(TOP)\ext\misc\fileio.c \
22082215
$(TOP)\ext\misc\completion.c \
2209-
$(TOP)\ext\misc\uint.c \
2216+
$(TOP)\ext\misc\decimal.c \
2217+
$(TOP)\ext\misc\fileio.c \
2218+
$(TOP)\ext\misc\ieee754.c \
2219+
$(TOP)\ext\misc\shathree.c \
2220+
$(TOP)\ext\misc\uint.c \
22102221
$(TOP)\ext\expert\sqlite3expert.c \
22112222
$(TOP)\ext\expert\sqlite3expert.h \
22122223
$(TOP)\ext\misc\memtrace.c \
@@ -2337,19 +2348,22 @@ LSM1_SRC = \
23372348
$(TOP)\ext\lsm1\lsm_win32.c
23382349

23392350
fts5parse.c: $(TOP)\ext\fts5\fts5parse.y lemon.exe
2340-
copy $(TOP)\ext\fts5\fts5parse.y .
2351+
copy /Y $(TOP)\ext\fts5\fts5parse.y .
2352+
copy /B fts5parse.y +,,
23412353
del /Q fts5parse.h 2>NUL
23422354
.\lemon.exe $(REQ_FEATURE_FLAGS) $(OPT_FEATURE_FLAGS) $(EXT_FEATURE_FLAGS) $(OPTS) -S fts5parse.y
23432355

23442356
fts5parse.h: fts5parse.c
23452357

23462358
fts5.c: $(FTS5_SRC)
23472359
$(TCLSH_CMD) $(TOP)\ext\fts5\tool\mkfts5c.tcl
2348-
copy $(TOP)\ext\fts5\fts5.h .
2360+
copy /Y $(TOP)\ext\fts5\fts5.h .
2361+
copy /B fts5.h +,,
23492362

23502363
lsm1.c: $(LSM1_SRC)
23512364
$(TCLSH_CMD) $(TOP)\ext\lsm1\tool\mklsm1c.tcl
2352-
copy $(TOP)\ext\lsm1\lsm.h .
2365+
copy /Y $(TOP)\ext\lsm1\lsm.h .
2366+
copy /B lsm.h +,,
23532367

23542368
fts5.lo: fts5.c $(HDR) $(EXTHDR)
23552369
$(LTCOMPILE) $(CORE_COMPILE_OPTS) $(NO_WARN) -DSQLITE_CORE -c fts5.c
@@ -2460,6 +2474,9 @@ smoketest: $(TESTPROGS)
24602474
@set PATH=$(LIBTCLPATH);$(PATH)
24612475
.\testfixture.exe $(TOP)\test\main.test $(TESTOPTS)
24622476

2477+
shelltest: $(TESTPROGS)
2478+
.\testfixture.exe $(TOP)\test\permutations.test shell
2479+
24632480
sqlite3_analyzer.c: $(SQLITE3C) $(SQLITE3H) $(TOP)\src\tclsqlite.c $(TOP)\tool\spaceanal.tcl $(TOP)\tool\mkccode.tcl $(TOP)\tool\sqlite3_analyzer.c.in $(SQLITE_TCL_DEP)
24642481
$(TCLSH_CMD) $(TOP)\tool\mkccode.tcl $(TOP)\tool\sqlite3_analyzer.c.in > $@
24652482

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.32.3
1+
3.33.0

autoconf/Makefile.am

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_D
1313

1414
include_HEADERS = sqlite3.h sqlite3ext.h
1515

16-
EXTRA_DIST = sqlite3.1 tea Makefile.msc sqlite3.rc README.txt Replace.cs Makefile.fallback
16+
EXTRA_DIST = sqlite3.1 tea Makefile.msc sqlite3.rc sqlite3rc.h README.txt Replace.cs Makefile.fallback
1717
pkgconfigdir = ${libdir}/pkgconfig
1818
pkgconfig_DATA = sqlite3.pc
1919

configure

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#! /bin/sh
22
# Guess values for system-dependent variables and create Makefiles.
3-
# Generated by GNU Autoconf 2.69 for sqlcipher 3.32.3.
3+
# Generated by GNU Autoconf 2.69 for sqlcipher 3.33.0.
44
#
55
#
66
# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
@@ -587,8 +587,8 @@ MAKEFLAGS=
587587
# Identity of this package.
588588
PACKAGE_NAME='sqlcipher'
589589
PACKAGE_TARNAME='sqlcipher'
590-
PACKAGE_VERSION='3.32.3'
591-
PACKAGE_STRING='sqlcipher 3.32.3'
590+
PACKAGE_VERSION='3.33.0'
591+
PACKAGE_STRING='sqlcipher 3.33.0'
592592
PACKAGE_BUGREPORT=''
593593
PACKAGE_URL=''
594594

@@ -1349,7 +1349,7 @@ if test "$ac_init_help" = "long"; then
13491349
# Omit some internal or obsolete options to make the list less imposing.
13501350
# This message is too long to be a string in the A/UX 3.1 sh.
13511351
cat <<_ACEOF
1352-
\`configure' configures sqlcipher 3.32.3 to adapt to many kinds of systems.
1352+
\`configure' configures sqlcipher 3.33.0 to adapt to many kinds of systems.
13531353
13541354
Usage: $0 [OPTION]... [VAR=VALUE]...
13551355
@@ -1415,7 +1415,7 @@ fi
14151415

14161416
if test -n "$ac_init_help"; then
14171417
case $ac_init_help in
1418-
short | recursive ) echo "Configuration of sqlcipher 3.32.3:";;
1418+
short | recursive ) echo "Configuration of sqlcipher 3.33.0:";;
14191419
esac
14201420
cat <<\_ACEOF
14211421
@@ -1552,7 +1552,7 @@ fi
15521552
test -n "$ac_init_help" && exit $ac_status
15531553
if $ac_init_version; then
15541554
cat <<\_ACEOF
1555-
sqlcipher configure 3.32.3
1555+
sqlcipher configure 3.33.0
15561556
generated by GNU Autoconf 2.69
15571557
15581558
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -1971,7 +1971,7 @@ cat >config.log <<_ACEOF
19711971
This file contains any messages produced by compilers while
19721972
running configure, to aid debugging if configure makes a mistake.
19731973
1974-
It was created by sqlcipher $as_me 3.32.3, which was
1974+
It was created by sqlcipher $as_me 3.33.0, which was
19751975
generated by GNU Autoconf 2.69. Invocation command line was
19761976
19771977
$ $0 $@
@@ -12875,7 +12875,7 @@ if test "${enable_amalgamation+set}" = set; then :
1287512875
enableval=$enable_amalgamation;
1287612876
fi
1287712877

12878-
if test "${enable_amalgamation}" == "no" ; then
12878+
if test "${enable_amalgamation}" = "no" ; then
1287912879
USE_AMALGAMATION=0
1288012880
fi
1288112881

@@ -13226,7 +13226,7 @@ if test "${enable_update_limit+set}" = set; then :
1322613226
enableval=$enable_update_limit;
1322713227
fi
1322813228

13229-
if test "${enable_udlimit}" = "yes" ; then
13229+
if test "${enable_update_limit}" = "yes" ; then
1323013230
OPT_FEATURE_FLAGS="${OPT_FEATURE_FLAGS} -DSQLITE_ENABLE_UPDATE_DELETE_LIMIT"
1323113231
fi
1323213232

@@ -13850,7 +13850,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
1385013850
# report actual input values of CONFIG_FILES etc. instead of their
1385113851
# values after options handling.
1385213852
ac_log="
13853-
This file was extended by sqlcipher $as_me 3.32.3, which was
13853+
This file was extended by sqlcipher $as_me 3.33.0, which was
1385413854
generated by GNU Autoconf 2.69. Invocation command line was
1385513855
1385613856
CONFIG_FILES = $CONFIG_FILES
@@ -13916,7 +13916,7 @@ _ACEOF
1391613916
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
1391713917
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
1391813918
ac_cs_version="\\
13919-
sqlcipher config.status 3.32.3
13919+
sqlcipher config.status 3.33.0
1392013920
configured by $0, generated by GNU Autoconf 2.69,
1392113921
with options \\"\$ac_cs_config\\"
1392213922

configure.ac

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -624,7 +624,7 @@ AC_SUBST(TARGET_DEBUG)
624624
# See whether we should use the amalgamation to build
625625
AC_ARG_ENABLE(amalgamation, AC_HELP_STRING([--disable-amalgamation],
626626
[Disable the amalgamation and instead build all files separately]))
627-
if test "${enable_amalgamation}" == "no" ; then
627+
if test "${enable_amalgamation}" = "no" ; then
628628
USE_AMALGAMATION=0
629629
fi
630630
AC_SUBST(USE_AMALGAMATION)
@@ -706,7 +706,7 @@ fi
706706
# statements.
707707
AC_ARG_ENABLE(update-limit, AC_HELP_STRING([--enable-update-limit],
708708
[Enable the UPDATE/DELETE LIMIT clause]))
709-
if test "${enable_udlimit}" = "yes" ; then
709+
if test "${enable_update_limit}" = "yes" ; then
710710
OPT_FEATURE_FLAGS="${OPT_FEATURE_FLAGS} -DSQLITE_ENABLE_UPDATE_DELETE_LIMIT"
711711
fi
712712

doc/lemon.html

Lines changed: 28 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -104,9 +104,13 @@ <h3>Command Line Options</h3>
104104
are written into the directory that contains the input grammar file.
105105
<li><b>-D<i>name</i></b>
106106
Define C preprocessor macro <i>name</i>. This macro is usable by
107-
"<tt><a href='#pifdef'>%ifdef</a></tt>" and
108-
"<tt><a href='#pifdef'>%ifndef</a></tt>" lines
107+
"<tt><a href='#pifdef'>%ifdef</a></tt>",
108+
"<tt><a href='#pifdef'>%ifndef</a></tt>", and
109+
"<tt><a href="#pifdef">%if</a></tt> lines
109110
in the grammar file.
111+
<li><b>-E</b>
112+
Run the "%if" preprocessor step only and print the revised grammar
113+
file.
110114
<li><b>-g</b>
111115
Do not generate a parser. Instead write the input grammar to standard
112116
output with all comments, actions, and other extraneous text removed.
@@ -555,9 +559,11 @@ <h3>Special Directives</h3>
555559
<li><tt><a href='#default_destructor'>%default_destructor</a></tt>
556560
<li><tt><a href='#default_type'>%default_type</a></tt>
557561
<li><tt><a href='#destructor'>%destructor</a></tt>
562+
<li><tt><a href='#pifdef'>%else</a></tt>
558563
<li><tt><a href='#pifdef'>%endif</a></tt>
559564
<li><tt><a href='#extraarg'>%extra_argument</a></tt>
560565
<li><tt><a href='#pfallback'>%fallback</a></tt>
566+
<li><tt><a href='#pifdef'>%if</a></tt>
561567
<li><tt><a href='#pifdef'>%ifdef</a></tt>
562568
<li><tt><a href='#pifdef'>%ifndef</a></tt>
563569
<li><tt><a href='#pinclude'>%include</a></tt>
@@ -737,10 +743,11 @@ <h4>The <tt>%fallback</tt> directive</h4>
737743
argument.</p>
738744

739745
<a name='pifdef'></a>
740-
<h4>The <tt>%ifdef</tt>, <tt>%ifndef</tt>, and <tt>%endif</tt> directives</h4>
746+
<h4>The <tt>%if</tt> directive and its friends</h4>
741747

742-
<p>The <tt>%ifdef</tt>, <tt>%ifndef</tt>, and <tt>%endif</tt> directives
743-
are similar to #ifdef, #ifndef, and #endif in the C-preprocessor,
748+
<p>The <tt>%if</tt>, <tt>%ifdef</tt>, <tt>%ifndef</tt>, <tt>%else</tt>,
749+
and <tt>%endif</tt> directives
750+
are similar to #if, #ifdef, #ifndef, #else, and #endif in the C-preprocessor,
744751
just not as general.
745752
Each of these directives must begin at the left margin. No whitespace
746753
is allowed between the "%" and the directive name.</p>
@@ -749,12 +756,22 @@ <h4>The <tt>%ifdef</tt>, <tt>%ifndef</tt>, and <tt>%endif</tt> directives</h4>
749756
"<tt>%endif</tt>" is
750757
ignored unless the "-DMACRO" command-line option is used. Grammar text
751758
betwen "<tt>%ifndef MACRO</tt>" and the next nested "<tt>%endif</tt>" is
752-
included except when the "-DMACRO" command-line option is used.</p>
753-
754-
<p>Note that the argument to <tt>%ifdef</tt> and <tt>%ifndef</tt> must
755-
be a single preprocessor symbol name, not a general expression.
756-
There is no "<tt>%else</tt>" directive.</p>
757-
759+
included except when the "-DMACRO" command-line option is used.<p>
760+
761+
<p>The text in between "<tt>%if</tt> <i>CONDITIONAL</i>" and its
762+
corresponding <tt>%endif</tt> is included only if <i>CONDITIONAL</i>
763+
is true. The CONDITION is one or more macro names, optionally connected
764+
using the "||" and "&amp;&amp;" binary operators, the "!" unary operator,
765+
and grouped using balanced parentheses. Each term is true if the
766+
corresponding macro exists, and false if it does not exist.</p>
767+
768+
<p>An optional "<tt>%else</tt>" directive can occur anywhere in between a
769+
<tt>%ifdef</tt>, <tt>%ifndef</tt>, or <tt>%if</tt> directive and
770+
its corresponding <tt>%endif</tt>.</p>
771+
772+
<p>Note that the argument to <tt>%ifdef</tt> and <tt>%ifndef</tt> is
773+
intended to be a single preprocessor symbol name, not a general expression.
774+
Use the "<tt>%if</tt>" directive for general expressions.</p>
758775

759776
<a name='pinclude'></a>
760777
<h4>The <tt>%include</tt> directive</h4>

0 commit comments

Comments
 (0)