Closed SonNNguyen closed 1 year ago
I have seen this error in the past, I don't recall the exact conditions, but I think it means something is missing. The missing piece belongs to the libonvif python module, and may be the libxml2-dev installation. You could try the installation from source in verbose mode and see if you get a more descriptive error message.
sudo apt install git cmake g++ python3-pip libxml2-dev libavdevice-dev libsdl2-dev '^libxcb.*-dev' libxkbcommon-x11-dev
sudo apt install virtualenv
virtualenv myenv
source myenv/bin/activate
git clone --recursive https://github.com/sr99622/libonvif
cd libonvif/libonvif
pip install -v .
cd ../libavio
pip install -v .
cd ../onvif-gui
pip install -v .
@sr99622 Thank you for your reply this is what I got!
But I checked on several cases regarding of the import of cmake (install via pip) on internet but no found solution. Do you have any recommendation? I did try re-install things multiple times. and the import of cmake is ok if I do it separately
Building wheels for collected packages: libonvif
Running command Building wheel for libonvif (pyproject.toml)
running bdist_wheel
running build
running build_py
running egg_info
writing libonvif.egg-info/PKG-INFO
writing dependency_links to libonvif.egg-info/dependency_links.txt
writing top-level names to libonvif.egg-info/top_level.txt
reading manifest file 'libonvif.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
adding license file 'LICENSE'
writing manifest file 'libonvif.egg-info/SOURCES.txt'
running build_ext
Traceback (most recent call last):
File "/home/doctorson/Desktop/Code/source/libonvif/.env/bin/cmake", line 5, in <module>
from cmake import cmake
ModuleNotFoundError: No module named 'cmake'
Traceback (most recent call last):
File "/home/doctorson/Desktop/Code/source/libonvif/.env/bin/cmake", line 5, in <module>
from cmake import cmake
ModuleNotFoundError: No module named 'cmake'
@sr99622
Oh I found it. Turns out I need to set correct PATH to /usr/bin/cmake instead of the cmake installed from pip.
Hello guys, after following installation guide Ubuntu 22, I got this can you help!