Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile gtest-all.cc failed to build on Windows with MSVC "error C2888: 'std::tuple_size<std::tr1::tuple<void,void,void,void,void,void,void,void,void,void>>': symbol cannot be defined within namespace 'tr1'" #39

Open
YangYang129 opened this issue Nov 8, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@YangYang129
Copy link

Compile gtest-all.cc failed to "error C2888: 'std::tuple_size<std::tr1::tuple<void,void,void,void,void,void,void,void,void,void>>': symbol cannot be defined within namespace 'tr1'". It can reproduces on version be8ca31 . Could you please help look at this issue? Thank you very much
Environment
Compiler version: VS2019 (16.11.2)
Operating system: Windows server 2016

Reproduce steps:

  1. git clone https://github.com/TorqueGameEngines/Torque2D F:\
  2. cd Torque2D\engine\source\testing\googleTest
  3. mkdir build_amd64test
  4. cd build_amd64test
  5. cmake -G "Visual Studio 16 2019" -A x64 -DCMAKE_SYSTEM_VERSION=10.0.18362.0 -DCMAKE_BUILD_TYPE=Release -Dgtest_build_tests=ON -DGTEST_USE_OWN_TR1_TUPLE=0 ..
  6. set CL=/wd4996
  7. msbuild /p:Configuration=Release;Platform=x64 gtest.sln /t:Rebuild /m

Error log:
msbuildx64test.log

Error info:
34>F:\Torque2D\engine\source\testing\googleTest\include\gtest/internal/gtest-tuple.h(711,69): error C2888: 'std::tuple_size<std::tr1::tuple<void,void,void,void,void,void,void,void,void,void>>': symbol cannot be defined within namespace 'tr1' [F:\Torque2D\engine\source\testing\googleTest\build_amd64test\gtest_main_use_own_tuple.vcxproj]
34>F:\Torque2D\engine\source\testing\googleTest\include\gtest/internal/gtest-tuple.h(747,2): error C3855: 'std::tuple_element': template parameter '_Index' is incompatible with the declaration [F:\Torque2D\engine\source\testing\googleTest\build_amd64test\gtest_main_use_own_tuple.vcxproj]
34>F:\Torque2D\engine\source\testing\googleTest\include\gtest/internal/gtest-tuple.h(759,10): error C2039: 'type': is not a member of 'std::tuple_element' [F:\Torque2D\engine\source\testing\googleTest\build_amd64test\gtest_main_use_own_tuple.vcxproj]
F:\Torque2D\engine\source\testing\googleTest\include\gtest/internal/gtest-tuple.h(744): message : see declaration of 'std::tuple_element' [F:\Torque2D\engine\source\testing\googleTest\build_amd64test\gtest_main_use_own_tuple.vcxproj]
34>F:\Torque2D\engine\source\testing\googleTest\include\gtest/internal/gtest-tuple.h(759,10): error C2146: syntax error: missing '>' before identifier 'type' [F:\Torque2D\engine\source\testing\googleTest\build_amd64test\gtest_main_use_own_tuple.vcxproj]
34>F:\Torque2D\engine\source\testing\googleTest\include\gtest/internal/gtest-tuple.h(759): error C2062: type 'unknown-type' unexpected [F:\Torque2D\engine\source\testing\googleTest\build_amd64test\gtest_main_use_own_tuple.vcxproj]
34>F:\Torque2D\engine\source\testing\googleTest\include\gtest/internal/gtest-tuple.h(759,10): error C2039: 'type': is not a member of '`global namespace'' [F:\Torque2D\engine\source\testing\googleTest\build_amd64test\gtest_main_use_own_tuple.vcxproj]
34>F:\Torque2D\engine\source\testing\googleTest\include\gtest/internal/gtest-tuple.h(760,1): error C2334: unexpected token(s) preceding '{'; skipping apparent function body [F:\Torque2D\engine\source\testing\googleTest\build_amd64test\gtest_main_use_own_tuple.vcxproj]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants