fix some errors when build the windows version