OLD | NEW |
1 From 3418fd3e3a60fe9f8b6c52f2aad93dcdf3b7af93 Mon Sep 17 00:00:00 2001 | 1 From 35703557681c70acd710c1ee83f1ef54eef06df8 Mon Sep 17 00:00:00 2001 |
2 From: Scott Hess <shess@chromium.org> | 2 From: Scott Hess <shess@chromium.org> |
3 Date: Fri, 16 Jan 2015 10:24:30 -0800 | 3 Date: Fri, 16 Jan 2015 10:24:30 -0800 |
4 Subject: [PATCH 01/16] [test] SQLite tests compiling on Linux. | 4 Subject: [PATCH 01/10] [test] SQLite tests compiling on Linux. |
5 | 5 |
6 --- | 6 --- |
7 third_party/sqlite/src/Makefile.linux-gcc | 42 ++++++++++++++++++++++--------- | 7 third_party/sqlite/src/Makefile.linux-gcc | 41 ++++++++++++++++++++++--------- |
8 1 file changed, 30 insertions(+), 12 deletions(-) | 8 third_party/sqlite/src/main.mk | 2 +- |
| 9 2 files changed, 30 insertions(+), 13 deletions(-) |
9 | 10 |
10 diff --git a/third_party/sqlite/src/Makefile.linux-gcc b/third_party/sqlite/src/
Makefile.linux-gcc | 11 diff --git a/third_party/sqlite/src/Makefile.linux-gcc b/third_party/sqlite/src/
Makefile.linux-gcc |
11 index 1c9f24f..6d67ba7 100644 | 12 index 1491a4b..a1dec21 100644 |
12 --- a/third_party/sqlite/src/Makefile.linux-gcc | 13 --- a/third_party/sqlite/src/Makefile.linux-gcc |
13 +++ b/third_party/sqlite/src/Makefile.linux-gcc | 14 +++ b/third_party/sqlite/src/Makefile.linux-gcc |
14 @@ -14,7 +14,7 @@ | 15 @@ -14,7 +14,7 @@ |
15 #### The toplevel directory of the source tree. This is the directory | 16 #### The toplevel directory of the source tree. This is the directory |
16 # that contains this "Makefile.in" and the "configure.in" script. | 17 # that contains this "Makefile.in" and the "configure.in" script. |
17 # | 18 # |
18 -TOP = ../sqlite | 19 -TOP = ../sqlite |
19 +TOP = .. | 20 +TOP = .. |
20 | 21 |
21 #### C Compiler and options for use in building executables that | 22 #### C Compiler and options for use in building executables that |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 +# -DSQLITE_OMIT_ATTACH=1 \ | 65 +# -DSQLITE_OMIT_ATTACH=1 \ |
65 +# -DSQLITE_OMIT_LOAD_EXTENSION=1 \ | 66 +# -DSQLITE_OMIT_LOAD_EXTENSION=1 \ |
66 +# -DSQLITE_OMIT_VACUUM=1 \ | 67 +# -DSQLITE_OMIT_VACUUM=1 \ |
67 +# -DSQLITE_TRANSACTION_DEFAULT_IMMEDIATE=1 \ | 68 +# -DSQLITE_TRANSACTION_DEFAULT_IMMEDIATE=1 \ |
68 + | 69 + |
69 +# TODO(shess) I can't see why I need this setting. | 70 +# TODO(shess) I can't see why I need this setting. |
70 +OPTS += -DOS_UNIX=1 | 71 +OPTS += -DOS_UNIX=1 |
71 | 72 |
72 #### The suffix to add to executable files. ".exe" for windows. | 73 #### The suffix to add to executable files. ".exe" for windows. |
73 # Nothing for unix. | 74 # Nothing for unix. |
74 @@ -70,7 +88,7 @@ EXE = | 75 @@ -70,7 +87,7 @@ EXE = |
75 # will run on the target platform. This is usually the same | 76 # will run on the target platform. This is usually the same |
76 # as BCC, unless you are cross-compiling. | 77 # as BCC, unless you are cross-compiling. |
77 # | 78 # |
78 -TCC = gcc -O6 | 79 -TCC = gcc -O6 |
79 +TCC = gcc -Os | 80 +TCC = gcc -Os |
80 #TCC = gcc -g -O0 -Wall | 81 #TCC = gcc -g -O0 -Wall |
81 #TCC = gcc -g -O0 -Wall -fprofile-arcs -ftest-coverage | 82 #TCC = gcc -g -O0 -Wall -fprofile-arcs -ftest-coverage |
82 #TCC = /opt/mingw/bin/i386-mingw32-gcc -O6 | 83 #TCC = /opt/mingw/bin/i386-mingw32-gcc -O6 |
83 @@ -91,16 +109,16 @@ SHPREFIX = lib | 84 @@ -91,16 +108,16 @@ SHPREFIX = lib |
84 | 85 |
85 #### Extra compiler options needed for programs that use the TCL library. | 86 #### Extra compiler options needed for programs that use the TCL library. |
86 # | 87 # |
87 -#TCL_FLAGS = | 88 -#TCL_FLAGS = |
88 +TCL_FLAGS = -I/usr/include/tcl8.5 | 89 +TCL_FLAGS = -I/usr/include/tcl8.6 |
89 #TCL_FLAGS = -DSTATIC_BUILD=1 | 90 #TCL_FLAGS = -DSTATIC_BUILD=1 |
90 -TCL_FLAGS = -I/home/drh/tcltk/8.5linux | 91 -TCL_FLAGS = -I/home/drh/tcltk/8.5linux |
91 +#TCL_FLAGS = -I/home/drh/tcltk/8.5linux | 92 +#TCL_FLAGS = -I/home/drh/tcltk/8.5linux |
92 #TCL_FLAGS = -I/home/drh/tcltk/8.5win -DSTATIC_BUILD=1 | 93 #TCL_FLAGS = -I/home/drh/tcltk/8.5win -DSTATIC_BUILD=1 |
93 #TCL_FLAGS = -I/home/drh/tcltk/8.3hpux | 94 #TCL_FLAGS = -I/home/drh/tcltk/8.3hpux |
94 | 95 |
95 #### Linker options needed to link against the TCL library. | 96 #### Linker options needed to link against the TCL library. |
96 # | 97 # |
97 -#LIBTCL = -ltcl -lm -ldl | 98 -#LIBTCL = -ltcl -lm -ldl |
98 -LIBTCL = /home/drh/tcltk/8.5linux/libtcl8.5g.a -lm -ldl | 99 -LIBTCL = /home/drh/tcltk/8.5linux/libtcl8.5g.a -lm -ldl |
99 +LIBTCL = -ltcl8.5 -lm -ldl | 100 +LIBTCL = -ltcl8.6 -lm -ldl |
100 +#LIBTCL = /home/drh/tcltk/8.5linux/libtcl8.5g.a -lm -ldl | 101 +#LIBTCL = /home/drh/tcltk/8.5linux/libtcl8.5g.a -lm -ldl |
101 #LIBTCL = /home/drh/tcltk/8.5win/libtcl85s.a -lmsvcrt | 102 #LIBTCL = /home/drh/tcltk/8.5win/libtcl85s.a -lmsvcrt |
102 #LIBTCL = /home/drh/tcltk/8.3hpux/libtcl8.3.a -ldld -lm -lc | 103 #LIBTCL = /home/drh/tcltk/8.3hpux/libtcl8.3.a -ldld -lm -lc |
103 | 104 |
| 105 diff --git a/third_party/sqlite/src/main.mk b/third_party/sqlite/src/main.mk |
| 106 index e6ca1ac..fcc0270 100644 |
| 107 --- a/third_party/sqlite/src/main.mk |
| 108 +++ b/third_party/sqlite/src/main.mk |
| 109 @@ -714,7 +714,7 @@ sqlite3_analyzer.c: sqlite3.c $(TOP)/src/tclsqlite.c $(TOP)/
tool/spaceanal.tcl |
| 110 echo "; return zMainloop; }" >> $@ |
| 111 |
| 112 sqlite3_analyzer$(EXE): sqlite3_analyzer.c |
| 113 - $(TCCX) $(TCL_FLAGS) sqlite3_analyzer.c -o $@ $(LIBTCL) $(THREADLIB) |
| 114 + $(TCCX) $(TCL_FLAGS) sqlite3_analyzer.c -o $@ $(LIBTCL) $(TLIBS) $(THREA
DLIB) |
| 115 |
| 116 # Rules to build the 'testfixture' application. |
| 117 # |
104 -- | 118 -- |
105 2.2.1 | 119 2.7.0 |
106 | 120 |
OLD | NEW |