diff --git a/README.md b/README.md index 238cb15..1441c4b 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ fn main() { Status ------ -Currently Mac and Windows has been tested. Linux will be tested and verified soon. +Currently Mac, Windows has been Linux has been tested which are the supported platforms for now. Build instructions diff --git a/src/lib.rs b/src/lib.rs index 9a66e41..63dc6a0 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -19,6 +19,13 @@ extern { fn mfb_close(); } +#[cfg(target_os = "linux")] +#[link(name = "X11")] +extern { + fn mfb_open(name: *const c_char, width: c_int, height: c_int) -> c_int; + fn mfb_update(buffer: *mut c_void) -> c_int; + fn mfb_close(); +} /// /// Open up a window diff --git a/src/native/x11/X11MiniFB.c b/src/native/x11/X11MiniFB.c index c25d9b5..e55face 100644 --- a/src/native/x11/X11MiniFB.c +++ b/src/native/x11/X11MiniFB.c @@ -1,6 +1,5 @@ #include #include -#include ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////