pybind11_bazel icon indicating copy to clipboard operation
pybind11_bazel copied to clipboard

Looking for bazel build example for build whl

Open tz301 opened this issue 4 years ago • 3 comments

I have seen build examples with setuptools, cmake in https://pybind11.readthedocs.io/en/stable/compiling.html. Could provide a bazel build example to build usable python .whl?

tz301 avatar Jul 07 '20 06:07 tz301

Hello.

Check out this repo for an working example for bazel + pybind11 + whl

https://github.com/OpenMined/PSI/blob/master/setup.py

bcebere avatar Dec 07 '20 11:12 bcebere

@bcebere Thanks a lot! This tutorial is really helpful.

yutongs-dmai avatar Dec 30 '20 02:12 yutongs-dmai

I usually try to find good examples through githubs search-engine. As google is all about bazel (or their internal version of it), the google projects are probably good candidates to look at.

While some of them seem to get wheel-building to work more bazel-native (no setup.py), i only had success with the setup.py workaround yet. My main source in this regard was: https://github.com/google/atheris/tree/master/contrib/libprotobuf_mutator

sschnug avatar Nov 14 '22 21:11 sschnug