Support VS2012 and VS2013

Support building VS2012 and VS2013 environment

(cherry picked from commit 41cbc8ba5cb17ae42e63945e7c9c51dd4353ced5)