- Added SNMP configuration options to `AppConfig` for querying printer status. - Extended `PrintInstruction` in the proto file to support additional fields for remote file URLs and raw data. - Implemented logic in `CupsClient` to retrieve printer paper levels and page counts via SNMP. - Updated `Cargo.toml` to include `snmp` and `reqwest` dependencies for network communication. - Refactored `TempPdf` handling to support multiple data sources for printing. - Improved error handling and logging for better diagnostics during print operations.
15 lines
391 B
Rust
15 lines
391 B
Rust
fn main() {
|
|
let protoc = protoc_bin_vendored::protoc_bin_path().expect("failed to fetch protoc");
|
|
unsafe {
|
|
std::env::set_var("PROTOC", protoc);
|
|
}
|
|
|
|
println!("cargo:rerun-if-changed=proto/control.proto");
|
|
|
|
tonic_build::configure()
|
|
.build_server(false)
|
|
.compile(&["proto/control.proto"], &["proto"])
|
|
.expect("failed to compile protobuf");
|
|
}
|
|
|