set HAVE_CXX11 for MSVC
set HAVE_CXX11 for clang
change var names to avoid warnings re shadowing