mirror of
https://github.com/tursodatabase/limbo.git
synced 2025-08-04 10:08:20 +00:00
Fix build on macOS
This commit is contained in:
parent
60abb68cef
commit
caf56bdc77
2 changed files with 7 additions and 4 deletions
|
@ -4,10 +4,10 @@ use std::io::{Read, Seek};
|
|||
use std::os::unix::io::AsRawFd;
|
||||
use std::{fs::File, sync::Arc};
|
||||
|
||||
#[cfg(feature = "fs")]
|
||||
#[cfg(all(feature = "fs", target_os = "linux"))]
|
||||
mod io_uring;
|
||||
|
||||
#[cfg(target_os = "linux")]
|
||||
#[cfg(feature = "fs")]
|
||||
mod syscall;
|
||||
|
||||
/// I/O access method
|
||||
|
@ -35,7 +35,7 @@ impl Default for IO {
|
|||
}
|
||||
}
|
||||
|
||||
#[cfg(all(feature = "fs", target_os = "darwin"))]
|
||||
#[cfg(all(feature = "fs", target_os = "macos"))]
|
||||
impl Default for IO {
|
||||
fn default() -> Self {
|
||||
IO {
|
||||
|
@ -61,6 +61,7 @@ impl IO {
|
|||
let io = Arc::new(syscall::SyscallIO::open(path)?);
|
||||
Ok(PageSource { io })
|
||||
}
|
||||
#[cfg(all(feature = "fs", target_os = "darwin"))]
|
||||
IOMethod::IoUring => {
|
||||
let io = Arc::new(io_uring::IoUring::open(path)?);
|
||||
Ok(PageSource { io })
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue