Take the 2-minute tour ×

I'm getting the following error when I compile my program which links to libtorrent.lib. I've tried compiling libtorrent with different settings, I've tried enabling/disabling DHT, deprecated functions, etc.

error LNK2019: unresolved external symbol "void __cdecl libtorrent::rel_performancetimer_pools_nolog_resolvecountries_deprecated_dht_ext_(void)"

Is anyone here familiar with libtorrent, or can anyone provide any advice for getting rid of this error? I don't see any other libraries that I need to link to.

Thanks in advance.

share|improve this question
possible duplicate of error LNK2019: unresolved external symbol "public: –  Eitan T Aug 14 '12 at 21:02

2 Answers 2

I've spent two days on it and finally I've found an issue. Name of this function "void rel_performancetimer_pools_nolog_resolvecountries_deprecated_dht_ext_" consists of the parts, that describes your current preferences. For example, dht_ means you're using DHT, and nolog_ means you're switched off TORRENT_LOGGING directive. The problem is: this settings works only with Release configuration! rel_ means release_. On the libtorrent 0.16.11 this problem still not solved. I've put this text in file build_config.hpp on the line 40:

#ifdef _DEBUG

This is the way to compile my project with libtorrent in release and debug configurations, without making any corrections. Arvid, please, include this 3 lines to your next version of libtorrent. Appreciated, Ilya from Russia.

share|improve this answer
Arvid forgot to pay for the DNS name registration. –  Prof. Falken Sep 11 '13 at 6:28
up vote 0 down vote accepted

The problem was that my definitions in my project were inconsistent with the configuration/definitions in the libtorrent compilation, so some macros were calling a function that doesn't exist.

share|improve this answer

Your Answer


