Attached is a patch that builds & installs the sqlite3_rsync binary, and includes a man page describing the sqlite3_rsync utility.
Kind regards, Job
diff --git a/debian/changelog b/debian/changelog index 23360bb..9e56067 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +sqlite3 (3.53.4-2+rsync1) UNRELEASED; urgency=low + + * Build and install sqlite3_rsync, and provide sqlite3_rsync.1 man page. + + -- Job Snijders <[email protected]> Sun, 23 Aug 2026 23:03:22 +0000 + sqlite3 (3.53.4-2) unstable; urgency=high * Backport upstream security fix for CVE-2026-50813: buffer overread in the diff --git a/debian/control b/debian/control index 6582932..39e6bb5 100644 --- a/debian/control +++ b/debian/control @@ -129,3 +129,4 @@ Description: Command line interface for SQLite 3 (tools) - showwal - sqldiff - sqlite3_analyzer + - sqlite3_rsync diff --git a/debian/copyright b/debian/copyright index 6d6a7a1..787fcd2 100644 --- a/debian/copyright +++ b/debian/copyright @@ -30,6 +30,9 @@ Files: debian/sqlite3_analyzer.1 Copyright: 2018 Yuriy M. Kaminskiy Aq [email protected] License: public-domain +Files: debian/sqlite3_rsync.1 +Copyright: 2026 Job Snijders Aq [email protected] +License: public-domain Files: debian/patches/* Copyright: D. Richard Hipp <[email protected]> diff --git a/debian/rules b/debian/rules index ac29947..1690fa9 100755 --- a/debian/rules +++ b/debian/rules @@ -87,7 +87,7 @@ build-stamp: configure $(MAKE) lemon ifeq (,$(findstring $(DEB_BUILD_ARCH_OS),kfreebsd)) # build tools - $(MAKE) showdb showjournal showstat4 showwal sqldiff sqlite3_analyzer + $(MAKE) showdb showjournal showstat4 showwal sqldiff sqlite3_analyzer sqlite3_rsync endif cd ext/misc && $(CC) $(LDFLAGS) $(CPPFLAGS) $(CFLAGS) -g -fPIC -I../.. -shared csv.c -o csv.so cd ext/icu && $(CC) $(LDFLAGS) $(CPPFLAGS) $(CFLAGS) -g -fPIC -I../.. -I../../src -shared icu.c $(shell $(PKG_CONFIG) --libs --cflags icu-uc icu-io) -o icu.so @@ -116,7 +116,7 @@ install: build install -m 0664 tool/lempar.c $(DESTDIR)/usr/share/lemon/ ifeq (,$(findstring $(DEB_BUILD_ARCH_OS),kfreebsd)) install -m 0775 showdb showjournal showstat4 showwal \ - sqldiff sqlite3_analyzer \ + sqldiff sqlite3_analyzer sqlite3_rsync \ $(DESTDIR)/usr/bin/ endif install -m 0775 lemon $(DESTDIR)/usr/bin/ diff --git a/debian/sqlite3-tools.install b/debian/sqlite3-tools.install index e3f5d9c..029b8bd 100644 --- a/debian/sqlite3-tools.install +++ b/debian/sqlite3-tools.install @@ -4,3 +4,4 @@ usr/bin/showstat4 usr/bin/showwal usr/bin/sqldiff usr/bin/sqlite3_analyzer +usr/bin/sqlite3_rsync diff --git a/debian/sqlite3-tools.manpages b/debian/sqlite3-tools.manpages index c710fb8..ae9adbc 100644 --- a/debian/sqlite3-tools.manpages +++ b/debian/sqlite3-tools.manpages @@ -1,2 +1,3 @@ debian/sqlite3_analyzer.1 +debian/sqlite3_rsync.1 debian/sqldiff.1 diff --git a/debian/sqlite3_rsync.1 b/debian/sqlite3_rsync.1 new file mode 100644 index 0000000..88b024d --- /dev/null +++ b/debian/sqlite3_rsync.1 @@ -0,0 +1,123 @@ +.Dd 2026-08-24 +.Dt SQLITE3_RSYNC 1 +.Os "Debian GNU/Linux" +.Sh NAME +.Nm sqlite3_rsync +.Nd SQLite3 database remote-copy tool +.Sh SYNOPSIS +.Nm +.Ar ORIGIN +.Ar REPLICA +.Op Fl -exe Ar PATH +.Op Fl -help +.Op Fl p|--port Ar PORT +.Op Fl -protocol Ar N +.Op Fl -ssh Ar PATH +.Op Fl v +.Op Fl -version +.Op Fl -wal-only +.Sh DESCRIPTION +.Nm +makes +.Ar REPLICA +into a copy of +.Ar ORIGIN . +If +.Ar REPLICA +does not already exist, it is created. +.Pp +One of +.Ar ORIGIN +or +.Ar REPLICA +is a pathname to a database on the local machine and the other is of the form +.Dq USER@HOST:PATH +describing a database on a remote machine. +At least one of +.Ar ORIGIN +or +.Ar REPLICA +must be on the local machine. +It is not required that one of +.Ar ORIGIN +or +.Ar REPLICA +be remote, local copy works fine too. +.Pp +The synchronization uses a bandwidth-efficient protocol, similar to +.Xr rsync 1 +(from which its name is derived). +The +.Xr ssh 1 +program is used for communication, so +.Dq USER@HOST +may be an SSH alias. +.Pp +Both databases may be +.Dq live +while this utility is running. +Other programs can have active connections to the databases on either end while this utility is running. +Other programs can write to +.Ar ORIGIN +and can read from +.Ar REPLICA +while this utility runs. +.Pp +.Ar REPLICA +becomes a copy of a snapshot of +.Ar ORIGIN +as it existed when the +.Nm +command started. +If other processes change the content of +.Ar ORIGIN +while this command is running, those changes will be applied to +.Ar ORIGIN , +but they are not transferred to +.Ar REPLICA . +Thus, +.Ar REPLICA +ends up as a fully-consistent snapshot of +.Ar ORIGIN +at an instant in time. +.Pp +See +.Lk https://sqlite.org/rsync.html +for a more detailed description. +.Sh OPTIONS +.Bl -tag -width indent +.It Fl -exe Ar PATH +Name of the +.Nm +program on the remote side. +.It Fl -help +Show help screen. +.It Fl p|--port Ar PORT +Run SSH over TCP port +.Ar PORT +instead of the default 22. +.It Fl -protocol Ar N +Use sync protocol version +.Ar N . +.It Fl -ssh Ar PATH +Name of the SSH program used to reach the remote side. +.It Fl v +Verbose. +Specify +.Fl v +multiple times for increasing output. +.It Fl -version +Show detailed version information. +.It Fl -wal-only +Do not sync unless both databases are in +.Em WAL +mode. +.El +.Sh AUTHOR +.Nm +has been written by +.An D. Richard Hipp Aq [email protected] . +.Pp +This manual page was written by +.An Job Snijders Aq [email protected] +for the Debian GNU/Linux system.

