Skip to content

ERL-1445: Repeated Erlang/OTP compilations from the same source directory don't produce identical build results #4417

@OTP-Maintainer

Description

@OTP-Maintainer

Original reporter: jeromedebretagne
Affected version: OTP-23.1
Component: Not Specified
Migrated from: https://bugs.erlang.org/browse/ERL-1445


+Steps to reproduce+

$ cd otp_src
 $ git checkout OTP-23.1.5
 $ export ERL_COMPILER_OPTIONS=deterministic
 $ git clean -xfdq
 $ ./otp_build autoconf
 $ ./otp_build configure
 $ make -j4
 $ make RELEASE_ROOT=/path/to/build/directory1 release

$ # from the same otp_src directory
 $ git clean -xfdq
 $ ./otp_build autoconf
 $ ./otp_build configure
 $ make -j4
 $ make RELEASE_ROOT=/path/to/build/directory2 release

Comparing the 2 buld directory outputs show differences in beam.smp, OtpErlang.jar and in a few .hrl files due to the introduction of timestamps.

Cf. the attached diff file.

 

+Expected result+

Builds should produce deterministic results.
 Cf. [https://reproducible-builds.org/] for why it matters.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions