x11-rs
x11-rs copied to clipboard
Modify the X11 crate for no_std
This resolves #93 by turning the x11
crate into a #![no_std]
crate. x11
now has the std
feature, enabled by default. At the crate root, I have created the crate-private os_primitives
module. This module will reexport the std::os::raw
module if the std
feature is enabled, or reexport the C primitives within libc
if it is disabled. In this PR, I also cleaned up the code somewhat and ran the rustfmt
program.
Note that the x11-dl
crate within this repository still uses std
. I have modified it slightly to be compatible with the changes described above.