-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[MSVC] ROOT_x86 failed due to libCling.exp : error LNK2001: unresolved external symbol "char const * __cdecl __std_find_trivial<char const ,char>(char const *,char const *,char) #15336
Comments
@SyahmieS it is maybe related to #15321 and #9445
|
I just tried with ROOT master and it works with the following commands:
|
In absence of an answer and the ability to reproduce, I am closing. Please feel free to re-open if I misunderstand the status of this issue. |
Hi @bellenot @dpiparo , thank you for your reply. Yes, we tried to build with VS2022 17.9.6 Release and there was indeed no such issue. However, we are actually testing an unreleased version of VS with an open source project, which means an unreleased MSVC. But this problem still exists. And we got some information from the MSVC team as follows. Failing (latest prod/be): Passing (17.9.6): It looks like ROOT manually adds exports in their cmake build steps: root/core/metacling/src/CMakeLists.txt at master · root-project/root · GitHub
I think the first four lines need to get updated with the new undecorated names, but I'm not sure what exactly they need or why those specific implementations are being exported right now. Actual Result: |
Can you tell us what exact version of Visual Studio you are using? I tried ROOT master with the v17.11.0-pre.1.1 without problem. I will not be able to fix the issue until I can reproduce it... |
Thank you for your quick response, @bellenot. The version of VS we use is not important, we just need to test the compiler MSVC inside VS, the compiler version is the latest, not release or preview. it's development version. And the correct MSVC_VERSION as below. Microsoft (R) C/C++ Optimizing Compiler Version 19.41.34007.96 for x64 |
@spacelg then there is nothing we can do for the time being. We'll have to wait until the compiler is available for testing. Please ping us when it is available, so we can fix the issue before the public release. |
@spacelg Let me try something... I'll keep you updated |
@bellenot , thank you very much for your reply and information, if there is any workaround info, we will try it. |
So you can try to filer out the symbols using the CMake variable
|
Hi @bellenot , thank you very much for the workaround you provided, after testing, it works for us. |
You're very welcome! And thanks for the feedback! |
Fixes root-project#15336 Fix the following compilation errors with Visual Studio v17.10 on x86 ``` libCling.exp : error LNK2001: unresolved external symbol "char const * __cdecl __std_find_trivial<char const ,char>(char const *,char const *,char)" (??$__std_find_trivial@$$CBDD@@YAPBDPBD0D@Z) [C:\ root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "char * __cdecl __std_find_trivial<char,char>(char *,char *,char)" (??$__std_find_trivial@DD@@YAPADPAD0D@Z) [C:\root-dev\build\x86\release\co re\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "int * __cdecl __std_find_trivial<int,int>(int *,int *,int)" (??$__std_find_trivial@HH@@YAPAHPAH0H@Z) [C:\root-dev\build\x86\release\core\met acling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "unsigned int * __cdecl __std_find_trivial<unsigned int,int>(unsigned int *,unsigned int *,int)" (??$__std_find_trivial@IH@@YAPAIPAI0H@Z) [C: \root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] C:\root-dev\build\x86\release\bin\libCling.dll : fatal error LNK1120: 4 unresolved externals [C:\root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] ```
Fixes #15336 Fix the following compilation errors with Visual Studio v17.10 on x86 ``` libCling.exp : error LNK2001: unresolved external symbol "char const * __cdecl __std_find_trivial<char const ,char>(char const *,char const *,char)" (??$__std_find_trivial@$$CBDD@@YAPBDPBD0D@Z) [C:\ root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "char * __cdecl __std_find_trivial<char,char>(char *,char *,char)" (??$__std_find_trivial@DD@@YAPADPAD0D@Z) [C:\root-dev\build\x86\release\co re\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "int * __cdecl __std_find_trivial<int,int>(int *,int *,int)" (??$__std_find_trivial@HH@@YAPAHPAH0H@Z) [C:\root-dev\build\x86\release\core\met acling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "unsigned int * __cdecl __std_find_trivial<unsigned int,int>(unsigned int *,unsigned int *,int)" (??$__std_find_trivial@IH@@YAPAIPAI0H@Z) [C: \root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] C:\root-dev\build\x86\release\bin\libCling.dll : fatal error LNK1120: 4 unresolved externals [C:\root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] ```
Fixes root-project#15336 Fix the following compilation errors with Visual Studio v17.10 on x86 ``` libCling.exp : error LNK2001: unresolved external symbol "char const * __cdecl __std_find_trivial<char const ,char>(char const *,char const *,char)" (??$__std_find_trivial@$$CBDD@@YAPBDPBD0D@Z) [C:\ root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "char * __cdecl __std_find_trivial<char,char>(char *,char *,char)" (??$__std_find_trivial@DD@@YAPADPAD0D@Z) [C:\root-dev\build\x86\release\co re\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "int * __cdecl __std_find_trivial<int,int>(int *,int *,int)" (??$__std_find_trivial@HH@@YAPAHPAH0H@Z) [C:\root-dev\build\x86\release\core\met acling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "unsigned int * __cdecl __std_find_trivial<unsigned int,int>(unsigned int *,unsigned int *,int)" (??$__std_find_trivial@IH@@YAPAIPAI0H@Z) [C: \root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] C:\root-dev\build\x86\release\bin\libCling.dll : fatal error LNK1120: 4 unresolved externals [C:\root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] ```
Fixes #15336 Fix the following compilation errors with Visual Studio v17.10 on x86 ``` libCling.exp : error LNK2001: unresolved external symbol "char const * __cdecl __std_find_trivial<char const ,char>(char const *,char const *,char)" (??$__std_find_trivial@$$CBDD@@YAPBDPBD0D@Z) [C:\ root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "char * __cdecl __std_find_trivial<char,char>(char *,char *,char)" (??$__std_find_trivial@DD@@YAPADPAD0D@Z) [C:\root-dev\build\x86\release\co re\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "int * __cdecl __std_find_trivial<int,int>(int *,int *,int)" (??$__std_find_trivial@HH@@YAPAHPAH0H@Z) [C:\root-dev\build\x86\release\core\met acling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "unsigned int * __cdecl __std_find_trivial<unsigned int,int>(unsigned int *,unsigned int *,int)" (??$__std_find_trivial@IH@@YAPAIPAI0H@Z) [C: \root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] C:\root-dev\build\x86\release\bin\libCling.dll : fatal error LNK1120: 4 unresolved externals [C:\root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] ```
Fixes root-project#15336 Fix the following compilation errors with Visual Studio v17.10 on x86 ``` libCling.exp : error LNK2001: unresolved external symbol "char const * __cdecl __std_find_trivial<char const ,char>(char const *,char const *,char)" (??$__std_find_trivial@$$CBDD@@YAPBDPBD0D@Z) [C:\ root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "char * __cdecl __std_find_trivial<char,char>(char *,char *,char)" (??$__std_find_trivial@DD@@YAPADPAD0D@Z) [C:\root-dev\build\x86\release\co re\metacling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "int * __cdecl __std_find_trivial<int,int>(int *,int *,int)" (??$__std_find_trivial@HH@@YAPAHPAH0H@Z) [C:\root-dev\build\x86\release\core\met acling\src\Cling.vcxproj] libCling.exp : error LNK2001: unresolved external symbol "unsigned int * __cdecl __std_find_trivial<unsigned int,int>(unsigned int *,unsigned int *,int)" (??$__std_find_trivial@IH@@YAPAIPAI0H@Z) [C: \root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] C:\root-dev\build\x86\release\bin\libCling.dll : fatal error LNK1120: 4 unresolved externals [C:\root-dev\build\x86\release\core\metacling\src\Cling.vcxproj] ```
Check duplicate issues.
Description
Hi all,
[MSVC] ROOT_x86 failed due to failed due to libCling.exp : error LNK2001: unresolved external symbol "char const * __cdecl __std_find_trivial<char const ,char>(char const *,char const *,char). It can be reproduced on this commit
1f86c24
Could you please help look at this issue? Thanks in advance!Reproducer
Steps to reproduce the behavior:
Error Message: After updating the hash commit, ROOT_amd64 passed but ROOT_X86 failed with the following error:
libCling.exp : error LNK2001: unresolved external symbol "char const * __cdecl __std_find_trivial<char const ,char>(char const *,char const *,char)"
What is the expected behaviour?
Project Pass
Operating System
Windows
What versions of the operating systems?
VS 2022 + Windows Server 2022 Datacenter
Architectures
86-bit
Stacktrace
No response
Plug-in formats (if applicable)
No response
Plug-in host applications (DAWs) (if applicable)
No response
Testing on the develop branch
The bug is present on the develop branch.
ROOT version
N/A
Installation method
N/A
Operating system
Windows
Additional context
No response
The text was updated successfully, but these errors were encountered: