0
点赞
收藏
分享

微信扫一扫

ubuntu系统python安装pycairo报错:Run-time dependency python found: NO (t

英乐 06-29 12:00 阅读 24

报错信息:


Run-time dependency python found: NO  (tried pkgconfig and       sysconfig)

../cairo/meson.build:51:15: ERROR: Python dependency not       found


解决方法:


sudo apt install python3-dev


(hhmarl_2D_pytorch) geovis@geovis-System-Product-Name:~/hhmarl_2D_pytorch$ uv pip install pycairo
Resolved 1 package in 1ms
× Failed to build pycairo==1.29.0 ├─▶ The build backend returned an error
╰─▶ Call to mesonpy.build_wheel failed (exit status: 1)

[stdout]
+ meson setup
/home/geovis/.cache/uv/sdists-v9/pypi/pycairo/1.29.0/NFcmmSxoqxBVzz4c/src
/home/geovis/.cache/uv/sdists-v9/pypi/pycairo/1.29.0/NFcmmSxoqxBVzz4c/src/.mesonpy-1pfhz83x
-Dbuildtype=release -Db_ndebug=if-release
-Db_vscrt=md -Dwheel=true -Dtests=false
--native-file=/home/geovis/.cache/uv/sdists-v9/pypi/pycairo/1.29.0/NFcmmSxoqxBVzz4c/src/.mesonpy-1pfhz83x/meson-python-native-file.ini
The Meson build system
Version: 1.11.1
Source dir:
/home/geovis/.cache/uv/sdists-v9/pypi/pycairo/1.29.0/NFcmmSxoqxBVzz4c/src
Build dir:
/home/geovis/.cache/uv/sdists-v9/pypi/pycairo/1.29.0/NFcmmSxoqxBVzz4c/src/.mesonpy-1pfhz83x
Build type: native build
Project name: pycairo
Project version: 1.29.0
C compiler for the host machine: cc (gcc 11.4.0 "cc (Ubuntu
11.4.0-1ubuntu1~22.04.3) 11.4.0")
C linker for the host machine: cc ld.bfd 2.38
Host machine cpu family: x86_64
Host machine cpu: x86_64
Program python3 found: YES
(/home/geovis/.cache/uv/builds-v0/.tmpUSLdhr/bin/python)
Compiler for C supports arguments -Wall: YES
Compiler for C supports arguments -Warray-bounds: YES
Compiler for C supports arguments -Wcast-align: YES
Compiler for C supports arguments -Wconversion: YES
Compiler for C supports arguments -Wextra: YES
Compiler for C supports arguments -Wformat=2: YES
Compiler for C supports arguments -Wformat-nonliteral: YES
Compiler for C supports arguments -Wformat-security: YES
Compiler for C supports arguments
-Wimplicit-function-declaration: YES
Compiler for C supports arguments -Winit-self: YES
Compiler for C supports arguments -Wmissing-format-attribute:
YES
Compiler for C supports arguments -Wmissing-noreturn: YES
Compiler for C supports arguments -Wnested-externs: YES
Compiler for C supports arguments -Wold-style-definition: YES
Compiler for C supports arguments -Wpacked: YES
Compiler for C supports arguments -Wpointer-arith: YES
Compiler for C supports arguments -Wreturn-type: YES
Compiler for C supports arguments -Wshadow: YES
Compiler for C supports arguments -Wsign-compare: YES
Compiler for C supports arguments -Wstrict-aliasing: YES
Compiler for C supports arguments -Wundef: YES
Compiler for C supports arguments -Wunused-but-set-variable:
YES
Compiler for C supports arguments -Wswitch-default: YES
Compiler for C supports arguments
-Wno-missing-field-initializers: YES
Compiler for C supports arguments -Wno-unused-parameter: YES
Compiler for C supports arguments -fno-strict-aliasing: YES
Compiler for C supports arguments -fvisibility=hidden: YES
Found pkg-config: YES (/usr/bin/pkg-config) 0.29.2
Run-time dependency cairo found: YES 1.16.0
Found pkg-config: YES (/usr/bin/pkg-config) 0.29.2
Run-time dependency python found: NO (tried pkgconfig and
sysconfig)

../cairo/meson.build:51:15: ERROR: Python dependency not
found

A full log can be found at
/home/geovis/.cache/uv/sdists-v9/pypi/pycairo/1.29.0/NFcmmSxoqxBVzz4c/src/.mesonpy-1pfhz83x/meson-logs/meson-log.txt

hint: Build failures usually indicate a problem with the package or the build environment(hhmarl_2D_pytorch)

举报
0 条评论