3 ms·
> Good luck writing Makefiles for OCaml So what's the problem exactly? https://mmottl.github.io/ocaml-makefile/ https://mmottl.github.io/ocaml-makefile/ Oh lo
by instig007 2y ago
> Good luck writing Makefiles for OCaml
So what's the problem exactly? https://mmottl.github.io/ocaml-makefile/ https://mmottl.github.io/ocaml-makefile/
Oh look, it even builds a project faster than Dune: https://discuss.ocaml.org/t/dune-build-vs-makefile/11394 https://discuss.ocaml.org/t/dune-build-vs-makefile/11394
- ReleaseCandidat 2y ago> So what's the problem exactly? They all have the samé problem: that you don't know the name (or even the number) of modules (module files) being generated without reading the source. And as a bonus every compiler uses a sligthly different naming scheme for the generated module file (this is of course no problem for OCaml ;). As an example (using Fortran). File `test.f90`: module first contains subroutine hello () end subroutine hello end module first module second contains subroutine world () end subroutine world end module second `gfortran -c test.f90` yields the following files (2 of them are modules): -rw-r--r-- 1 roland staff 221 Sep 21 19:07 first.mod -rw-r--r-- 1 roland staff 225 Sep 21 19:07 second.mod -rw-r--r-- 1 roland staff 185 Sep 21 19:07 test.f90 -rw-r--r-- 1 roland staff 672 Sep 21 19:08 test.o