HomePhabricator

[electrum] Progress on AppImage reproducibility

Description

[electrum] Progress on AppImage reproducibility

Summary:

Linux build: Enforce no debug symbols (-g0) when compiling with pip

This commit restores determinism to the AppImage build.

Adding -g0 to CFLAGS disables debug symbols, which will prevent
mktemp()-generated tmp paths from making their way into any .so
files that a python package may compile via pip (which ended up
making the AppImage build non-deterministic).

build: Fix AppImage reproducibility by using rusts trim-paths

This also uses a patched version of cryptography that passes
-fmacro-prefix-map to the compiler.

This is a backport of electroncash#2816 and https://github.com/EchterAgo/Electron-Cash/commit/9457d2ab92b7cde19e98e75147f29572a978f983

Note that for Electrum ABC there is still an issue with reproducibility after this, so more work is needed.

Depends on D15871

Test Plan: build the appimage, test it

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D15872

Details

Provenance
EchterAgoAuthored on Mar 22 2024, 12:00
PiRKCommitted on Apr 3 2024, 14:36
PiRKPushed on Apr 3 2024, 14:36
Reviewer
Restricted Project
Differential Revision
D15872: [electrum] Progress on AppImage reproducibility
Parents
rABCf0d661a5be7e: [electrum] Use native architecture when building on macos
Branches
Unknown
Tags
Unknown