安装qmetaobject后,编译出现下面错误信息,原因是环境变量和搜索路径没有正确设置。
qt_gui>cargo run
warning: unused manifest key: build
Compiling qttypes v0.2.11
error: failed to run custom build command for `qttypes v0.2.11`
note: To improve backtraces for build dependencies, set the CARGO_PROFILE_DEV_BUILD_OVERRIDE_DEBUG=true environment variable to enable debug information generation.
Caused by:
process didn't exit successfully: `D:\DiskX\Demos\2024-01-05 Rust_QT\qt_gui\target\debug\build\qttypes-624ed0d59ffcb9fe\build-script-build` (exit code: 101)
--- stdout
cargo:rerun-if-env-changed=QT_INCLUDE_PATH
cargo:rerun-if-env-changed=QT_LIBRARY_PATH
cargo:rerun-if-env-changed=QMAKE
环境变量RUST_BACKTRACE的设置:
增加下面两个搜索路径: