Skip to content

Commit

Permalink
updated node, ruby, sqlite3 versions
Browse files Browse the repository at this point in the history
  • Loading branch information
rongxin-liu committed Jun 24, 2024
1 parent df4ac11 commit 99d7386
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
24 changes: 12 additions & 12 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ RUN cd /tmp && \
chmod a+rx /opt/bin/*


# Install Node.js 21.x
# Install Node.js 22.x
# https://nodejs.dev/en/download/
# https://github.com/tj/n#installation
RUN curl --location https://raw.githubusercontent.com/tj/n/master/bin/n --output /usr/local/bin/n && \
chmod a+x /usr/local/bin/n && \
n 21.6.2
n 22.3.0


# Install Node.js packages
Expand Down Expand Up @@ -86,16 +86,16 @@ RUN apt update && \
apt clean && \
rm --force --recursive /var/lib/apt/lists/* && \
cd /tmp && \
curl https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0.tar.gz --output ruby-3.3.0.tar.gz && \
tar xzf ruby-3.3.0.tar.gz && \
rm --force ruby-3.3.0.tar.gz && \
cd ruby-3.3.0 && \
curl https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.3.tar.gz --output ruby-3.3.3.tar.gz && \
tar xzf ruby-3.3.3.tar.gz && \
rm --force ruby-3.3.3.tar.gz && \
cd ruby-3.3.3 && \
if [ "$BUILDARCH" = "arm64" ]; then ASFLAGS=-mbranch-protection=pac-ret; else ASFLAGS=; fi && \
ASFLAGS=${ASFLAGS} CFLAGS=-Os ./configure --disable-install-doc --enable-load-relative && \
make && \
make install && \
cd .. && \
rm --force --recursive ruby-3.3.0
rm --force --recursive ruby-3.3.3


# Install Ruby packages
Expand All @@ -114,14 +114,14 @@ RUN echo "gem: --no-document" > /etc/gemrc && \
# 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/2024/sqlite-amalgamation-3450000.zip && \
unzip sqlite-amalgamation-3450000.zip && \
rm --force sqlite-amalgamation-3450000.zip && \
cd sqlite-amalgamation-3450000 && \
curl --remote-name https://www.sqlite.org/2024/sqlite-amalgamation-3460000.zip && \
unzip sqlite-amalgamation-3460000.zip && \
rm --force sqlite-amalgamation-3460000.zip && \
cd sqlite-amalgamation-3460000 && \
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-3450000 && \
rm --force --recursive sqlite-amalgamation-3460000 && \
rm --force /tmp/shell.c.patch
Expand Down
2 changes: 1 addition & 1 deletion shell.c.patch
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
29438,29440d29437
30882,30884d30881
< sputf(stdout, "SQLite version %s %.19s%s\n" /*extra-version-info*/
< "Enter \".help\" for usage hints.\n",
< sqlite3_libversion(), sqlite3_sourceid(), SHELL_CIO_CHAR_SET);

0 comments on commit 99d7386

Please sign in to comment.