Dune comes with a library to query OS-specific information, called configurator. It is able to evaluate C expressions and turn them into OCaml value. Surprisingly, it even works when compiling for a different architecture. How can it do that? A CD-ROM problem Let’s take an old school example: suppose we want to eject a CD-ROM drive. On Linux, the way to do that is to open the device file such as /