Skip to content

Tests fail to find Python.h #272

Description

@yurivict

First it failed like this:

In file included from /usr/local/include/pybind11/pytypes.h:12:
/usr/local/include/pybind11/detail/common.h:186:10: fatal error: 'Python.h' file not found
#include <Python.h>
         ^~~~~~~~~~

then it failed like this:

In file included from /usr/local/include/xtensor-python/pytensor.hpp:22:
/usr/local/include/xtensor-python/pycontainer.hpp:30:10: fatal error: 'numpy/arrayobject.h' file not found
#include "numpy/arrayobject.h"
         ^~~~~~~~~~~~~~~~~~~~~

I had to add these arguments to fix these failures:

CXXFLAGS=-I${PYTHON_INCLUDEDIR} -I${PYTHON_SITELIBDIR}/numpy/core/include

It should find relevant headers by itself.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions