Installation seems to fail due to python as a normal user
I don't think I am doing something special.
While the installation returns success. the python stuff is not correctly installed.
I did reset the CMAKE_INSTALL_PREFIX to $HOME/dune_install and ran make install as a normal user:
-- Installing: /home/mblatt/dune_install/share/bash-completion/completions/dunecontrol
Installing python package (Debug)
CMake Warning at /home/mblatt/src/dune/opm-2.10/dune-common/cmake/modules/DuneExecuteProcess.cmake:76 (message):
python package installation failed - ignored
Run command:/usr/bin/cmake;--build;.;--target;install_python;--config;Debug
Return code: 2
Output:
gmake[1]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
betreten
gmake[2]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
betreten
gmake[3]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
betreten
gmake[4]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
betreten
gmake[4]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
verlassen
gmake[4]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
betreten
Installing the python package at
/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug/python/.
(location --user)
error: externally-managed-environment
× This environment is externally managed
╰─> To install Python packages system-wide, try apt install
python3-xyz, where xyz is the package you are trying to
install.
If you wish to install a non-Debian-packaged Python package,
create a virtual environment using python3 -m venv path/to/venv.
Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
sure you have python3-full installed.
If you wish to install a non-Debian packaged Python application,
it may be easiest to use pipx install xyz, which will manage a
virtual environment for you. Make sure you have pipx installed.
See /usr/share/doc/python3.11/README.venv for more information.
note: If you believe this is a mistake, please contact your Python
installation or OS distribution provider. You can override this, at the
risk of breaking your Python installation or OS, by passing
--break-system-packages.
hint: See PEP 668 for the detailed specification.
gmake[4]: ***
[python/CMakeFiles/install_python_package_017119b47aa3e31d2f1458e7ae21943a.dir/build.make:71:
python/CMakeFiles/install_python_package_017119b47aa3e31d2f1458e7ae21943a]
Fehler 1
gmake[4]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
verlassen
gmake[3]: *** [CMakeFiles/Makefile2:5414:
python/CMakeFiles/install_python_package_017119b47aa3e31d2f1458e7ae21943a.dir/all]
Fehler 2
gmake[3]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
verlassen
gmake[2]: *** [CMakeFiles/Makefile2:2040:
CMakeFiles/install_python.dir/rule] Fehler 2
gmake[2]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
verlassen
gmake[1]: *** [Makefile:621: install_python] Fehler 2
gmake[1]: Verzeichnis
„/home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug“ wird
verlassen
Call Stack (most recent call first):
python/cmake_install.cmake:55 (dune_execute_process)
cmake_install.cmake:96 (include)
Installing wheel for python package at /home/mblatt/src/dune/opm-2.10/dune-common/opm-parallel-debug/python/. into /home/mblatt/dune_install/share/dune/wheelhouse...
Interestingly the return code of the install command is 0
, like success.