Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No matching distribution found for webp #24

Closed
implementosk opened this issue May 14, 2021 · 4 comments
Closed

No matching distribution found for webp #24

implementosk opened this issue May 14, 2021 · 4 comments
Labels

Comments

@implementosk
Copy link

Hi,

I have tried to install webp:
pip3 install webp

Unfortunately i receive error:
ERROR: Could not find a version that satisfies the requirement webp (from versions: 0.1.0a4, 0.1.0a5, 0.1.0a6, 0.1.0a7, 0.1.0a9, 0.1.0a10, 0.1.0a11, 0.1.0a12, 0.1.0a13, 0.1.0a14, 0.1.0a15, 0.1.0a16, 0.1.0, 0.1.1)
ERROR: No matching distribution found for webp

Full output:
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-2h0kdpgl/webp_982bcc469215407a9724d41dcda8a63b/setup.py'"'"'; file='"'"'/tmp/pip-install-2h0kdpgl/webp_982bcc469215407a9724d41dcda8a63b/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-icxt3c46
cwd: /tmp/pip-install-2h0kdpgl/webp_982bcc469215407a9724d41dcda8a63b/
Complete output (68 lines):
Configuration:
[settings]
arch=x86_64
arch_build=x86_64
build_type=Release
compiler=gcc
compiler.version=8.3
os=Linux
os_build=Linux
[options]
[build_requires]
[env]

conanfile.txt: Installing package
Requirements
libwebp/1.0.3@bincrafters/stable from 'conan-center' - Cache
Packages
libwebp/1.0.3@bincrafters/stable:4f7fdaf7ecd182f1bc32b35513734e57dafe119a - Missing

Installing (downloading, building) binaries...

ERROR: Missing binary: libwebp/1.0.3@bincrafters/stable:4f7fdaf7ecd182f1bc32b35513734e57dafe119a
libwebp/1.0.3@bincrafters/stable: WARN: Can't find a 'libwebp/1.0.3@bincrafters/stable' package for the specified settings, options and dependencies:
- Settings: arch=x86_64, build_type=Release, compiler=gcc, compiler.version=8.3, os=Linux
- Options: fPIC=True, near_lossless=True, shared=False, swap_16bit_csp=False, with_simd=True
- Dependencies:
- Requirements:
- Package ID: 4f7fdaf7ecd182f1bc32b35513734e57dafe119a

