-
Notifications
You must be signed in to change notification settings - Fork 409
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
reproducible builds: filesystem readdir order #9794
reproducible builds: filesystem readdir order #9794
Comments
Hi, |
I had a look at the build instructions. This part does not look right:
The first command will create If I understand correctly, you're installing (in the light of that, #9507 didn't really have to be fixed in terms of reproducibility, but it's still valuable to remove this code path) |
I saw
so the final binary gets written there by I also tried -ln -sv ../_boot/dune.exe .bin/dune
+ln -sv ../_build/default/bin/dune.exe .bin/dune and it did not help with the original issue.
|
Fixes ocaml#9794 `_boot/dune.exe` is installed, so it needs to be reproducible. This change ensures that the source files are scanned in an order that is independent from the underlying directory entries. This has been tested with `disorderfs --shuffle-dirents=yes`: two runs of `make bootstrap` create the same binary. Signed-off-by: Etienne Millon <me@emillon.org>
Fixes ocaml#9794 `_boot/dune.exe` is installed, so it needs to be reproducible. This change ensures that the source files are scanned in an order that is independent from the underlying directory entries. This has been tested with `disorderfs --shuffle-dirents=yes`: two runs of `make bootstrap` create the same binary. Signed-off-by: Etienne Millon <me@emillon.org>
Sorry, I was confused about our bootstrap process. It's indeed intended that |
Fixes #9794 `_boot/dune.exe` is installed, so it needs to be reproducible. This change ensures that the source files are scanned in an order that is independent from the underlying directory entries. This has been tested with `disorderfs --shuffle-dirents=yes`: two runs of `make bootstrap` create the same binary. Signed-off-by: Etienne Millon <me@emillon.org>
Fixes ocaml#9794 `_boot/dune.exe` is installed, so it needs to be reproducible. This change ensures that the source files are scanned in an order that is independent from the underlying directory entries. This has been tested with `disorderfs --shuffle-dirents=yes`: two runs of `make bootstrap` create the same binary. Signed-off-by: Etienne Millon <me@emillon.org>
Fixes #9794 `_boot/dune.exe` is installed, so it needs to be reproducible. This change ensures that the source files are scanned in an order that is independent from the underlying directory entries. This has been tested with `disorderfs --shuffle-dirents=yes`: two runs of `make bootstrap` create the same binary. Signed-off-by: Etienne Millon <me@emillon.org>
CHANGES: - Fix performance regression for incremental builds (ocaml/dune#9769, fixes ocaml/dune#9738, @rgrinberg) - Fix `dune ocaml top-module` to correctly handle absolute paths. (ocaml/dune#8249, fixes ocaml/dune#7370, @Alizter) - subst: ignore broken symlinks when looking at source files (ocaml/dune#9810, fixes ocaml/dune#9593, @emillon) - subst: do not fail on 32-bit systems when large files are encountered. Just log a warning in this case. (ocaml/dune#9811, fixes ocaml/dune#9538, @emillon) - boot: sort directory entries in readdir. This makes the dune binary reproducible in terms of filesystem order. (ocaml/dune#9861, fixes ocaml/dune#9794, @emillon)
CHANGES: - Fix performance regression for incremental builds (ocaml/dune#9769, fixes ocaml/dune#9738, @rgrinberg) - Fix `dune ocaml top-module` to correctly handle absolute paths. (ocaml/dune#8249, fixes ocaml/dune#7370, @Alizter) - subst: ignore broken symlinks when looking at source files (ocaml/dune#9810, fixes ocaml/dune#9593, @emillon) - subst: do not fail on 32-bit systems when large files are encountered. Just log a warning in this case. (ocaml/dune#9811, fixes ocaml/dune#9538, @emillon) - boot: sort directory entries in readdir. This makes the dune binary reproducible in terms of filesystem order. (ocaml/dune#9861, fixes ocaml/dune#9794, @emillon)
While working on reproducible builds for openSUSE, I found that our ocaml-dune package varies through non-determinism from filesystem readdir order.
Expected Behavior
dune build should be reproducible
Actual Behavior
Maybe related: ocaml-dune-3.12.2/_boot/source_files produced by
./.duneboot.exe --verbose
also has order variations.Reproduction
build on two different filesystems or use disorderfs or randomize readdir order
Specifications
dune
(output ofdune --version
): ocaml-dune-3.12.2 with boot: remove single-command bootstrap #9735ocaml
(output ofocamlc --version
) ocaml-4.14.1The text was updated successfully, but these errors were encountered: