commit 46fdee0b1b5a7bb0a183d7ba850521a0a333fa74 truex <truex@equwal.com> 2026-09-26 19:13:24 -0700 Compile the speech library without the compiler version line, and set the version to 0.2.2 The clang of the Windows NDK adds its own version line to the .comment section, and the clang of the Linux NDK does not, so the F-Droid build of the library would differ from the signed APK. With -fno-ident, the Windows and Linux builds are the same (checked on SubRead, which has the same build).
app/build.gradle.kts | 4 ++-- app/src/main/cpp/CMakeLists.txt | 5 ++++- fastlane/metadata/android/en-US/changelogs/5.txt | 1 + fdroid/com.honjimaku.subrep.yml | 10 +++++----- 4 files changed, 12 insertions(+), 8 deletions(-)
diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 1244b74..536e4aa 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -25,8 +25,8 @@ android { // The sound of other apps can be captured from Android 10 (API 29). Older devices get the microphone. minSdk = 26 targetSdk = 36 - versionCode = 4 - versionName = "0.2.1" + versionCode = 5 + versionName = "0.2.2" // Each phone worth running Whisper on is 64-bit ARM; the speech library is built for // ARMv8.2 (see src/main/cpp/CMakeLists.txt). diff --git a/app/src/main/cpp/CMakeLists.txt b/app/src/main/cpp/CMakeLists.txt index 9a2c6c9..0b0257e 100644 --- a/app/src/main/cpp/CMakeLists.txt +++ b/app/src/main/cpp/CMakeLists.txt @@ -15,13 +15,16 @@ set(WHISPER_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../../../third_party/whisper.cpp) # Reproducible build: F-Droid builds this library again, on Linux and at another # path, and compares it with the signed APK. The maps remove the paths of the # build machine from the __FILE__ strings of ggml. -ffile-reproducible writes "/" -# in them on Windows too. An empty GIT_EXE stops ggml from recording the git state +# in them on Windows too. -fno-ident keeps the version line of the compiler out of +# the .comment section: the clang of the Windows NDK writes another line than the +# clang of the Linux NDK. An empty GIT_EXE stops ggml from recording the git state # of the checkout, which the F-Droid scanner changes. get_filename_component(SUBREP_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/../../../.." ABSOLUTE) get_filename_component(SUBREP_TOOLCHAIN_BIN "${CMAKE_C_COMPILER}" DIRECTORY) get_filename_component(SUBREP_TOOLCHAIN_ROOT "${SUBREP_TOOLCHAIN_BIN}" DIRECTORY) add_compile_options( -ffile-reproducible + -fno-ident "-ffile-prefix-map=${SUBREP_ROOT}=." "-ffile-prefix-map=${SUBREP_TOOLCHAIN_ROOT}=toolchain") set(GIT_EXE "" CACHE FILEPATH "Not used: the build records no git state" FORCE) diff --git a/fastlane/metadata/android/en-US/changelogs/5.txt b/fastlane/metadata/android/en-US/changelogs/5.txt new file mode 100644 index 0000000..6d00846 --- /dev/null +++ b/fastlane/metadata/android/en-US/changelogs/5.txt @@ -0,0 +1 @@ +The speech library no longer holds the version line of the compiler, so the F-Droid build is the same as the signed APK on GitHub. Nothing else changes. diff --git a/fdroid/com.honjimaku.subrep.yml b/fdroid/com.honjimaku.subrep.yml index 1f66d3d..72db223 100644 --- a/fdroid/com.honjimaku.subrep.yml +++ b/fdroid/com.honjimaku.subrep.yml @@ -20,9 +20,9 @@ Repo: https://github.com/equwal/subrep-android.git Binaries: https://github.com/equwal/subrep-android/releases/download/v%v/Subrep-%v.apk Builds: - - versionName: 0.2.1 - versionCode: 4 - commit: v0.2.1 + - versionName: 0.2.2 + versionCode: 5 + commit: v0.2.2 subdir: app submodules: true sudo: @@ -40,5 +40,5 @@ AllowedAPKSigningKeys: 1850490335e34b5a8edc9054125f2fb276afa2905755f4cf390b02973 AutoUpdateMode: Version UpdateCheckMode: Tags -CurrentVersion: 0.2.1 -CurrentVersionCode: 4 \ No newline at end of file +CurrentVersion: 0.2.2 +CurrentVersionCode: 5