rules_ocaml icon indicating copy to clipboard operation
rules_ocaml copied to clipboard

configurable defaults: linkmode, linkopts for cc_deps

Open mobileink opened this issue 4 years ago • 0 comments

Rule-specific configurable default for cc_deps just allows designation of a lib to link, e.g.

--@ocaml//executable:cc_deps=@foo//bar:baz # add cc lib dep to to all ocaml_executable targets

Problem: how to specify linkmode (static/shared) and linkopts (e.g. linkall) for such deps. Adding additional config defaults e.g. @ocaml//executable:cc_linkmode etc. only partially solves the problem, since cc_deps could involve multiple libs. That is, the label could refer to a library of multiple libs, each of which might need its own linkmode and opts.

mobileink avatar Jan 04 '21 13:01 mobileink