On 15/09/2022 20:38, William Hu via Cygwin-apps wrote:
Hello,
[...]
Cygport checks one more time to make sure mldir exists in the package being built (this second check is why those errors are hard to trigger on a non-OCaml package) and then calls `find` on both ${D}${mldir} and ${mldir}. Of course, since the *real* /usr/lib/ocaml won't exist if OCaml isn't installed on your actual system when you build it, find will output an error when run on those two directories. Two ways to fix this would be to either remove the ${mldir} argument from find or test if ${mldir} exists and set it to the empty string if it doesn't. The second would likely preserve compatibility if there exist packages that depend on find searching both directories. The buggy test was added in <https://github.com/cygwin/cygport/commit/7d24eb71bdd91e2a368739728dbd522ddd4faaac>. Does anyone else have any insights or suggestions or does the above fix sound reasonable?
I think just dropping ${mldir} would prevent cygport from detecting the dependencies of an ocaml library (other ocaml libraries, or ocaml itself?), but the second alternative sounds acceptable.
Patches welcome, as always :)