Add portable support for windows by adding preprocesor conditions and fake implementations