Compiling with VS 2008 Pro (error C2064)

Added by prophetpro over 8 years ago

Hello Everyone,

Actually I am trying to compile server.sln, and after setting up my VS configuration I tried to compile it, but I got the following error :

------ Début de la génération : Projet : pd_lib, Configuration : Release Win32 ------
Compilation en cours...
reference_builder.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\include\xhash(600) : error C2064: le terme ne correspond pas à une fonction qui prend 2 arguments
la classe ne définit pas un 'operator()' ou un opérateur de conversion défini par l'utilisateur en pointeur de fonction ou référence de fonction qui accepte le nombre d'arguments approprié
C:\Program Files\Microsoft Visual Studio 9.0\VC\include\xhash(596) : lors de la compilation de la fonction membre '<Inconnu>' de la classe <Inconnu>
C:\Program Files\Microsoft Visual Studio 9.0\VC\include\hash_map(88) : voir la référence à l'instanciation de la classe modèle 'stdext::_Hash<_Traits>' en cours de compilation
with
[
_Traits=stdext::_Hmap_traits<RY_PDS::CColumnIndex,RY_PDS::TIndexList,RY_PDS::CColumnIndexHashMapTraits,std::allocator<std::pair<const RY_PDS::CColumnIndex,RY_PDS::TIndexList>>,false>
]
g:\ryzom\src\code\ryzom\server\src\pd_lib\../pd_lib/pd_utils.h(585) : voir la référence à l'instanciation de la classe modèle 'stdext::hash_map<_Kty,_Ty,_Tr>' en cours de compilation
with
[
_Kty=RY_PDS::CColumnIndex,
_Ty=RY_PDS::TIndexList,
_Tr=RY_PDS::CColumnIndexHashMapTraits
]
C:\Program Files\Microsoft Visual Studio 9.0\VC\include\xhash(602) : error C2064: le terme ne correspond pas à une fonction qui prend 2 arguments
la classe ne définit pas un 'operator()' ou un opérateur de conversion défini par l'utilisateur en pointeur de fonction ou référence de fonction qui accepte le nombre d'arguments approprié

I though that my STLport library was well-configured (I put the path to the global VS configuration, making the includes (for headers,libraries and binaries) at the top of the list) but it is like standart STL is used instead. Or maybe the issue is not related to the STLport library?

You can answer in french if you want,

Thank you in advance your help.

vs-setup.jpg - VS 2008 header include directory setup (61.8 kB)


Replies (4)

RE: Compiling with VS 2008 Pro (error C2064) - Added by sorlok_reaves over 8 years ago

Your error is odd; it seems to be a parameter error, which I definitely didn't get when building.

One thing that you might want to fix: some of the project files expect your external library code to be in a directory called "external".

There's a picture of how your includes should look on this page:
http://dev.ryzom.com/wiki/nel/CompilingOnWindows

If you can re-arrange your code to follow this guide (which is only a few changes) I might be able to help you if you keep getting the same error.

Or, stay tuned for someone who is more familiar with the stlport library. :)

RE: Compiling with VS 2008 Pro (error C2064) - Added by prophetpro over 8 years ago

Oh sorry, I found out what was the problem : I didn't have the SP1 installed for VS2008 :(
I was so sure that I had it...
It works better now.

Anyway, thank you for your (fast) answer sorlok_reaves :)

RE: Compiling with VS 2008 Pro (error C2064) - Added by kervala over 8 years ago

Normally, I fixed that today :) Did you update sources today ?

RE: Compiling with VS 2008 Pro (error C2064) - Added by prophetpro over 8 years ago

Actually, I downloaded the sources yesterday. That is probably why I met the issue (I think you referred to the fix of the BUG #845).
If I had known earlier that, I would have test your fix, but it is too late now because I have already installed SP1 :/

(1-4/4)