ocamlmklib was recently changed to fail if called with unrecognized options. This causes regressions. I wonder how to deal with those regressions.
It seems ocamlmklib tries to handle rpath linker options, and recognizes a few related -Wl options. I wonder why it does not pass everything non-rpath related -Wloption verbatim to the compiler via -ccopt. Is this done on purpose?
The code in question runs ocamlmklib $(LDFLAGS) ..., which now fails. LDFLAGS contains more than a single argument, so it would be cumbersome to split this into individual -ccopt arguments. Since the compiler did not receive the options from LDFLAGS anyway in the past, the options are apparently not relevant in this context. I may just unset LDFLAGSto workaround this single instance.
Edit: Does ocamlmklib use LDFLAGS from Makefile.confunder the hood? But, since this may come from environment as well if I interpret the used ?= correctly.