Add --includes and --include-dir to dpnp CLI#2916
Conversation
|
View rendered docs @ https://intelpython.github.io/dpnp/pull/2916/index.html |
|
Array API standard conformance tests for dpnp=0.21.0dev0=py313h509198e_55 ran successfully. |
antonwolfy
left a comment
There was a problem hiding this comment.
The only concern is about documentation, but can be covered separately
|
|
||
| These options are useful when building pybind11 extensions that use | ||
| ``dpnp4pybind11.hpp`` or libtensor kernel headers. | ||
|
|
There was a problem hiding this comment.
might be helpful to add an examples:
For example, to compile a C++ extension using dpnp header using the Intel(R) oneAPI DPC++ compiler:
.. code-block:: bash
icpx -fsycl myextension.cpp $(python -m dpnp --includes) -o myextension.soNot sure if that works this way, based on docs/doc_sources/api_reference/dpctl_pybind11.rst from dpctl.
There was a problem hiding this comment.
we should at least get something to work and then add it as an example.
In theory, the above should work, we just need an extension to test with
There was a problem hiding this comment.
@ndgrigorian @antonwolfy
I think it would be better to do this in PR that adds examples to dpnp
This PR adds
--includesand--include-diroptions todpnpCLI (python -m dpnp)These options return the path to
dpnp/backendinclude directory containingdpnp4pybind11.hpp