Skip to content

nix: cross compile dune to windows#15285

Draft
Alizter wants to merge 4 commits into
ocaml:mainfrom
Alizter:push-uqyluvxyxzmz
Draft

nix: cross compile dune to windows#15285
Alizter wants to merge 4 commits into
ocaml:mainfrom
Alizter:push-uqyluvxyxzmz

Conversation

@Alizter

@Alizter Alizter commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

This derivation allows us to cross-compile Dune to windows using mingw. This can be used to distribute Windows binaries for https://github.com/ocaml-dune/binary-distribution/

@rgrinberg

Copy link
Copy Markdown
Member

Nice. Shall we add this to CI as well? Seems like this should be a lot faster.

Is it all possible to run our test suite with wine?

@Alizter

Alizter commented Jun 23, 2026

Copy link
Copy Markdown
Collaborator Author

Nice. Shall we add this to CI as well? Seems like this should be a lot faster.

Is it all possible to run our test suite with wine?

I can add some build jobs to CI so we can test it actually continues to work going forward however it will take more work to do something useful with the binary.

For cram tests there are different levels of integration that are possible. We could wrap each cross-windows binary with wine and run it in regular bash or run windows bash in wine together with all the windows executables that bash will exec.

The second option seems better since it will more closely match the behaviour of running tests on windows.

@Alizter Alizter force-pushed the push-uqyluvxyxzmz branch 7 times, most recently from 07381fa to 96ee50e Compare June 27, 2026 20:12
@Alizter Alizter marked this pull request as draft June 28, 2026 10:06
@Alizter Alizter added the windows Issues that relate to Dune on Microsoft Windows label Jun 28, 2026
@Alizter Alizter force-pushed the push-uqyluvxyxzmz branch 2 times, most recently from 331a43f to fe22bbb Compare June 29, 2026 08:24
Alizter added 4 commits June 29, 2026 09:26
Signed-off-by: Ali Caglayan <alizter@gmail.com>
Signed-off-by: Ali Caglayan <alizter@gmail.com>
Signed-off-by: Ali Caglayan <alizter@gmail.com>
Signed-off-by: Ali Caglayan <alizter@gmail.com>
@Alizter Alizter force-pushed the push-uqyluvxyxzmz branch from fe22bbb to bb039c5 Compare June 29, 2026 08:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

windows Issues that relate to Dune on Microsoft Windows

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants