2026-04-12 19:18:18 -03:00
|
|
|
use std::path::PathBuf;
|
|
|
|
|
|
|
|
|
|
fn main() {
|
2026-04-13 02:52:32 -03:00
|
|
|
println!("cargo:rustc-check-cfg=cfg(coverage)");
|
|
|
|
|
|
2026-04-12 19:18:18 -03:00
|
|
|
let manifest_dir = PathBuf::from(std::env::var("CARGO_MANIFEST_DIR").expect("manifest dir"));
|
|
|
|
|
let workspace_dir = manifest_dir.parent().expect("workspace dir");
|
|
|
|
|
|
|
|
|
|
let server_uvc = workspace_dir
|
|
|
|
|
.join("server/src/bin/lesavka-uvc.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical server uvc bin path");
|
2026-04-12 19:47:26 -03:00
|
|
|
let server_main = workspace_dir
|
|
|
|
|
.join("server/src/main.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical server main path");
|
2026-04-12 21:10:15 -03:00
|
|
|
let server_video = workspace_dir
|
|
|
|
|
.join("server/src/video.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical server video path");
|
2026-04-12 21:12:22 -03:00
|
|
|
let server_gadget = workspace_dir
|
|
|
|
|
.join("server/src/gadget.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical server gadget path");
|
2026-04-13 02:52:32 -03:00
|
|
|
let server_video_sinks = workspace_dir
|
|
|
|
|
.join("server/src/video_sinks.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical server video_sinks path");
|
2026-04-12 19:47:26 -03:00
|
|
|
let client_main = workspace_dir
|
|
|
|
|
.join("client/src/main.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client main path");
|
2026-04-13 02:52:32 -03:00
|
|
|
let client_app = workspace_dir
|
|
|
|
|
.join("client/src/app.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client app path");
|
2026-04-12 19:47:26 -03:00
|
|
|
let client_inputs = workspace_dir
|
|
|
|
|
.join("client/src/input/inputs.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client inputs path");
|
2026-04-13 02:52:32 -03:00
|
|
|
let client_camera = workspace_dir
|
|
|
|
|
.join("client/src/input/camera.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client camera path");
|
2026-04-12 20:45:31 -03:00
|
|
|
let client_keyboard = workspace_dir
|
|
|
|
|
.join("client/src/input/keyboard.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client keyboard path");
|
2026-04-13 02:52:32 -03:00
|
|
|
let client_microphone = workspace_dir
|
|
|
|
|
.join("client/src/input/microphone.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client microphone path");
|
2026-04-12 20:45:31 -03:00
|
|
|
let client_mouse = workspace_dir
|
|
|
|
|
.join("client/src/input/mouse.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client mouse path");
|
2026-04-13 02:52:32 -03:00
|
|
|
let client_output_audio = workspace_dir
|
|
|
|
|
.join("client/src/output/audio.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client output audio path");
|
|
|
|
|
let client_output_display = workspace_dir
|
|
|
|
|
.join("client/src/output/display.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client output display path");
|
|
|
|
|
let client_output_video = workspace_dir
|
|
|
|
|
.join("client/src/output/video.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical client output video path");
|
2026-04-12 19:18:18 -03:00
|
|
|
let common_cli = workspace_dir
|
|
|
|
|
.join("common/src/bin/cli.rs")
|
|
|
|
|
.canonicalize()
|
|
|
|
|
.expect("canonical common cli bin path");
|
|
|
|
|
|
|
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_SERVER_UVC_BIN_SRC={}",
|
|
|
|
|
server_uvc.display()
|
|
|
|
|
);
|
2026-04-12 19:47:26 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_SERVER_MAIN_SRC={}",
|
|
|
|
|
server_main.display()
|
|
|
|
|
);
|
2026-04-12 21:10:15 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_SERVER_VIDEO_SRC={}",
|
|
|
|
|
server_video.display()
|
|
|
|
|
);
|
2026-04-12 21:12:22 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_SERVER_GADGET_SRC={}",
|
|
|
|
|
server_gadget.display()
|
|
|
|
|
);
|
2026-04-13 02:52:32 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_SERVER_VIDEO_SINKS_SRC={}",
|
|
|
|
|
server_video_sinks.display()
|
|
|
|
|
);
|
2026-04-12 19:47:26 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_MAIN_SRC={}",
|
|
|
|
|
client_main.display()
|
|
|
|
|
);
|
2026-04-13 02:52:32 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_APP_SRC={}",
|
|
|
|
|
client_app.display()
|
|
|
|
|
);
|
2026-04-12 19:47:26 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_INPUTS_SRC={}",
|
|
|
|
|
client_inputs.display()
|
|
|
|
|
);
|
2026-04-13 02:52:32 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_CAMERA_SRC={}",
|
|
|
|
|
client_camera.display()
|
|
|
|
|
);
|
2026-04-12 20:45:31 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_KEYBOARD_SRC={}",
|
|
|
|
|
client_keyboard.display()
|
|
|
|
|
);
|
2026-04-13 02:52:32 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_MICROPHONE_SRC={}",
|
|
|
|
|
client_microphone.display()
|
|
|
|
|
);
|
2026-04-12 20:45:31 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_MOUSE_SRC={}",
|
|
|
|
|
client_mouse.display()
|
|
|
|
|
);
|
2026-04-13 02:52:32 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_OUTPUT_AUDIO_SRC={}",
|
|
|
|
|
client_output_audio.display()
|
|
|
|
|
);
|
|
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_OUTPUT_DISPLAY_SRC={}",
|
|
|
|
|
client_output_display.display()
|
|
|
|
|
);
|
|
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_CLIENT_OUTPUT_VIDEO_SRC={}",
|
|
|
|
|
client_output_video.display()
|
|
|
|
|
);
|
2026-04-12 19:18:18 -03:00
|
|
|
println!(
|
|
|
|
|
"cargo:rustc-env=LESAVKA_COMMON_CLI_BIN_SRC={}",
|
|
|
|
|
common_cli.display()
|
|
|
|
|
);
|
|
|
|
|
}
|