On Fri, Aug 3, 2018 at 5:12 PM, Martin Dušek <[email protected]> wrote:
> Hi,
> I built Crypto++ 7 using msvc2013, release dll. I linked it to my msvc2013
> Qt app. If my app is built in release mode it runs. When I build it in debug
> configuration, linker outputs several LNK2005 errors:
>
> cryptopp.lib(cryptopp.dll):-1: error: LNK2005: "public: static char const *
> __cdecl CryptoPP::SHA256::StaticAlgorithmName(void)"
> (?StaticAlgorithmName@SHA256@CryptoPP@@SAPBDXZ) already defined in hwid.obj
>
> cryptopp.lib(cryptopp.dll):-1: error: LNK2005: "public: __thiscall
> CryptoPP::NotImplemented::NotImplemented(class std::basic_string<char,struct
> std::char_traits<char>,class std::allocator<char> > const &)"
> (??0NotImplemented@CryptoPP@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z)
> already defined in config.obj
>
> cryptopp.lib(cryptopp.dll):-1: error: LNK2005: "public: unsigned int
> __thiscall CryptoPP::BufferedTransformation::Put(unsigned char const
> *,unsigned int,bool)" (?Put@BufferedTransformation@CryptoPP@@QAEIPBEI_N@Z)
> already defined in config.obj
>
> I also trie to build debug cryptopp dll and link it with my app in debug
> configuration - with the same result.
>
> What is wrong with my app or cryptopp build?

The DLL is a special purpose FIPS DLL. It is missing most general
classes. It only has classes for FIPS algorithms. You still have to
link to cryptlib.lib to get the missing classes. Also see
https://www.cryptopp.com/wiki/FIPS_DLL.

You should link to the static library. _IF_ you really want a DLL then
create a wrapper DLL than links to the static library.

I want to delete the projects because (1) the DLL is on the Historical
Validation List so it is no longer valid; and (2) it is a constant
source of problems for users.

Jeff

-- 
You received this message because you are subscribed to "Crypto++ Users". More 
information about Crypto++ and this group is available at 
http://www.cryptopp.com and 
http://groups.google.com/forum/#!forum/cryptopp-users.
--- 
You received this message because you are subscribed to the Google Groups 
"Crypto++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to