Add Linux audio capture module with unsupported functionality

- Introduced a new `linux.rs` module for audio capture, indicating that audio capture is not supported on Linux at this time.
- Updated `mod.rs` to include the Linux module conditionally based on the target OS.
This commit is contained in:
Jamie Pine
2026-01-31 05:10:27 -08:00
parent ab10c26ce4
commit a52ff7d950
2 changed files with 20 additions and 0 deletions
@@ -0,0 +1,16 @@
use crate::audio_capture::AudioCaptureState;
pub async fn start_capture(
_state: &AudioCaptureState,
_max_duration_secs: u32,
) -> Result<(), String> {
Err("Audio capture is not supported on Linux, YET. Use the built-in recording features instead.".to_string())
}
pub async fn stop_capture(_state: &AudioCaptureState) -> Result<String, String> {
Err("Audio capture is not supported on Linux.".to_string())
}
pub fn is_supported() -> bool {
false
}
+4
View File
@@ -2,11 +2,15 @@
mod macos;
#[cfg(target_os = "windows")]
mod windows;
#[cfg(target_os = "linux")]
mod linux;
#[cfg(target_os = "macos")]
pub use macos::*;
#[cfg(target_os = "windows")]
pub use windows::*;
#[cfg(target_os = "linux")]
pub use linux::*;
use std::sync::{Arc, Mutex};