aboutsummaryrefslogtreecommitdiff
path: root/metadata/reproducible-builds.md
diff options
context:
space:
mode:
authorLena <lena@omega>2026-01-01 00:00:00 +0000
committerLena <lena@omega>2026-01-01 00:00:00 +0000
commit7e04941bccb2683f8a6e3ee38a99c50129234dd1 (patch)
tree471227fa437291e7a6b499e3de6c106c54eaf311 /metadata/reproducible-builds.md
downloadrsend-7e04941bccb2683f8a6e3ee38a99c50129234dd1.tar.gz
rsend: push phone folders to a home SSH host over rsync
A small Android app for one-way folder backup, a KISS alternative to Syncthing. It bundles rsync (built from pinned source via the NDK) and a pure-Go SSH transport, both shipped in the APK as lib*.so and run from the native library directory. rsend pins the host key, stores the ed25519 identity Keystore-encrypted, pushes each folder additively or as a mirror, and runs on demand or on a WiFi-only schedule. The build is self-contained and reproducible: make setup provisions the toolchain, make builds rsync, rsh, and the APK.
Diffstat (limited to 'metadata/reproducible-builds.md')
-rw-r--r--metadata/reproducible-builds.md46
1 files changed, 46 insertions, 0 deletions
diff --git a/metadata/reproducible-builds.md b/metadata/reproducible-builds.md
new file mode 100644
index 0000000..9830957
--- /dev/null
+++ b/metadata/reproducible-builds.md
@@ -0,0 +1,46 @@
+rsend reproducible builds
+=========================
+How rsend stays reproducible and what F-Droid needs to build it.
+
+
+Pinning
+-------
+Every tool and source version lives in ./versions: the rsync source and its
+sha256, the Go version, the Android NDK, SDK platform, build-tools, Gradle, the
+Android Gradle Plugin, and Kotlin. The build never floats a version.
+
+
+Determinism
+-----------
+- rsh (Go): built with the NDK clang, -trimpath, -ldflags "-s -w -buildid=",
+ and CGO_CFLAGS=-ffile-prefix-map to drop build paths.
+- rsync (C): cross-compiled with -ffile-prefix-map and stripped; optional
+ dependencies are disabled and zlib and popt come from rsync's bundled copies,
+ so the binary needs nothing outside Bionic.
+- APK: no code shrinking (minifyEnabled false), the Google dependency-metadata
+ block is dropped (dependenciesInfo off), and native libs use legacy packaging.
+
+Verify locally by building twice and diffing the native libs:
+
+ make verify-repro
+
+
+F-Droid
+-------
+The build recipe lives in fdroiddata, not in this repo. F-Droid supplies the
+NDK named by the recipe's ndk field and exports ANDROID_NDK_HOME. It pins Go
+through the go srclib (the official Go source) and builds it with make.bash,
+and installs make and g++ for rsync. The native lib*.so are then built in the
+recipe's build step, which runs after F-Droid's source scanner and calls
+rsync/build.sh and rsh/build.sh; Gradle then assembles the APK. The release
+build is unsigned unless a local keystore.properties is present, so F-Droid
+signs the published APK with its own key.
+
+
+All-files access
+----------------
+rsend requests MANAGE_EXTERNAL_STORAGE. It is required: backup targets such as
+OEM call-recording directories and app-specific media folders live outside the
+scoped-media buckets, and rsync needs real filesystem paths rather than SAF
+content URIs. The app makes no network access other than the SSH connection to
+the host the user configures.