efforg/rayhunter#738

View on GitHub →
#738 error building v0.8.0 from main branch

Hi!

I would like to be able to build rayhunter at home and possibly contribute to the project. I cloned the repository and I’m following the build instructions (https://efforg.github.io/rayhunter/installing-from-source.html). I’m getting two warnings (okay, no big deal) and also getting four compile errors:

Compiling rayhunter v0.8.0 (/home/gary/rayhunter-dec2025/rayhunter/lib)
warning: unused import: `error`
 --> lib/src/diag.rs:8:11
  |
8 | use log::{error, warn};
  |           ^^^^^
  |
  = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default

warning: value assigned to `hdr_len` is never read
   --> lib/src/diag.rs:153:14
    |
153 | #[deku(ctx = "log_type: u16, hdr_len: u16", id = "log_type")]
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: maybe it is overwritten before being read?
    = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default

warning: `rayhunter` (lib) generated 2 warnings (run `cargo fix --lib -p rayhunter` to apply 1 suggestion)
   Compiling rayhunter-daemon v0.8.0 (/home/gary/rayhunter-dec2025/rayhunter/daemon)
error: couldn't read `daemon/src/../web/build/rayhunter_orca_only.png`: No such file or directory (os error 2)
  --> daemon/src/server.rs:79:13
   |
79 |             include_bytes!("../web/build/rayhunter_orca_only.png"),
   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error: couldn't read `daemon/src/../web/build/rayhunter_text.png`: No such file or directory (os error 2)
  --> daemon/src/server.rs:84:13
   |
84 |             include_bytes!("../web/build/rayhunter_text.png"),
   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error: couldn't read `daemon/src/../web/build/favicon.png`: No such file or directory (os error 2)
  --> daemon/src/server.rs:89:13
   |
89 |             include_bytes!("../web/build/favicon.png"),
   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error: couldn't read `daemon/src/../web/build/index.html.gz`: No such file or directory (os error 2)
  --> daemon/src/server.rs:97:13
   |
97 |             include_bytes!("../web/build/index.html.gz"),
   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error: could not compile `rayhunter-daemon` (bin "rayhunter-daemon") due to 4 previous errors

I did not see rayhunter_orca_only.png at the location above, but rather at rayhunter/daemon/web/static.

I’ve been a programmer for a while, but I’m new to Rust, so apologies if I’m missing a simple fix.

Thank you for the help!

Gary

1
Comments (2)

You’re missing the web UI artifacts. You first need to build the web UI:

x@xps:~/workspace/code/rayhunter$ pushd daemon/web && npm install && npm run build && popd
~/workspace/code/rayhunter/daemon/web ~/workspace/code/rayhunter
... <SNIP> ...
.svelte-kit/output/server/remote-entry.js                            27.51 kB
.svelte-kit/output/server/chunks/internal.js                         72.44 kB
.svelte-kit/output/server/index.js                                  126.39 kB
✓ built in 2.58s

Run npm run preview to preview your production build locally.

> Using @sveltejs/adapter-static
  Wrote site to "build"
  ✔ done
~/workspace/code/rayhunter
x@xps:~/workspace/code/rayhunter$

Then you can:

x@xps:~/workspace/code/rayhunter$ cargo build-daemon-firmware-devel
   Compiling proc-macro2 v1.0.95
   Compiling unicode-ident v1.0.18
... <SNIP> ...
   Compiling pycrate-rs v0.1.0 (https://github.com/EFForg/pycrate-rs#9e72e40b)
   Compiling rayhunter v0.8.0 (/home/x/workspace/code/rayhunter/lib)
warning: unused import: `error`
 --> lib/src/diag.rs:8:11
  |
8 | use log::{error, warn};
  |           ^^^^^
  |
  = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default

warning: value assigned to `hdr_len` is never read
   --> lib/src/diag.rs:153:14
    |
153 | #[deku(ctx = "log_type: u16, hdr_len: u16", id = "log_type")]
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: maybe it is overwritten before being read?
    = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default

warning: `rayhunter` (lib) generated 2 warnings (run `cargo fix --lib -p rayhunter` to apply 1 suggestion)
   Compiling rayhunter-daemon v0.8.0 (/home/x/workspace/code/rayhunter/daemon)
    Finished `firmware-devel` profile [optimized + debuginfo] target(s) in 3m 59s
warning: the following packages contain code that will be rejected by a future version of Rust: num-bigint-dig v0.8.4
note: to see what the problems were, use the option `--future-incompat-report`, or run `cargo report future-incompatibilities --id 1`
x@xps:~/workspace/code/rayhunter$

And then build the rootshell:

x@xps:~/workspace/code/rayhunter$ cargo build -p rootshell --bin rootshell --target armv7-unknown-linux-musleabihf --profile firmware
   Compiling libc v0.2.172
   Compiling cfg_aliases v0.2.1
   Compiling bitflags v2.9.1
   Compiling cfg-if v1.0.0
   Compiling nix v0.29.0
   Compiling rootshell v0.8.0 (/home/x/workspace/code/rayhunter/rootshell)
    Finished `firmware` profile [optimized] target(s) in 3.92s
x@xps:~/workspace/code/rayhunter$

Finally, flash onto your device with adb:

FILE_RAYHUNTER_DAEMON=$PWD/target/armv7-unknown-linux-musleabihf/firmware-devel/rayhunter-daemon cargo run -p installer --bin installer orbic
1

Nice! Thank you, and “pilot error” on my part. :-)

My Orbic is attached via usb, so I needed to update the final step to “./target/debug/installer orbic-usb” (added -usb).

Now, it’s built and re-loaded and I’m interested to start learning how this thing works!

THANK YOU AGAIN!

Gary

👍 1❤️ 1