Hi Thomas and Thank you very much!

I changed csp.c->csp.cpp and those errors have been removed;
but now I have a link error about "autoreg.cpp" file which is here:

autoreg.obj : error LNK2001: unresolved external symbol _g_hModule
F:\csp\Debug\csp.dll : fatal error LNK1120: 1 unresolved externals

Could you guide me again how I can remove this error?

Meanwhile,because my Csp is a Smart Card CSP,I uncomment "#define
SCARD_CSP" line in autoreg.cpp,and add "winscard.lib" to my project,

Do you have any experience about using and working with "autoreg.cpp"
in CSPDK?

I posted my questions about this to Microsoft discussions but no one
helped me,so I had to ask you here?!!

Please help me again,
Best Regards.
Gary

On May 27, 6:20 pm, "Thomas Harning Jr." <[email protected]> wrote:
> On Wed, May 27, 2009 at 9:36 AM, Gary <[email protected]> wrote:
>
> > Hello!
>
> > I'm implementing a Smart Card CSP(Cryptographic Service Provider).
> > but I've not used of Windows Cryptographic Functions(in
> > "wincrypt.h"),I've add "CryptoPP
> > 5.5.2" library to my CSP for cryptographic operations.
>
> > (I downloaded "CSPDK" package of microsoft site and I use of Visual C+
> > + 2008;)
>
> > My custom cryptographic codes are all ready,but I have several
> > problems in final building
> > and producing csp.dll and csp.lib files!
>
> > I add the "CryptoPP" library and it's necessary header files to my CSP
> > project,but when
> > compiling it,I get 102 confusing errors which some of them are here:
>
> > ------ Build started: Project: csp, Configuration: Debug Win32 ------
> > Compiling...
> > csp.c
> > d:\cryptopp\config.h(102) : error C2061: syntax error : identifier
> > 'CryptoPP'
>
> Off the top of my head... it's a ".c" file ...  windows will compile
> that as C, not C++, therefore including C++ code will break the
> parser/compiler.  You'll want to rename csp.c -> csp.cpp (and make
> sure any symbols being exported are properly marked extern "C" (and
> the like)
> --
> Thomas Harning Jr.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" 
Google Group.
To unsubscribe, send an email to [email protected].
More information about Crypto++ and this group is available at 
http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---

Reply via email to