Here's part of my motivation for starting this discussion now: I recently experienced a hard-drive failure and had to switch to my backup windows laptop. I was dismayed that opam is still not available for Windows, and while wodi is available, it's not nearly as well developed, and apparently requires many hacks for different packages.
It seems to me that these hacks are some of the things that make platform compatibility hard for opam. Each build system has different requirements and methods of compilation, and making this approach cross-platform compatible is difficult. Ideally, a build system will abstract away the things that are not inter-platform compatible. This is why I don't like people using makefiles. Makefiles are not available natively on Windows, and they often contain other bits of shell code that isn't available on all POSIX platforms, let alone on Windows. Not to mention the fact that makefiles have a very tricky and sensitive syntax.
I don't expect one build system to match everyone's requirements, but I think if we get together, make a list of requirements, and try to get over our personal biases, we can find something that works for most people, and with some group effort, can work for even more people in more use-cases. I'm not suggesting that we invent something new, but that we take something good and make it better, as well as make an effort to learn that tool and convert packages to use that tool.
So here are some requirements I can think of (using some of the suggestions that have been brought up):
- Easy to use, especially for small projects (large projects can afford to put more time into their build systems)
- Abstract away platform considerations as much as possible. No dependence on specific shells and POSIX utilities.
- Allows compilation of C files, which is quite common in ocaml packages.
- Scalable to many directories and files
- Uses ocamlfind to locate packages
- Handles camlp4 and ppx
- Parallel & incremental compilation
About Jenga: I took a quick look at Jenga, and even though I'm impressed by its capabilities, the amount of code needed to be written even for simple projects is overwhelming. It's clearly a very flexible and powerful tool, but I'd say it's too flexible for the mainstream. There's always room for a build system that's integrated into ocaml itself (like Shake), but I think declarative build systems tend to be easier to comprehend for the average user.
ocp-build actually looks very interesting. The manual (which is here:
http://github.com/OCamlPro/ocp-build/blob/master/docs/user-manual/user-manual.pdf?raw=true) is incomplete, but contains a nice survey of the existing build tools, and motivation for making ocp-build. Has anyone had experience with ocp-build? Opam seems to be using it, but they also use a makefile (why?) with a bunch of shell commands inside (which is precisely the problem from my perspective). ocp-build is supposedly compatible with Windows, too.
Yotam