A compilation problem when using templates

Hello life savers,

I'm having trouble compiling a specific program. The program was originally written for gcc and was compiled successfully under it. When trying to compile under Solaris 11, I get this error:

"Hashtable.h", line 170: Error: Could not find a match for hash needed in Hashtable<long long, Orderbook*>::get(long long).
"ReferenceData.cpp", line 59: Where: While instantiating "Hashtable<long long, Orderbook*>::get(long long)".
"ReferenceData.cpp", line 59: Where: Instantiated from non-template code.

line 170 of file "Hashtable.h" is:
int tIndex = (hash(pKey,mSize));

(line 59 of "ReferenceData.cpp" is using it).

The "hash" functions are global, and are defined as followed:

static int hash( int64 pValue, int pMod )
{
int tValue = (int) (pValue & 0x7FFFFFFF);
return (tValue % pMod);
}

static int hash( int pValue, int pMod )
{
return (pValue % pMod);
}

static int hashString( const char *pStr, int pMod )
{
int tLen = (int) strlen( pStr );
unsigned int hash = 0;
unsigned int x = 0;

for(int i = 0; i < tLen; pStr++, i++)
{
hash = (hash << 4) + (*pStr);
if((x = hash & 0xF0000000L) != 0)
{
hash ^= (x >> 24);
}
hash &= ~x;
}

return (int) (hash % pMod);
}

static int hash( const std::string *pStr, int pMod )
{
return hashString( pStr->c_str(), pMod );
}

static int hash( const char *pStr, int pMod )
{
return hashString( pStr, pMod );
}

Please tell me if the pasted code is enough or you need the entire class code for finding what's wrong (didn't want to paste the whole thing. it's long....).

Thanks a lot.
yp515.

i) There is no Solaris 11 (do you mean Sun Studio 11 Compilers?)
ii) assuming you've used gcc on linux-x64 to develop that code: gcc is available for solaris-sparc - get this one and you should be fine

I do mean Sun Studio 11 Compilers.....
Using gcc is not an option. This is a 3rd party code which should be integrated into an existing project which uses Sun Solaris 11.

Why are you suggesting gcc? is there a problem with Sun Studio 11 regarding templates?