change back to using "linked" feature cfg.
This commit is contained in:
@@ -4,7 +4,8 @@ version = "0.1.0"
|
|||||||
edition = "2021"
|
edition = "2021"
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
default = ["openxr/mint"]
|
default = ["openxr/mint", "linked"]
|
||||||
|
linked = ["openxr/linked"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
anyhow = "1.0.75"
|
anyhow = "1.0.75"
|
||||||
@@ -16,7 +17,7 @@ wgpu-core = { version = "0.17.1", features = ["vulkan"] }
|
|||||||
wgpu-hal = "0.17.1"
|
wgpu-hal = "0.17.1"
|
||||||
|
|
||||||
[target.'cfg( target_os = "linux" )'.dependencies]
|
[target.'cfg( target_os = "linux" )'.dependencies]
|
||||||
openxr = { version = "0.17.1", features = ["linked"] }
|
openxr = "0.17.1"
|
||||||
|
|
||||||
[target.'cfg(not(target_os = "linux"))'.dependencies]
|
[target.'cfg(not(target_os = "linux"))'.dependencies]
|
||||||
openxr = { version = "0.17.1", features = ["static"] }
|
openxr = { version = "0.17.1", features = ["static"] }
|
||||||
|
|||||||
@@ -36,9 +36,9 @@ pub fn initialize_xr_graphics(
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub fn xr_entry() -> xr::Entry {
|
pub fn xr_entry() -> xr::Entry {
|
||||||
#[cfg(target_os = "linux")]
|
#[cfg(feature = "linked")]
|
||||||
let entry = xr::Entry::linked();
|
let entry = xr::Entry::linked();
|
||||||
#[cfg(not(target_os = "linux"))]
|
#[cfg(not(feature = "linked"))]
|
||||||
let entry = unsafe { xr::Entry::load().unwrap() };
|
let entry = unsafe { xr::Entry::load().unwrap() };
|
||||||
entry
|
entry
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user