From 7502fc16ea800fad1a1dcb15ca73f7c182e66275 Mon Sep 17 00:00:00 2001 From: Charlton Rodda Date: Sun, 10 Dec 2023 02:11:11 +0000 Subject: [PATCH] Add error if no backend is enabled --- src/lib.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/lib.rs b/src/lib.rs index fe1b93a..e35d09e 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -171,6 +171,9 @@ impl Plugin for OpenXrPlugin { } } +#[cfg(all(not(feature = "vulkan"), not(all(feature = "d3d12", windows))))] +compile_error!("At least one platform-compatible backend feature must be enabled."); + #[derive(Debug)] pub enum Backend { #[cfg(feature = "vulkan")]