# Volunteers to review the relocatable-OCaml work?

**URL:** <https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667>\
**Category:** Community\
**Tags:** reproducible, compiler\
**Created:** [May 17, 2025, 3:30pm UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667 "2025-05-17T15:30:22Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![gasche](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/gasche/32/4_2.png) [@gasche](https://discuss.ocaml.org/u/gasche)\
**Post date:** [May 17, 2025, 3:30pm UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/1 "2025-05-17T15:30:22Z")

</div>

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](https://discuss.ocaml.org/t/relocatable-compiler-work/11218).

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](https://github.com/ocaml/RFCs/pull/53) that describes the design, and we got [a first PR](https://github.com/ocaml/ocaml/pull/14014) 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](https://github.com/ocaml/ocaml/pull/13728) (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.

---

<div class="post-metadata">

**Author:** ![dra27](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/dra27/32/5294_2.png) [@dra27](https://discuss.ocaml.org/u/dra27)\
**Post date:** [May 17, 2025, 4:58pm UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/2 "2025-05-17T16:58:52Z")

</div>

> [@gasche](#):
>
> has been working for a few years now on making the OCaml compiler relocatable.

Just to make it sound a little less Herculean, I haven’t been working _solidly_ on it 😊 There were a few OCaml 5.0 and Windows opam 2.2-shaped diversions on the way…

In addition to the already opened test harness, there’s a draft (with explanatory text) of the first of the main PRs at [Relocatable OCaml - explicit-relative paths in `ld.conf` by dra27 · Pull Request #183 · dra27/ocaml · GitHub](https://github.com/dra27/ocaml/pull/183) and a draft of the second ( ~~currently without~~ _now with_ explanatory text ~~although that will be there by next week~~ ) at [Relocatable OCaml - `--with-relative-libdir` by dra27 · Pull Request #162 · dra27/ocaml · GitHub](https://github.com/dra27/ocaml/pull/162). The third is still awaiting a small amount of tidying (which will hopefully also be done by the end of next week 🥵)

---

<div class="post-metadata">

**Author:** ![kit-ty-kate](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/kit-ty-kate/32/5953_2.png) [@kit-ty-kate](https://discuss.ocaml.org/u/kit-ty-kate)\
**Post date:** [May 19, 2025, 6:51pm UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/3 "2025-05-19T18:51:01Z")

</div>

Do you have the list of PRs that need some help? Is it just [#14014](https://github.com/ocaml/ocaml/pull/14014) or is there more?

I think it might help if the PRs were labeled with either something like `external help wanted` or `relocatable` (similar to the `multicore` label)

---

<div class="post-metadata">

**Author:** ![gasche](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/gasche/32/4_2.png) [@gasche](https://discuss.ocaml.org/u/gasche)\
**Post date:** [May 20, 2025, 10:39am UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/4 "2025-05-20T10:39:53Z")

</div>

Just this one… for now!

> [@kit-ty-kate](#):
>
> I think it might help if the PRs were labeled with either something like `external help wanted` or `relocatable`

Wish granted: [Issues · ocaml/ocaml · GitHub](https://github.com/ocaml/ocaml/labels/relocatable)

---

<div class="post-metadata">

**Author:** ![otini](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/otini/32/3533_2.png) [@otini](https://discuss.ocaml.org/u/otini)\
**Post date:** [May 20, 2025, 1:40pm UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/5 "2025-05-20T13:40:19Z")

</div>

FYI I’ve just started looking at #14014 today myself.

---

<div class="post-metadata">

**Author:** ![jbeckford](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/jbeckford/32/3027_2.png) [@jbeckford](https://discuss.ocaml.org/u/jbeckford)\
**Post date:** [May 21, 2025, 7:15pm UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/6 "2025-05-21T19:15:34Z")

</div>

I can help in a couple weeks if there are reviews still pending. At least on code that hasn’t changed much since OCaml 4 (ie. bytecode, runtime).

---

<div class="post-metadata">

**Author:** ![gasche](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/gasche/32/4_2.png) [@gasche](https://discuss.ocaml.org/u/gasche)\
**Post date:** [September 15, 2025, 4:36am UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/7 "2025-09-15T04:36:14Z")

</div>

Note: @dra27 just announced that the rest of the Relocatable work is now available ( [Relocatable OCaml](https://discuss.ocaml.org/t/relocatable-ocaml/17253) ), and in particular there are several new PRs on the OCaml compiler:

> [@Relocatable OCaml](https://discuss.ocaml.org/t/relocatable-ocaml/17253/1):
>
> ([ocaml/ocaml#14243](https://github.com/ocaml/ocaml/pull/14243), [ocaml/ocaml#14244](https://github.com/ocaml/ocaml/pull/14244), [ocaml/ocaml#14245](https://github.com/ocaml/ocaml/pull/14245) and [ocaml/ocaml#14246](https://github.com/ocaml/ocaml/pull/14246))

As before, help reviewing this work is warmly welcome.

---

<div class="post-metadata">

**Author:** ![giltho](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/giltho/32/3521_2.png) [@giltho](https://discuss.ocaml.org/u/giltho)\
**Post date:** [September 25, 2025, 3:02pm UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/8 "2025-09-25T15:02:39Z")

</div>

Has anyone volunteered yet? I’m a bit stuck before PLDI, but I’d be up to help after that. I’ll still have somewhat limited time, but I could review one of them and see how it goes

---

<div class="post-metadata">

**Author:** ![shonfeder](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/shonfeder/32/424_2.png) [@shonfeder](https://discuss.ocaml.org/u/shonfeder)\
**Post date:** [September 25, 2025, 5:03pm UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/9 "2025-09-25T17:03:43Z")

</div>

The PRs have no review feedback yet, so apparently not 😃

---

<div class="post-metadata">

**Author:** ![dra27](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/dra27/32/5294_2.png) [@dra27](https://discuss.ocaml.org/u/dra27)\
**Post date:** [December 12, 2025, 7:33am UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/11 "2025-12-12T07:33:55Z")

</div>

I’m very happy to say that the last PR has just been merged!

> <https://github.com/ocaml/ocaml/commit/7e71861a1ac1ea472104f40168f42133da02096c>

Many thanks to @jbeckford, @Rucikir, @damiendoligez, @hhugo, @shym and @vlaviron for reviewing, and to @octachron, @gasche and @nojb for merging - they, and all the other OCaml core devs, will be relieved to know that there will now be no further updates on Relocatable OCaml in future core dev meetings😊

---

<div class="post-metadata">

**Author:** ![gasche](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/gasche/32/4_2.png) [@gasche](https://discuss.ocaml.org/u/gasche)\
**Post date:** [December 12, 2025, 8:14am UTC](https://discuss.ocaml.org/t/volunteers-to-review-the-relocatable-ocaml-work/16667/12 "2025-12-12T08:14:39Z")

</div>

As someone who is really happy to have a relocatable but wasn’t available to help along, I’m also grateful for the help we received moving things along. (In particular I felt that the reviews of @shym were outstanding, and I was impressed that @jbeckford would jump in the middle of arcane compiler details just to help.)
