Comment corriger l'erreur CMake : wxPython/Phoenix does not appear to be installed on the system
Problème
En essayant de compiler un logiciel en utilisant CMake, vous voyez un message d’erreur tel que :
cmake_wxpython_error.txt
Traceback (most recent call last):
File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'wx'
CMake Error at cmake/FindwxPython.cmake:56 (message):
wxPython/Phoenix does not appear to be installed on the system
Call Stack (most recent call first):
CMakeLists.txt:1004 (find_package)Solution
CMake vérifie fondamentalement si vous avez le paquet Python wx installé.
Afin de l’installer, utilisez
install_wxpython.sh
pip install --user --break-system-packages wxpythonSi cela ne fonctionne pas, vérifiez si vous avez plusieurs versions de Python installées
Si cet article vous a aidé, pensez à m'offrir un café ou à faire un don via PayPal pour soutenir la recherche et la publication de nouveaux articles sur TechOverflow