mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-04-01 02:05:30 +00:00
21 lines
490 B
Rust
21 lines
490 B
Rust
use cfg_if::cfg_if;
|
|
|
|
pub mod config;
|
|
pub mod common;
|
|
|
|
#[cfg(feature = "with-mio")]
|
|
pub mod mio;
|
|
#[cfg(all(feature = "with-glommio", target_os = "linux"))]
|
|
pub mod glommio;
|
|
|
|
pub const APP_NAME: &str = "aquatic_http: HTTP/TLS BitTorrent tracker";
|
|
|
|
pub fn run(config: config::Config) -> ::anyhow::Result<()> {
|
|
cfg_if! {
|
|
if #[cfg(all(feature = "with-glommio", target_os = "linux"))] {
|
|
glommio::run(config)
|
|
} else {
|
|
mio::run(config)
|
|
}
|
|
}
|
|
}
|