python - 安装基于 pyproject.toml 的项目所需的错误 : Could not build wheels for coincurve,

标签 python android bit termux

在未 root 的 Samsung Galaxy s10 Android 12 上使用 Termux 安装 bit 时出错

~ $ pip3 install bit                                    Collecting bit
  Using cached bit-0.8.0-py3-none-any.whl (68 kB)
Collecting requests                                       Using cached requests-2.27.1-py2.py3-none-any.whl (63 kB)                                                     Collecting coincurve>=4.3.0
  Using cached coincurve-17.0.0.tar.gz (2.5 MB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done            Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Collecting asn1crypto
  Using cached asn1crypto-1.5.0-py2.py3-none-any.whl (105 kB)                                                   Collecting cffi>=1.3.0
  Using cached cffi-1.15.0-cp310-cp310-linux_aarch64.whlCollecting urllib3<1.27,>=1.21.1                          Using cached urllib3-1.26.8-py2.py3-none-any.whl (138 kB)
Collecting certifi>=2017.4.17
  Using cached certifi-2021.10.8-py2.py3-none-any.whl (149 kB)
Collecting charset-normalizer~=2.0.0
  Using cached charset_normalizer-2.0.12-py3-none-any.whl (39 kB)
Collecting idna<4,>=2.5
  Using cached idna-3.3-py3-none-any.whl (61 kB)
Collecting pycparser
  Using cached pycparser-2.21-py2.py3-none-any.whl (118 kB)
Building wheels for collected packages: coincurve
  Building wheel for coincurve (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for coincurve (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [64 lines of output]
      running bdist_wheel
      running build
      running build_py
      creating build
      creating build/lib.linux-aarch64-3.10
      creating build/lib.linux-aarch64-3.10/coincurve
      copying coincurve/types.py -> build/lib.linux-aarch64-3.10/coincurve
      copying coincurve/ecdsa.py -> build/lib.linux-aarch64-3.10/coincurve
      copying coincurve/_windows_libsecp256k1.py -> build/lib.linux-aarch64-3.10/coincurve
      copying coincurve/keys.py -> build/lib.linux-aarch64-3.10/coincurve
      copying coincurve/context.py -> build/lib.linux-aarch64-3.10/coincurve
      copying coincurve/flags.py -> build/lib.linux-aarch64-3.10/coincurve
      copying coincurve/__init__.py -> build/lib.linux-aarch64-3.10/coincurve
      copying coincurve/utils.py -> build/lib.linux-aarch64-3.10/coincurve
      copying coincurve/py.typed -> build/lib.linux-aarch64-3.10/coincurve
      running build_clib
      Can't exec "aclocal": No such file or directory at /data/data/com.termux/files/usr/share/autoconf/Autom4te/FileUtils.pm line 274.
      autoreconf: error: aclocal failed with exit status: 1
      Traceback (most recent call last):
        File "/data/data/com.termux/files/usr/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 363, in <module>
          main()
        File "/data/data/com.termux/files/usr/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 345, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
        File "/data/data/com.termux/files/usr/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 261, in build_wheel
          return _build_backend().build_wheel(wheel_directory, config_settings,
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 244, in build_wheel
          return self._build_with_temp_dir(['bdist_wheel'], '.whl',
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 229, in _build_with_temp_dir
          self.run_setup()
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 281, in run_setup
          super(_BuildMetaLegacyBackend,
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 174, in run_setup
          exec(compile(code, __file__, 'exec'), locals())
        File "setup.py", line 264, in <module>
          setup(
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/__init__.py", line 155, in setup
          return distutils.core.setup(**attrs)
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 148, in setup
          return run_commands(dist)
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 163, in run_commands
          dist.run_commands()
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 967, in run_commands
          self.run_command(cmd)
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 986, in run_command
          cmd_obj.run()
        File "setup.py", line 97, in run
          _bdist_wheel.run(self)
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/wheel/bdist_wheel.py", line 299, in run
          self.run_command('build')
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 313, in run_command
          self.distribution.run_command(command)
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 986, in run_command
          cmd_obj.run()
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build.py", line 135, in run
          self.run_command(cmd_name)
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 313, in run_command
          self.distribution.run_command(command)
        File "/data/data/com.termux/files/usr/tmp/pip-build-env-idl32cqz/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 986, in run_command
          cmd_obj.run()
        File "setup.py", line 154, in run
          subprocess.check_call([autogen], cwd=absolute('libsecp256k1'))
        File "/data/data/com.termux/files/usr/lib/python3.10/subprocess.py", line 369, in check_call
          raise CalledProcessError(retcode, cmd)
      subprocess.CalledProcessError: Command '['/data/data/com.termux/files/usr/tmp/pip-install-pgwmnz6f/coincurve_5ace6eabc71247daaa71de70d4272038/libsecp256k1/autogen.sh']' returned non-zero exit status 1.
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for coincurve
Failed to build coincurve
ERROR: Could not build wheels for coincurve, which is required to install pyproject.toml-based projects

我已经安装了 wheel,但它仍然无法正常工作并尝试了一些其他的东西,但都没有工作(我不记得了,抱歉)。 我正在使用 Python 3.10.2 和 pip 22.0.4 一切通常都是最新的

谁知道我该如何解决这个问题?

最佳答案

更新 pip3 并安装 wheel。然后尝试单独安装 coincurve。

pip3 install --upgrade pip3

pip3 install wheel

pip3 install coincurve

关于python - 安装基于 pyproject.toml 的项目所需的错误 : Could not build wheels for coincurve,,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/71443172/

相关文章:

python - "PermissionError: [Errno 13] Permission denied: '/usr/lib/python3.5/site-packages '"安装Django

android - Android 主 UI 线程的 Looper.prepare() 和 Looper.loop() 方法调用

计算 C 中一个整数占用多少位

c++ - 在 C/C++ 中附加位

python - 完成的一些事件在 python 中创建另一个事件

python - 如何同时将 Python 与 C 和 Java 结合使用?

python - 如何将 SqlAlchemy 结果序列化为 JSON?

java - 将对象添加到 ListView - ANDROID

java - Android studio中的java文件错误

c - C中rotate left的解释