I work on a u 18.04 and a third party tool (pymesh) that I use needs to include Python.h
I installed python-dev, python3-dev, libpython-dev and libpython3-dev.
Python.h is found in the folders: /usr/include/Python/, /usr/include/Python3.6m/ and /usr/include/Python3.6/.
Still when I try to compile a minimal C-program:
#include<Python.h>
int main(){}
I get the error:
$ gcc test.c
test.c:1:9: fatal error: Python.h: No such file or directory
#include<Python.h>
^~~~~~~~~~
compilation terminated.
I can fix this by making symbolic links to every header in one of those directories in, e.g., /usr/local/include/ or by specifying the path in the #include statement, but is that the correct way of doing it?
#include <Python/Python.h>similar to how you would#include <alsa/asoundlib.h>it's fine