0

I am getting the following error when building my project:

LNK2019 unresolved external symbol __imp_curl_global_init referenced in function twilio_send_message    extendedPoke    C:\Dev\ts3Plugin-ExtendedPoke\src\twilio.obj    1   

Which lead me looking into the external dependencies folder in my IDE (Visual Studio). There I can open the curl.h header and if I hover over the functions I get the error "Function definition for 'curl_global_init' not found".

I have already added the Curl include folder in Properties -> C/C++ -> General -> Additional Include Directories. Added the Curl lib folder in Properties -> Linker -> General -> Additional Library Directories and added the Curl lib in Properties -> Linker -> Input -> Additional Dependencies.

Am I missing something?

  • Including the header tells the compiler about the function. You also have to tell the linker to link with the right library on the command line. 'Unresolved external symbol' means you've not done that. – Jonathan Leffler Sep 07 '22 at 21:39
  • @JonathanLeffler https://i.imgur.com/L0f1fnH.png https://i.imgur.com/MucJnFf.png https://i.imgur.com/2Vij7MU.png I followed some tutorials and i could not find more options then theese three. Am I missing some linking? I thought thats all. – CodeEnjoyer Sep 07 '22 at 21:46
  • I have found the solution to my problem. I have compiled the libcurl.lib in a command prompt with a x86 environment. But I needed it in a x64 environment. https://learn.microsoft.com/en-us/cpp/build/how-to-enable-a-64-bit-visual-cpp-toolset-on-the-command-line?view=msvc-170 – CodeEnjoyer Sep 08 '22 at 17:04
  • Congratulations. – Jonathan Leffler Sep 08 '22 at 21:05

0 Answers0