romanz / electrs

An efficient re-implementation of Electrum Server in Rust
MIT License
1.06k stars 391 forks source link

Build: could not find `iterator` in `signal_hook` and SIGUSR1 not found in scope #709

Open vostrnad opened 2 years ago

vostrnad commented 2 years ago

Which command failed? cargo build --locked --release (with or without --no-default-features)

What was the error message?

Error message ``` error[E0432]: unresolved import `signal_hook::iterator` --> src\signals.rs:4:18 | 4 | use signal_hook::iterator::Signals; | ^^^^^^^^ could not find `iterator` in `signal_hook` error[E0425]: cannot find value `SIGUSR1` in this scope --> src\signals.rs:59:13 | 59 | SIGUSR1, // allow external triggering (e.g. via bitcoind `blocknotify`) | ^^^^^^^ not found in this scope error: aborting due to 2 previous errors ```

System OS name and version: Windows 10 rustc 1.48.0 (7eac88abb 2020-11-16) cargo 1.48.0 (65cbdd2dc 2020-10-14)

Compilation Linking: static Cross compilation: no Target architecture: amd64

romanz commented 1 year ago

Thanks for reporting this issue, and sorry for the delayed response! Does this issue reproduces on latest master?

vostrnad commented 1 year ago

Yes, the error message appears exactly the same.

romanz commented 1 year ago

I guess it's related to https://docs.rs/signal-hook/latest/signal_hook/iterator/index.html not being supported on Windows.

romanz commented 1 year ago

Maybe we can try to use https://crates.io/crates/ctrlc (which seems to support Windows).