Skip to content

Commit

Permalink
chore: Attempt to make reproducible builds
Browse files Browse the repository at this point in the history
Rustc still does not have complete support for fully reproducible builds
(rust-lang/rust#75362). Attempt to narrow the
gap by following the advice from
(rust-lang/rust#102299) and overwrite all
panic paths with a different, consistent value.
  • Loading branch information
Leander Beernaert committed May 21, 2023
1 parent b42b5fd commit 6f9743d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
11 changes: 9 additions & 2 deletions you-have-mail-android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ android {
applicationId "dev.lbeernaert.youhavemail"
minSdk 29
targetSdk 33
versionCode 19
versionName "0.7.1"
versionCode 20
versionName "0.7.2"

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables {
Expand Down Expand Up @@ -89,6 +89,13 @@ cargo {
/*features {
defaultAnd("null_backend")
}*/

// Ensure paths are consistent for reproducible builds.
exec { spec, _ ->
var home = "$System.env.HOME"
var pwd = "$System.env.PWD"
spec.environment("RUSTFLAGS", "--remap-path-prefix=${home}=/remap-home --remap-path-prefix=${pwd}=/remap-pwd")
}
}

tasks.whenTaskAdded { task ->
Expand Down
2 changes: 1 addition & 1 deletion you-have-mail-common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ secrecy = "0.8"
crossbeam-channel = "0.5"

[dependencies.proton-api-rs]
version = "0.8.0"
version = "0.8.1"
optional = true
features = ["http-ureq"]

Expand Down

0 comments on commit 6f9743d

Please sign in to comment.