PR#6794: pass -package flags when building C files#150
Conversation
ocamlbuild/findlib.ml
Outdated
There was a problem hiding this comment.
Why are you exposing an optional argument (the optional argument itself looks rather fishy to me) if it is not used in the patch. Do you have a need for it in an external plugin?
(If so, I think that rather than an obscure API, I would prefer a locations : package list -> string list function to be exposed that allows people to implement whatever variant of include_flags without hassle.)
Note that I think naming the function "include_flags" rather than "compile_flags" is a good change.
There was a problem hiding this comment.
Why are you exposing an optional argument (the optional argument itself looks rather fishy to me) if it is not used in the patch. Do you have a need for it in an external plugin?
I can useful if you need the list of "-L" for instance. I don't mind removing it.
(If so, I think that rather than an obscure API, I would prefer a locations : package list -> string list function to be exposed that allows people to implement whatever variant of include_flags without hassle.)
Yeah I though about that. Given that the function is quite small already it didn't seem worth it to split it even more.
There was a problem hiding this comment.
I'd prefer the patch without the hard-to-document optional argument, but I have nothing against exposing a separate function for -L if that is useful.
|
Merged in 4.02 and master, thanks. |
|
@gasche Are you sure you merged in 4.02? I can't find the commit. |
|
Indeed I had forgotten it. I just committed in 4.02@15891. Thanks for double-checking! |
Co-authored-by: Thibaut <thibaut.mattio@gmail.com>
Patch for 6794.