Rust-GPU / Rust-GPU/rust-gpu.github.io

Guide doesn't seem to work

Đang mở
#90 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Ngôn ngữ chính
MDX
Star
16
Fork
8
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Apologies in advance for a mess of an issue, I'm struggling to get started with rust-gpu and running in to different issues with the docs.

I tried to follow https://rust-gpu.github.io/rust-gpu/book/writing-shader-crates.html but something seems off there and I'm not sure what, been struggling with it for hours.

First error I get is

error: failed to run custom build command for `rustc_codegen_spirv v0.9.0`

Caused by:
  process didn't exit successfully: `[path]/builder/target/debug/build/rustc_codegen_spirv-ffa44511fcb54869/build-script-build` (exit status: 1)
  --- stdout
  cargo:rerun-if-env-changed=RUSTGPU_SKIP_TOOLCHAIN_CHECK

  --- stderr
  error: wrong toolchain detected (found commit hash `be19eda0dc4c22c5cf5f1b48fd163acf9bd4b0a6`, expected `1a5f8bce74ee432f7cc3aa131bc3d6920e06de10`).
  Make sure your `rust-toolchain.toml` file contains the following:
  -------------
  [toolchain]
  channel = "nightly-2023-05-27"
  components = ["rust-src", "rustc-dev", "llvm-tools-preview"]
  -------------

So I updated channel to "nightly-2023-05-27" instead of the one suggested in the docs, but then I get:

error: failed to parse lock file at: [path]/builder/Cargo.lock

Caused by:
  lock file version `4` was found, but this version of Cargo does not understand this lock file, perhaps Cargo needs to be updated?

Changing Cargo.lock version to 3 gives:

error: failed to run custom build command for `builder v0.1.0 ([path]/builder)`

Caused by:
  process didn't exit successfully: `[path]/builder/target/debug/build/builder-ab9d01841427145d/build-script-build` (exit status: 1)
  --- stdout
  cargo:rerun-if-env-changed=RUSTGPU_CODEGEN_ARGS
  cargo:rerun-if-env-changed=RUSTGPU_RUSTFLAGS

  --- stderr
  error: failed to parse lock file at: [path]/shader/Cargo.lock

  Caused by:
    lock file version `4` was found, but this version of Cargo does not understand this lock file, perhaps Cargo needs to be updated?
  Error: BuildFailed

I tried to play with some more settings, and kept bumping in to

  error: missing libm intrinsic _RNvMNtNtNtCsbtJY5FUAdnQ_4libm4math7support3bigNtB2_4u2566signed, which is math::support::big::u256::signed

  error: missing libm intrinsic _RNvXs2_NtNtNtCsbtJY5FUAdnQ_4libm4math7support3bigNtB5_4u256NtNtNtCsktVOBji75Go_4core3ops5arith3Add3add, which is <math::support::big::u256 as core::ops::Add>::add

  error: missing libm intrinsic _RNvXs3_NtNtNtCsbtJY5FUAdnQ_4libm4math7support3bigNtB5_4u256INtNtNtCsktVOBji75Go_4core3ops3bit3ShrmE3shr, which is <math::support::big::u256 as core::ops::Shr<u32>>::shr

  error: missing libm intrinsic _RNvXs4_NtNtNtCsbtJY5FUAdnQ_4libm4math7support3bigoNtNtB7_10int_traits4HInt5widen, which is math::support::big::<impl math::support::int_traits::HInt for u128>::widen

  error: missing libm intrinsic _RNvXs4_NtNtNtCsbtJY5FUAdnQ_4libm4math7support3bigoNtNtB7_10int_traits4HInt10zero_widen, which is math::support::big::<impl math::support::int_traits::HInt for u128>::zero_widen
...

Again, apologies for this mess. I honestly can't figure out what the root cause is and how to get around it.

Any pointers?

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Bắt đầu với hướng dẫn writing-shader-crates tại URL được liên kết và đối chiếu các hướng dẫn trong đó với những lỗi đã báo cáo của toolchain rustc_codegen_spirv và Cargo.lock. Công việc được xem là hoàn tất khi hướng dẫn cung cấp một thiết lập có thể tái hiện, tránh được các lỗi đã báo cáo, hoặc ghi lại rõ ràng các phiên bản và giới hạn bắt buộc.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
rust
Lĩnh vực
documentation
Loại issue
Tài liệu
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Cần làm rõ
Mức phù hợp với người mới
25/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.