rules_graalvm icon indicating copy to clipboard operation
rules_graalvm copied to clipboard

Shared libraries with C/C++ targets

Open sgammon opened this issue 7 months ago • 2 comments

When building a Native Image as a shared library, users will want to make use of those outputs downstream, most obviously in cc_* targets.

The following would be great:

// imports...

native_image(
  name = "my-image",
  shared_library = True,
  // ...
)

cc_binary(
  name = "some-binary",
  deps = [
    ":my-image",
    // ...
  ],
  // ...
)

# bazel build //:some-binary

To support this, we'll need to ship providers with Native Image targets that build shared libraries, so that downstream rules can resolve the generated library and headers.

sgammon avatar Jan 02 '24 23:01 sgammon