Skip to content
This repository has been archived by the owner on Jun 24, 2024. It is now read-only.

build fails on arch linux #33

Closed
xi-pinmping opened this issue Mar 17, 2023 · 4 comments
Closed

build fails on arch linux #33

xi-pinmping opened this issue Mar 17, 2023 · 4 comments

Comments

@xi-pinmping
Copy link

xi-pinmping commented Mar 17, 2023

Hi, building with arch linux fails and provides this output

warning: ggml/ggml.c: In function ‘quantize_row_q4_0’:
warning: ggml/ggml.c:413:13: warning: unused variable ‘pp’ [-Wunused-variable]
warning:   413 |     uint8_t pp[QK/2];
warning:       |             ^~
warning: ggml/ggml.c: In function ‘ggml_vec_dot_q4_0’:
warning: ggml/ggml.c:1422:18: warning: unused variable ‘countBlocks’ [-Wunused-variable]
warning:  1422 |     const size_t countBlocks = nb;
warning:       |                  ^~~~~~~~~~~
   Compiling llama-rs v0.1.0 (/home/user/opt/llama/llama-rs/llama-rs)
error[E0658]: let...else  statements are unstable
   --> llama-rs/src/lib.rs:492:17
    |
492 | /                 let Some(tensor) = model.tensors.get(&tensor_name)
493 | |                     else {
494 | |                         return Err(LoadError::UnknownTensor { tensor_name, path: part_path });
495 | |                     };
    | |______________________^
    |
    = note: see issue #87335 <https://github.com/rust-lang/rust/issues/87335> for more information

For more information about this error, try rustc --explain E0658.
error: could not compile llama-rs due to previous error
@philpax
Copy link
Collaborator

philpax commented Mar 17, 2023

You're using an old version of Rust - update to 1.65.0 or above.

@setzer22
Copy link
Collaborator

I wonder if there's a better way to enforce our MSRV so that cargo would complain if the rustc version is too old. These "something is unstable" messages are always so cryptic...

@philpax
Copy link
Collaborator

philpax commented Mar 17, 2023

There is: https://doc.rust-lang.org/cargo/reference/manifest.html#the-rust-version-field

We should check our MSRV and add that. If it's just let else though, it might not be too hard to drop the MSRV further 🤔

@setzer22
Copy link
Collaborator

For now I just made a very quick push specifying 1.65 as our MSRV to give a more accurate error message. We can later on try out different compiler versions to figure out the minimum (after removing the use of let..else)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants