Skip to content

Commit

Permalink
updated sqlite3 version
Browse files Browse the repository at this point in the history
  • Loading branch information
rongxin-liu committed Nov 1, 2023
1 parent a8cee18 commit 061a8b2
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 deletions.
12 changes: 6 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -105,19 +105,19 @@ RUN apt update && \
rm --force --recursive ruby-3.2.2


# Install SQLite 3.x
# Install SQLite 3.4x
# https://www.sqlite.org/download.html
# https://www.sqlite.org/howtocompile.html#compiling_the_command_line_interface
COPY shell.c.patch /tmp
RUN cd /tmp && \
curl --remote-name https://www.sqlite.org/2023/sqlite-amalgamation-3420000.zip && \
unzip sqlite-amalgamation-3420000.zip && \
rm --force sqlite-amalgamation-3420000.zip && \
cd sqlite-amalgamation-3420000 && \
curl --remote-name https://www.sqlite.org/2023/sqlite-amalgamation-3440000.zip && \
unzip sqlite-amalgamation-3440000.zip && \
rm --force sqlite-amalgamation-3440000.zip && \
cd sqlite-amalgamation-3440000 && \
patch shell.c < /tmp/shell.c.patch && \
gcc -D HAVE_READLINE -D SQLITE_DEFAULT_FOREIGN_KEYS=1 -D SQLITE_OMIT_DYNAPROMPT=1 shell.c sqlite3.c -lpthread -ldl -lm -lreadline -lncurses -o /usr/local/bin/sqlite3 && \
cd .. && \
rm --force --recursive sqlite-amalgamation-3420000 && \
rm --force --recursive sqlite-amalgamation-3440000 && \
rm --force /tmp/shell.c.patch


Expand Down
28 changes: 14 additions & 14 deletions shell.c.patch
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# diff shell.c shell_modified.c > shell.c.patch
27832,27842c27832,27842
28631,28641c28631,28641
< printf(
< "SQLite version %s %.19s\n" /*extra-version-info*/
< "SQLite version %s %.19s%s\n" /*extra-version-info*/
< "Enter \".help\" for usage hints.\n",
< sqlite3_libversion(), sqlite3_sourceid()
< sqlite3_libversion(), sqlite3_sourceid(), zCharset
< );
< if( warnInmemoryDb ){
< printf("Connected to a ");
Expand All @@ -12,14 +12,14 @@
< "persistent database.\n");
< }
---
> // printf(
> // "SQLite version %s %.19s\n" /*extra-version-info*/
> // "Enter \".help\" for usage hints.\n",
> // sqlite3_libversion(), sqlite3_sourceid()
> // );
> // if( warnInmemoryDb ){
> // printf("Connected to a ");
> // printBold("transient in-memory database");
> // printf(".\nUse \".open FILENAME\" to reopen on a "
> // "persistent database.\n");
> // }
> // printf(
> // "SQLite version %s %.19s%s\n" /*extra-version-info*/
> // "Enter \".help\" for usage hints.\n",
> // sqlite3_libversion(), sqlite3_sourceid(), zCharset
> // );
> // if( warnInmemoryDb ){
> // printf("Connected to a ");
> // printBold("transient in-memory database");
> // printf(".\nUse \".open FILENAME\" to reopen on a "
> // "persistent database.\n");
> // }

0 comments on commit 061a8b2

Please sign in to comment.