Added windows compatibility, used PR #176