msgpack-c icon indicating copy to clipboard operation
msgpack-c copied to clipboard

Build failure using clang5 and clang6 on Windows

Open macdew opened this issue 7 years ago • 0 comments

Our project works fine with Visual Studio cl.exe, but when I use the LLVM clang-for-windows compiler, I get the following error:

  In file included from msgpack\2.1.5\include\msgpack.hpp:18:
  In file included from msgpack\2.1.5\include/msgpack/type.hpp:18:
  In file included from msgpack\2.1.5\include/msgpack/adaptor/size_equal_only.hpp:13:
  In file included from msgpack\2.1.5\include\msgpack/adaptor/size_equal_only_decl.hpp:13:
  In file included from msgpack\2.1.5\include\msgpack/v1/adaptor/size_equal_only_decl.hpp:15:
  In file included from msgpack\2.1.5\include\msgpack/adaptor/msgpack_tuple.hpp:15:
  In file included from msgpack\2.1.5\include\msgpack/v1/adaptor/msgpack_tuple.hpp:18:
msgpack\2.1.5\include\msgpack/v1/adaptor/detail/cpp11_msgpack_tuple.hpp(65,16): error : no matching function for call to 'get' [myproj.vcxproj]
          o.pack(std::get<0>(v));

Clang on linux and Mac work fine, I think this may be a combination of clang with the microsoft runtime/headers? The compiler shows a bunch of failed matches, including in C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\tuple

This happens in Visual Studio 2015 (and Visual Studio 2017) when you install the clang compiler from llvm.org, then compile using the LLVM-vs2014 toolset.

macdew avatar Mar 28 '18 16:03 macdew