I installed Python 3.10.11 from source on my Linux (OpenSuSE Leap 15.4 on AMD64) machine and defined a venv so that I can build an app, which requires a fresh (>= 3.8) Python version. Unfortunately, when getting wxWidgets for Python via pip, I always get an error because of a missing header file: Python.h
:
Checking for header Python.h: Distutils not installed? Broken python installation? Get python-config now!
The configuration failed
I do have Python.h
in my Python installation: /home/jacek/bin/tmp/Python-3.10.11/Include
The pyvenv.cfg
file looks like this:
home = /home/jacek/bin/tmp/Python-3.10.11/dist/bin
implementation = CPython
version_info = 3.10.11.final.0
virtualenv = 20.23.0
include-system-site-packages = false
base-prefix = /home/jacek/bin/tmp/Python-3.10.11/dist
base-exec-prefix = /home/jacek/bin/tmp/Python-3.10.11/dist
base-executable = /home/jacek/bin/tmp/Python-3.10.11/dist/bin/python3
What I can't find anywhere in the Python docs is how to state a header file folder, just something like base-include-dir
(if it exists). The pyvenv.cfg
file is situated in /home/jacek/bin/tmp/Python-3.10.11/dist/displaycal
, whereas the activate
script lies in /home/jacek/bin/tmp/Python-3.10.11/dist/displaycal/bin
(if this matters).