Traceback (most recent call last):
File "", line 1, in
File "/tmp/pip-install-2h0kdpgl/webp_982bcc469215407a9724d41dcda8a63b/setup.py", line 24, in
'License :: OSI Approved :: MIT License',
File "/usr/lib/python3/dist-packages/setuptools/init.py", line 145, in setup
return distutils.core.setup(**attrs)
File "/usr/lib/python3.7/distutils/core.py", line 108, in setup
_setup_distribution = dist = klass(attrs)
File "/usr/lib/python3/dist-packages/setuptools/dist.py", line 447, in init
k: v for k, v in attrs.items()
File "/usr/lib/python3.7/distutils/dist.py", line 292, in init
self.finalize_options()
File "/usr/lib/python3/dist-packages/setuptools/dist.py", line 739, in finalize_options
ep.load()(self, ep.name, value)
File "/tmp/pip-install-2h0kdpgl/webp_982bcc469215407a9724d41dcda8a63b/.eggs/cffi-1.14.5-py3.7-linux-x86_64.egg/cffi/setuptools_ext.py", line 219, in cffi_modules
add_cffi_module(dist, cffi_module)
File "/tmp/pip-install-2h0kdpgl/webp_982bcc469215407a9724d41dcda8a63b/.eggs/cffi-1.14.5-py3.7-linux-x86_64.egg/cffi/setuptools_ext.py", line 49, in add_cffi_module
execfile(build_file_name, mod_vars)
File "/tmp/pip-install-2h0kdpgl/webp_982bcc469215407a9724d41dcda8a63b/.eggs/cffi-1.14.5-py3.7-linux-x86_64.egg/cffi/setuptools_ext.py", line 25, in execfile
exec(code, glob, glob)
File "webp_build/builder.py", line 14, in
conan.install(path=getcwd(), cwd=tmp_dir)
File "/usr/local/lib/python3.7/dist-packages/conans/client/conan_api.py", line 93, in wrapper
return f(api, *args, **kwargs)
File "/usr/local/lib/python3.7/dist-packages/conans/client/conan_api.py", line 610, in install
recorder=recorder)
File "/usr/local/lib/python3.7/dist-packages/conans/client/manager.py", line 81, in deps_install
graph_lock, keep_build=keep_build)
File "/usr/local/lib/python3.7/dist-packages/conans/client/installer.py", line 314, in install
graph_lock, remotes, build_mode, update)
File "/usr/local/lib/python3.7/dist-packages/conans/client/installer.py", line 424, in _build
self._raise_missing(missing)
File "/usr/local/lib/python3.7/dist-packages/conans/client/installer.py", line 372, in _raise_missing
''' % (missing_pkgs, build_str)))
conans.errors.ConanException: Missing prebuilt package for 'libwebp/1.0.3@bincrafters/stable'
Try to build from sources with '--build=libwebp'
Use 'conan search --table table.html'
Or read 'http://docs.conan.io/en/latest/faq/troubleshooting.html#error-missing-prebuilt-package'

WARNING: Discarding https://files.pythonhosted.org/packages/62/df/1efb36189ee596f6d3773c8c1b051ada90d244a601b0e4de00181e8fa6f9/webp-0.1.0.tar.gz#sha256=9f15bf22999789b05f12dd02e0970d44adf506e086ea9558e6c5abc4c5585126 (from https://pypi.org/simple/webp/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
ERROR: Could not find a version that satisfies the requirement webp (from versions: 0.1.0a4, 0.1.0a5, 0.1.0a6, 0.1.0a7, 0.1.0a9, 0.1.0a10, 0.1.0a11, 0.1.0a12, 0.1.0a13, 0.1.0a14, 0.1.0a15, 0.1.0a16, 0.1.0, 0.1.1)
ERROR: No matching distribution found for webp

Thanks.

@anibali
Copy link
Owner

anibali commented May 14, 2021

It looks like you somehow have your compiler version stored with a minor version number included, which is apparently not Conan-friendly.

Try running the following command before installing webp:

conan profile update "settings.compiler.version=8" default

@implementosk
Copy link
Author

It looks like you somehow have your compiler version stored with a minor version number included, which is apparently not Conan-friendly.

Try running the following command before installing webp:

conan profile update "settings.compiler.version=8" default

Thanks for your answer.

After running your command, another error:
build/temp.linux-x86_64-3.7/_webp.c:50:14: fatal error: pyconfig.h: No such file or directory
# include <pyconfig.h>
^~~~~~~~~~~~
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

Full output:

Collecting webp
Using cached webp-0.1.1.tar.gz (10 kB)
Requirement already satisfied: Pillow>=4.0.0 in /usr/local/lib/python3.7/dist-packages (from webp) (8.2.0)
Requirement already satisfied: cffi>=1.0.0 in /usr/local/lib/python3.7/dist-packages (from webp) (1.14.5)
Requirement already satisfied: numpy>=1.0.0 in /usr/local/lib/python3.7/dist-packages (from webp) (1.20.2)
Requirement already satisfied: pycparser in /usr/local/lib/python3.7/dist-packages (from cffi>=1.0.0->webp) (2.20)
Building wheels for collected packages: webp
Building wheel for webp (setup.py) ... error
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-pnp37dq4/webp_25381749d1e7439cbda1a076dd81fbfd/setup.py'"'"'; file='"'"'/tmp/pip-install-pnp37dq4/webp_25381749d1e7439cbda1a076dd81fbfd/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-l1wpx2sd
cwd: /tmp/pip-install-pnp37dq4/webp_25381749d1e7439cbda1a076dd81fbfd/
Complete output (49 lines):
Configuration:
[settings]
arch=x86_64
arch_build=x86_64
build_type=Release
compiler=gcc
compiler.version=8
os=Linux
os_build=Linux
[options]
[build_requires]
[env]

conanfile.txt: Installing package
Requirements
libwebp/1.0.3@bincrafters/stable from 'conan-center' - Cache
Packages
libwebp/1.0.3@bincrafters/stable:a4d73d2d4a03abfc1a36922919556dad5ab3d20d - Cache

Installing (downloading, building) binaries...
libwebp/1.0.3@bincrafters/stable: Already installed!
conanfile.txt: Generator txt created conanbuildinfo.txt
conanfile.txt: Generator json created conanbuildinfo.json
conanfile.txt: Generated conaninfo.txt
conanfile.txt: Generated graphinfo
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.7
creating build/lib.linux-x86_64-3.7/webp
copying webp/init.py -> build/lib.linux-x86_64-3.7/webp
creating build/lib.linux-x86_64-3.7/webp_build
copying webp_build/builder.py -> build/lib.linux-x86_64-3.7/webp_build
copying webp_build/init.py -> build/lib.linux-x86_64-3.7/webp_build
copying webp_build/cdef.h -> build/lib.linux-x86_64-3.7/webp_build
copying webp_build/source.c -> build/lib.linux-x86_64-3.7/webp_build
running build_ext
generating cffi module 'build/temp.linux-x86_64-3.7/_webp.c'
creating build/temp.linux-x86_64-3.7
building '_webp' extension
creating build/temp.linux-x86_64-3.7/build
creating build/temp.linux-x86_64-3.7/build/temp.linux-x86_64-3.7
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/root/.conan/data/libwebp/1.0.3/bincrafters/stable/package/a4d73d2d4a03abfc1a36922919556dad5ab3d20d/include -I/usr/include/python3.7m -c build/temp.linux-x86_64-3.7/_webp.c -o build/temp.linux-x86_64-3.7/build/temp.linux-x86_64-3.7/_webp.o
build/temp.linux-x86_64-3.7/_webp.c:50:14: fatal error: pyconfig.h: No such file or directory

include <pyconfig.h>

            ^~~~~~~~~~~~

compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

ERROR: Failed building wheel for webp
Running setup.py clean for webp
Failed to build webp
Installing collected packages: webp
Running setup.py install for webp ... error
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-pnp37dq4/webp_25381749d1e7439cbda1a076dd81fbfd/setup.py'"'"'; file='"'"'/tmp/pip-install-pnp37dq4/webp_25381749d1e7439cbda1a076dd81fbfd/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-19d8rc4b/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.7/webp
cwd: /tmp/pip-install-pnp37dq4/webp_25381749d1e7439cbda1a076dd81fbfd/
Complete output (49 lines):
Configuration:
[settings]
arch=x86_64
arch_build=x86_64
build_type=Release
compiler=gcc
compiler.version=8
os=Linux
os_build=Linux
[options]
[build_requires]
[env]

conanfile.txt: Installing package
Requirements
    libwebp/1.0.3@bincrafters/stable from 'conan-center' - Cache
Packages
    libwebp/1.0.3@bincrafters/stable:a4d73d2d4a03abfc1a36922919556dad5ab3d20d - Cache

Installing (downloading, building) binaries...
libwebp/1.0.3@bincrafters/stable: Already installed!
conanfile.txt: Generator txt created conanbuildinfo.txt
conanfile.txt: Generator json created conanbuildinfo.json
conanfile.txt: Generated conaninfo.txt
conanfile.txt: Generated graphinfo
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.7
creating build/lib.linux-x86_64-3.7/webp
copying webp/__init__.py -> build/lib.linux-x86_64-3.7/webp
creating build/lib.linux-x86_64-3.7/webp_build
copying webp_build/builder.py -> build/lib.linux-x86_64-3.7/webp_build
copying webp_build/__init__.py -> build/lib.linux-x86_64-3.7/webp_build
copying webp_build/cdef.h -> build/lib.linux-x86_64-3.7/webp_build
copying webp_build/source.c -> build/lib.linux-x86_64-3.7/webp_build
running build_ext
generating cffi module 'build/temp.linux-x86_64-3.7/_webp.c'
creating build/temp.linux-x86_64-3.7
building '_webp' extension
creating build/temp.linux-x86_64-3.7/build
creating build/temp.linux-x86_64-3.7/build/temp.linux-x86_64-3.7
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/root/.conan/data/libwebp/1.0.3/bincrafters/stable/package/a4d73d2d4a03abfc1a36922919556dad5ab3d20d/include -I/usr/include/python3.7m -c build/temp.linux-x86_64-3.7/_webp.c -o build/temp.linux-x86_64-3.7/build/temp.linux-x86_64-3.7/_webp.o
build/temp.linux-x86_64-3.7/_webp.c:50:14: fatal error: pyconfig.h: No such file or directory
 #    include <pyconfig.h>
              ^~~~~~~~~~~~
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------

ERROR: Command errored out with exit status 1: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-pnp37dq4/webp_25381749d1e7439cbda1a076dd81fbfd/setup.py'"'"'; file='"'"'/tmp/pip-install-pnp37dq4/webp_25381749d1e7439cbda1a076dd81fbfd/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-19d8rc4b/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.7/webp Check the logs for full command output.

@anibali
Copy link
Owner

anibali commented May 17, 2021

You need the Python development headers to compile C extensions. If you are using Python as packaged in Ubuntu, I think that you can install them with

sudo apt install python3-dev

@implementosk
Copy link
Author

Successfully installed webp-0.1.1

Thanks a lot!!!

@anibali anibali closed this as completed May 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants