gchp / rustbox

Rust implementation of the termbox library
MIT License
467 stars 48 forks source link

Windows support #7

Open gchp opened 9 years ago

gchp commented 9 years ago

So far I've only tested this on Linux and Mac. Need to make sure it works correctly on Windows also. Right now I believe this doesn't even build on Windows. See gchp/iota#25 for a starting place.

ghost commented 9 years ago

Is the goal here to get termbox for C to work on windows, or to jump straight into the pure-Rust version?

In either case this should need the Windows Console API?

ghost commented 9 years ago

FYI I am working on a pure-rust implementation for windows using the kernel32-sys bindings for win console api. LMK if you want me to contribute the code here. This is my first Rust project

gchp commented 9 years ago

@jayrandez the goal would be to get the Rust version working on Windows. My hope for Rustbox in the future would be to drop the C bindings and be entirely standalone. Windows is a bit of a gray area to me, though, so I'd welcome your contributions!

ghost commented 9 years ago

Working on windows version in a fork of rustbox, under the branch "win-dev"

I submitted a pull request which reorganizes the files a bit so that the windows implementation doesn't interfere with the existing linux. No changes to API or build.

Will submit another pull request once windows version implements the full API.

retep998 commented 8 years ago

I have started a middle level wrapper around the Windows console API in wio which should make implementing support here much nicer as you won't have to muck about with raw pointers.

An example of using that wrapper: https://github.com/retep998/wio-rs/blob/master/examples/console.rs

ghost commented 8 years ago

IIRC I had most of the windows support done in a separate fork. I abandoned it though, no time these days.

bb010g commented 8 years ago

Is there any chance of integrating @jayrandez's work soon?

rahilwazir commented 8 years ago

@gchp Whats the update for windows build?

aschuhardt commented 7 years ago

Would it be possible to get an update on if/when this might be in process?

Revertron commented 6 years ago

Okay, after 4 years I'm interested in working windows version too...

gchp commented 6 years ago

The issue with windows support is that the underlying C library doesn't have windows support.

In order to implement windows support here, the rustbox needs to be re-written to remove the dependency on the C library, similar to the Go implementation (https://github.com/nsf/termbox-go).

I'd be happy to work with someone on this, however I do not have time currently to do all of this development myself.

aberg001 commented 5 years ago

I'm not sure if this belongs here or in a new issue, but if I build the example code from the README using the Linux Subsystem for Windows (Ubuntu) it compiles and runs but does not quit when I press 'q'.