Made it to compile without record feature
This commit is contained in:
parent
b770c4d8fb
commit
21703321bd
@ -73,6 +73,8 @@ itertools = "0.12.0"
|
|||||||
chrono = {version = "0.4.31", optional = true}
|
chrono = {version = "0.4.31", optional = true}
|
||||||
# For getting UUIDs in recording
|
# For getting UUIDs in recording
|
||||||
uuid = { version = "1.6.1", features = ["v4"] , optional = true}
|
uuid = { version = "1.6.1", features = ["v4"] , optional = true}
|
||||||
|
|
||||||
|
# Command line argument parser, for CLI apps
|
||||||
clap = { version = "4.4.11", features = ["derive", "color", "help", "suggestions"] }
|
clap = { version = "4.4.11", features = ["derive", "color", "help", "suggestions"] }
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
use anyhow::Result;
|
use anyhow::{bail, Result};
|
||||||
use clap::{arg, command, Parser};
|
use clap::{arg, command, Parser};
|
||||||
use crossbeam::channel::{unbounded, Receiver, TryRecvError};
|
use crossbeam::channel::{unbounded, Receiver, TryRecvError};
|
||||||
#[cfg(feature = "record")]
|
#[cfg(feature = "record")]
|
||||||
use lasprs::daq::{StreamType,RecordSettings, RecordStatus, Recording, StreamMgr};
|
use lasprs::daq::{RecordSettings, RecordStatus, Recording, StreamMgr, StreamType};
|
||||||
use lasprs::Flt;
|
use lasprs::Flt;
|
||||||
use std::{
|
use std::{
|
||||||
io, thread,
|
io, thread,
|
||||||
@ -23,6 +23,10 @@ struct Cli {
|
|||||||
#[arg(short, long = "config-file")]
|
#[arg(short, long = "config-file")]
|
||||||
config_file_daq: Option<String>,
|
config_file_daq: Option<String>,
|
||||||
}
|
}
|
||||||
|
#[cfg(not(feature = "record"))]
|
||||||
|
fn main() -> Result<()> {
|
||||||
|
bail!("Record feature not enabled. This executable is not working");
|
||||||
|
}
|
||||||
|
|
||||||
#[cfg(feature = "record")]
|
#[cfg(feature = "record")]
|
||||||
fn main() -> Result<()> {
|
fn main() -> Result<()> {
|
||||||
@ -44,7 +48,6 @@ fn main() -> Result<()> {
|
|||||||
let cfg = DaqConfig::deserialize_TOML_str(&file)?;
|
let cfg = DaqConfig::deserialize_TOML_str(&file)?;
|
||||||
smgr.startStream(StreamType::Input, &cfg)?;
|
smgr.startStream(StreamType::Input, &cfg)?;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
let mut r = Recording::new(settings, &mut smgr)?;
|
let mut r = Recording::new(settings, &mut smgr)?;
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
use std::{ops::Index, path::PathBuf};
|
use std::{ops::Index, path::PathBuf};
|
||||||
|
|
||||||
use anyhow::Result;
|
use anyhow::Result;
|
||||||
use hdf5::File;
|
|
||||||
use super::api::StreamApiDescr;
|
use super::api::StreamApiDescr;
|
||||||
use super::datatype::DataType;
|
use super::datatype::DataType;
|
||||||
use super::deviceinfo::DeviceInfo;
|
use super::deviceinfo::DeviceInfo;
|
||||||
|
Loading…
Reference in New Issue
Block a user