diff --git a/src/lib.rs b/src/lib.rs index b5e5695..3a55290 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -11,17 +11,17 @@ use std::collections::HashSet; mod version; -#[cfg(not(target_arch = "wasm32"))] +#[cfg(any(not(target_arch = "wasm32"), target_os = "emscripten"))] mod native; -#[cfg(not(target_arch = "wasm32"))] +#[cfg(any(not(target_arch = "wasm32"), target_os = "emscripten"))] pub use native::*; -#[cfg(not(target_arch = "wasm32"))] +#[cfg(any(not(target_arch = "wasm32"), target_os = "emscripten"))] mod gl46; -#[cfg(target_arch = "wasm32")] +#[cfg(all(target_arch = "wasm32", not(target_os = "emscripten")))] #[path = "web_sys.rs"] mod web; -#[cfg(target_arch = "wasm32")] +#[cfg(all(target_arch = "wasm32", not(target_os = "emscripten")))] pub use web::*; pub type Shader = ::Shader;