Conversation
|
Thanks! I am not sure of the precise use-cases for it, but if it can help bootstrapping and building on Windows, it's great. There is of course still the third way, closer to |
If a bootstrap compiler is built, make lib-pkg may be run before configure to build all the required dependencies as findlib packages as an alternative to running make lib-ext after configure. The retrieval of the archives has much in common with the lib-ext method, and the two mechanisms are designed to live in harmony in the same Makefile. The patches directory is now ordered so that src_ext/patches/foo are the patches for foo when built with lib-ext (so as before) and src_ext/patches/foo.pkg are the patches for foo when built with lib-pkg. Additionally, src_ext/patches/foo.common are used with both mechanisms. The URLs and MD5 checksums have been moved to src_ext/Makefile.sources and the build instructions for each package are placed in src_ext/Makefile.packages. src_ext/Makefile has been updated to work without ../Makefile.config and Makefile cookies are used to ensure that the clone and clone-pkg targets correctly set-up the build directories. make lib-pkg supports parallel make.
Ubuntu 14.04 still ships with pre-4.0 make, which doesn't work with the lib-pkg mode.
|
That's correct - the only patches included are ones which are either upstreamed and not yet released or in the process of being upstreamed. It does indeed aim to be closer to the mode where you've used opam to install the dependencies - the difference is that The README for lib-pkg is in the temporary Windows instructions immediately after the bootstrapping instructions for getting a compiler, which I think is clear enough? I completely agree that now that we have a composable build system like Dune, there may be a magic point in the future where the |
|
Sure, just wanted to be sure I got it correctly. Thanks! |
|
PRed the mccs release to make way for this |
|
Hang on - I'll rebase with it! |
Especially as it was causing the ocaml-mccs tests to behave differently (unstable sorting).
Running cppo and mccs's testsuites otherwise!
|
Right, let's see how long CI takes! Incidentally, @AltGr, I've been going through travis-ci.org on some of mine and looking at old pull request jobs and branch jobs and killing the long (not) running macOS jobs... it's slowly helping bring down the Travis backlog! |
This is a quite old piece of my porting from when updating dependent packages frequently was quite important for Windows changes, and fighting
OCamlMakefilewas tedious. The main thing this PR adds is the ability to do a normal installation of opam's dependencies directly to the compiler built bymake compilerinbootstrap/. The advent of Jbuilder, which has been a more reliable replacement build system for lib-ext than OCamlMakefile was, has rendered this less useful than it was, but it's still quite handy.This PR also introduces an extra Travis test which essentially tests
make cold(and useslib-pkginstead oflib-ext).The
bootstrap-ocaml.shscript is tweaked to writesrc_ext/Makefile.configwhich contains the necessary information for lib-pkg to compile.src_ext/Makefileis split intosrc_ext/Makefile.sourceswhich contains the URLs and MD5s for all the tarballs andsrc_ext/Makefile.packageswhich contains the instructions needed to build each package from its sources tarball, and also the dependency graph between them.src_ext/Makefileis extended to permit alternating betweenmake lib-extandmake lib-pkgmode. Thesrc_ext/patchesdirectory is also restructured to allow for patches needed in both modes and patches needed only in one mode.There are a few other minor fixes included in this PR:
make lib-pkgassumes the package layout for the unreleased ocaml-mccs 1.1+5 (just because this has come from Windows development). It would probably be better to cut a release of ocaml-mccs before this is merged.