Hi discuss,
David @dra27 Allsopp has been working for a few years now on making the OCaml compiler relocatable.
Currently you configure the compiler to be installed at a certain path, and the resulting program and configuration depend on this path; moving the installed prefix to a different place will break various things. Having a relocatable compiler is good for Windows support, for reproducible builds, for caching, etc.
An early version of this work was presented by David at the OCaml compiler workshop 2022, and it is discuss in a past Dicuss thread.
Good news! The work is now in a good enough shape that @dra27 has started upstreaming parts of it – submitting them to the compiler distribution. There is an RFC that describes the design, and we got a first PR that is a test harness for the feature, with many more to come.
Bad news: we don’t know who would be available to review those PRs as they come. @nojb made an effort to review the test harness, but is also working on tons of other stuff (such as: trying to get stdlib contributions across the finish line). My understanding is that @Rucikir is not available to do this work. There is a risk that the work is held back due to the absence of motivated reviewers to look at it.
Would anyone around be interested in helping review this work? If so, I’m happy to post links to further PRs as they come.
In my experience, PRs by @dra27 touch a varied number of obscure topics that no one except maybe himself is an expert about – deep stuff about how the compiler work that most of us are happy to ignore because it usually stays out of the way. One typical example, I suspect, is #13728 : Add `Sys.runtime_executable` and `caml_sys_proc_self_exe (which is now merged, not looking for reviewers). If you find this PR super-obscure, welcome to the club, I don’t understand anything either. But if you also find it interesting, you may be excellent volunteer material to review more PRs on this.
Note: the contribution rules for compiler PRs is that each PR must be approved by someone with commit rights (a compiler maintainer) to get merged. By itself, an approval from another contributor does not suffice. But it is certainly possible for maintainers to give approval on behalf of another review – we do it in practice. If you review a PR (about this or anything else) and you feel confident that it is okay to merge it, please feel free to explicitly “approve” it through the github interface.