Skip to content

Specify to install libtiff-dev libpng-dev libwebp-dev before installing iio with python #22

@gardiens

Description

@gardiens

Hello,
I started a new fresh dockerfile ubuntu 22.04 and I tried to install iio with pip.
I encountered an error while trying to install iio using pip:

pip install iio
Collecting iio
Using cached iio-29.tar.gz (55 kB)
Preparing metadata (setup.py) ... done
Building wheels for collected packages: iio
Building wheel for iio (setup.py) ... error
error: subprocess-exited-with-error

× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [14 lines of output]
running bdist_wheel
running build
running build_py
creating build/lib.linux-x86_64-cpython-38
copying iio.py -> build/lib.linux-x86_64-cpython-38
running build_ext
building 'libiio' extension
creating build/temp.linux-x86_64-cpython-38/iio
gcc -pthread -B /opt/conda/envs/myenv/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iiio -I/usr/local/include -I/opt/conda/envs/myenv/include/python3.8 -c iio/iio.c -o build/temp.linux-x86_64-cpython-38/iio/iio.o -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -DI_CAN_HAS_LIBWEBP
iio/iio.c:2175:10: fatal error: webp/decode.h: No such file or directory
2175 | #include <webp/decode.h>
| ^~~~~~~~~~~~~~~
[end of output]

I fixed them by running sudo apt-get install -y libtiff-dev libpng-dev libwebp-dev . Maybe adding this command could help newcomers,
Sincerely,
Pierrick

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions