1#![no_std]
2#![allow(non_upper_case_globals)]
3#![allow(non_camel_case_types)]
4#![allow(non_snake_case)]
5
6#[cfg(any(target_os = "android", target_os = "linux"))]
7mod platform {
8 pub use linux_raw_sys::general::__kernel_size_t;
9 pub type drm_handle_t = core::ffi::c_uint;
10 pub const DRM_RDWR: u32 = linux_raw_sys::general::O_RDWR;
11 pub const DRM_CLOEXEC: u32 = linux_raw_sys::general::O_CLOEXEC;
12}
13
14#[cfg(not(any(target_os = "android", target_os = "linux")))]
15mod platform {
16 pub type __kernel_size_t = libc::size_t;
17 pub type drm_handle_t = core::ffi::c_ulong;
18 pub const DRM_RDWR: u32 = libc::O_RDWR as u32;
19 pub const DRM_CLOEXEC: u32 = libc::O_CLOEXEC as u32;
20}
21
22pub use platform::*;
23
24#[cfg(feature = "use_bindgen")]
25include!(concat!(env!("OUT_DIR"), "/bindings.rs"));
26
27#[cfg(not(feature = "use_bindgen"))]
28include!("bindings.rs");
29
30pub const DRM_PLANE_TYPE_OVERLAY: u32 = 0;
31pub const DRM_PLANE_TYPE_PRIMARY: u32 = 1;
32pub const DRM_PLANE_TYPE_CURSOR: u32 = 2;