Mingw cross compilation improvements#493
Conversation
|
If this was a PR against trunk, I would merge it in confidence (I looked at it and it seemed fine). I won't merge last-minute changes in 4.03 without @damiendoligez's review. |
|
Looks good. @adrien-n Do you have a document somewhere that summarizes how you do cross-compilation? |
…ments Mingw cross compilation improvements
|
Thanks! I don't have a document, yet. I've been working on a large batch of changes in win-builds and I'm not finished with it yet. There isn't much magic anymore exccept that I use a linux ocamlrun to run an ocamlc that got cross-compiled. That wasn't really planned and I think I got to that point by pure luck when updating my previous patchset to trunk in January. It just happened to work. As far as I understand, it's the same as for other platforms now but yes, it also works for Windows and can create .opt binaries even though I haven't tried using them. |
These two patches fix "regressions" for my use-case of cross-compilers to mingw-w64. They've been introduced less than two months ago.
First patch de-duplicates otherlibs/win32unix/Makefile{.nt,}; a duplication for which I was probably to blame in the first place.
Second patch ensures ".so" doesn't get hard-coded in the ocamlmklib configuration at compile-time.
PS: I use these on top of the changes mentionned in http://caml.inria.fr/mantis/view.php?id=7122 , http://caml.inria.fr/mantis/view.php?id=7121 and skipping the installation of ocamlyacc and ocamlrun when building the cross-compiler; the sum of all these and a bit of findlib config is all that is needed nowadays.