add cmake support, osx, linux, windows