SQLite

Check-in [3bafeec934]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Makefile enhancements: (1) Rename autoconf/tea/configure.in to autoconf/tea/configure.ac so that it works with the latest versions of autoconf. (2) Add the "amalgamation-tarball" targets to Makefile.in and main.mk (renamed from "dist" in the latter case). (3) Update the README.first file in autoconf/ (4) The TOP macro in Makefile.in is now an absolute rather than a relative path.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 3bafeec934e56f633d0de6890e84fca990e54435
User & Date: drh 2015-01-15 15:47:06.739
Context
2015-01-15
17:38
Fix the spelling of "malloc_usable_size" in configure and configure.ac. (check-in: 8f45217cba user: drh tags: trunk)
15:47
Makefile enhancements: (1) Rename autoconf/tea/configure.in to autoconf/tea/configure.ac so that it works with the latest versions of autoconf. (2) Add the "amalgamation-tarball" targets to Makefile.in and main.mk (renamed from "dist" in the latter case). (3) Update the README.first file in autoconf/ (4) The TOP macro in Makefile.in is now an absolute rather than a relative path. (check-in: 3bafeec934 user: drh tags: trunk)
2015-01-13
21:26
Simplify some code in rtree, to avoid confusing the optimizer in GCC on some macs: gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2335.15.00). Prior to these changes, compiling with -O3 would cause incorrect code to be generated. The change to the nodeGetCell() routine is key. The other changes are merely cosmetic details discovered while bug hunting. (check-in: 882181ff9d user: drh tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to Makefile.in.
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# be able to get it to work by giving it some hints.  See the comment
# at the beginning of configure.in for additional information.
#

# The toplevel directory of the source tree.  This is the directory
# that contains this "Makefile.in" and the "configure.in" script.
#
TOP = @srcdir@

# C Compiler and options for use in building executables that
# will run on the platform that is doing the build.
#
BCC = @BUILD_CC@ @BUILD_CFLAGS@

# TCC is the C Compile and options for use in building executables that 







|







11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# be able to get it to work by giving it some hints.  See the comment
# at the beginning of configure.in for additional information.
#

# The toplevel directory of the source tree.  This is the directory
# that contains this "Makefile.in" and the "configure.in" script.
#
TOP = @abs_srcdir@

# C Compiler and options for use in building executables that
# will run on the platform that is doing the build.
#
BCC = @BUILD_CC@ @BUILD_CFLAGS@

# TCC is the C Compile and options for use in building executables that 
1002
1003
1004
1005
1006
1007
1008





1009
1010
1011
1012
1013
1014
1015
# symbols that do not begin with "sqlite3_". It is run as part of the
# releasetest.tcl script.
#
checksymbols: sqlite3.lo
	nm -g --defined-only sqlite3.o | grep -v " sqlite3_" ; test $$? -ne 0
	echo '0 errors out of 1 tests'






# The next two rules are used to support the "threadtest" target. Building
# threadtest runs a few thread-safety tests that are implemented in C. This
# target is invoked by the releasetest.tcl script.
# 
THREADTEST3_SRC = $(TOP)/test/threadtest3.c    \
                  $(TOP)/test/tt3_checkpoint.c \
                  $(TOP)/test/tt3_index.c      \







>
>
>
>
>







1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
# symbols that do not begin with "sqlite3_". It is run as part of the
# releasetest.tcl script.
#
checksymbols: sqlite3.lo
	nm -g --defined-only sqlite3.o | grep -v " sqlite3_" ; test $$? -ne 0
	echo '0 errors out of 1 tests'

# Build the amalgamation-autoconf package.
#
amalgamation-tarball: sqlite3.c
	TOP=$(TOP) sh $(TOP)/tool/mkautoconfamal.sh

# The next two rules are used to support the "threadtest" target. Building
# threadtest runs a few thread-safety tests that are implemented in C. This
# target is invoked by the releasetest.tcl script.
# 
THREADTEST3_SRC = $(TOP)/test/threadtest3.c    \
                  $(TOP)/test/tt3_checkpoint.c \
                  $(TOP)/test/tt3_index.c      \
Changes to autoconf/README.first.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57

This file describes how to use the files in this directory to create a new
version of the "autoconf-amalgamation" package.

1. The following files should have executable permission:

  chmod 755 install-sh 
  chmod 755 missing 
  chmod 755 depcomp
  chmod 755 config.sub
  chmod 755 config.guess

2. Copy new versions of the following SQLite files into this directory:

  sqlite3.c
  sqlite3.h
  sqlite3ext.h
  sqlite3.1
  sqlite3.pc.in
  shell.c

3. Update the SQLite version number in the AC_INIT macro in file 
   configure.ac:

     AC_INIT(sqlite, 3.6.3, http://www.sqlite.org)

4. Run the following commands to push the version number change through
   to the generated files.

  aclocal
  autoconf
  automake

5. Create the tclsqlite3.c file in the tea/generic directory. As follows:

  mkdir -p tea/generic
  echo "#ifdef USE_SYSTEM_SQLITE"      > tea/generic/tclsqlite3.c 
  echo "# include <sqlite3.h>"        >> tea/generic/tclsqlite3.c
  echo "#else"                        >> tea/generic/tclsqlite3.c
  echo "#include \"../../sqlite3.c\"" >> tea/generic/tclsqlite3.c
  echo "#endif"                       >> tea/generic/tclsqlite3.c
  cat  ../src/tclsqlite.c             >> tea/generic/tclsqlite3.c

6. Update the SQLite version in the AC_INIT macro in file tea/configure.in:

  AC_INIT([sqlite], [3.6.3])

7. From the 'tea' directory, run the following commands:

  autoconf
  rm -rf autom4te.cache

8. Run "./configure && make dist". This builds a distribution package
   named something like "sqlite-3.6.3.tar.gz". Rename to 
   "sqlite-amalgamation-3.6.3.tar.gz" and use.


|
<
<
|
<

<
<
<
<
<
|
<

<
<
<
<
<
<
<
<
|
|
<

<
<
|
<
<
<
|
<
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
1


2

3





4

5








6
7

8


9



10

11






















This directory contains components use to build an autoconf-ready package


of the SQLite amalgamation:  sqlite-autoconf-30XXXXXX.tar.gz







To build the autoconf amalgamation, run from the top-level:










   ./configure
   make amalgamation-tarball




The amalgamation-tarball target (also available in "main.mk") runs the



script tool/mkautoconfamal.sh which does the work.  Refer to that script

for details.






















Name change from autoconf/tea/configure.in to autoconf/tea/configure.ac.
Changes to main.mk.
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
# releasetest.tcl script.
#
checksymbols: sqlite3.o
	nm -g --defined-only sqlite3.o | grep -v " sqlite3_" ; test $$? -ne 0

# Build the amalgamation-autoconf package.
#
dist: sqlite3.c
	TOP=$(TOP) sh $(TOP)/tool/mkautoconfamal.sh


# Standard install and cleanup targets
#
install:	sqlite3 libsqlite3.a sqlite3.h
	mv sqlite3 /usr/bin







|







686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
# releasetest.tcl script.
#
checksymbols: sqlite3.o
	nm -g --defined-only sqlite3.o | grep -v " sqlite3_" ; test $$? -ne 0

# Build the amalgamation-autoconf package.
#
amalgamation-tarball: sqlite3.c
	TOP=$(TOP) sh $(TOP)/tool/mkautoconfamal.sh


# Standard install and cleanup targets
#
install:	sqlite3 libsqlite3.a sqlite3.h
	mv sqlite3 /usr/bin
Changes to tool/mkautoconfamal.sh.
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
echo "#ifdef USE_SYSTEM_SQLITE"      > tea/generic/tclsqlite3.c 
echo "# include <sqlite3.h>"        >> tea/generic/tclsqlite3.c
echo "#else"                        >> tea/generic/tclsqlite3.c
echo "#include \"sqlite3.c\""       >> tea/generic/tclsqlite3.c
echo "#endif"                       >> tea/generic/tclsqlite3.c
cat  $TOP/src/tclsqlite.c           >> tea/generic/tclsqlite3.c

cat tea/configure.in | 
  sed "s/AC_INIT(\[sqlite\], .*)/AC_INIT([sqlite], [$VERSION])/" > tmp
mv tmp tea/configure.in

cd tea
autoconf
rm -rf autom4te.cache

cd ../
./configure && make dist
tar -xzf sqlite-$VERSION.tar.gz
mv sqlite-$VERSION sqlite-autoconf-$ARTIFACT
tar -czf sqlite-autoconf-$ARTIFACT.tar.gz sqlite-autoconf-$ARTIFACT
mv sqlite-autoconf-$ARTIFACT.tar.gz ..








|

|











<
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82

echo "#ifdef USE_SYSTEM_SQLITE"      > tea/generic/tclsqlite3.c 
echo "# include <sqlite3.h>"        >> tea/generic/tclsqlite3.c
echo "#else"                        >> tea/generic/tclsqlite3.c
echo "#include \"sqlite3.c\""       >> tea/generic/tclsqlite3.c
echo "#endif"                       >> tea/generic/tclsqlite3.c
cat  $TOP/src/tclsqlite.c           >> tea/generic/tclsqlite3.c

cat tea/configure.ac | 
  sed "s/AC_INIT(\[sqlite\], .*)/AC_INIT([sqlite], [$VERSION])/" > tmp
mv tmp tea/configure.ac

cd tea
autoconf
rm -rf autom4te.cache

cd ../
./configure && make dist
tar -xzf sqlite-$VERSION.tar.gz
mv sqlite-$VERSION sqlite-autoconf-$ARTIFACT
tar -czf sqlite-autoconf-$ARTIFACT.tar.gz sqlite-autoconf-$ARTIFACT
mv sqlite-autoconf-$ARTIFACT.tar.gz ..