Skip to content

Error in VS 2022 #56

Open
Open
@JekSun97

Description

@JekSun97

I built libcurl 8.8.0, connected it to your library, and successfully built ftpclient.lib, now I created a project for testing, connected the library, but when I run it I get the following errors:

1>ftpclient.lib(FTPClient.obj) : error LNK2001: unresolved external symbol __imp__curl_slist_append.
1>ftpclient.lib(FTPClient.obj) : error LNK2001: unresolved external symbol __imp__curl_slist_free_all.
1>ftpclient.lib(FTPClient.obj) : error LNK2001: unresolved external symbol __imp__curl_easy_strerror.
1>ftpclient.lib(FTPClient.obj) : error LNK2001: unresolved external symbol __imp__curl_easy_init.
1>ftpclient.lib(FTPClient.obj) : error LNK2001: unresolved external symbol __imp__curl_easy_setopt.
1>ftpclient.lib(FTPClient.obj) : error LNK2001: unresolved external symbol __imp__curl_easy_perform.
1>ftpclient.lib(FTPClient.obj) : error LNK2001: unresolved external symbol __imp__curl_easy_cleanup.
1>ftpclient.lib(FTPClient.obj) : error LNK2001: unresolved external symbol __imp__curl_easy_getinfo.
1>ftpclient.lib(FTPClient.obj) : error LNK2001: unresolved external symbol __imp__curl_easy_reset.
1>ftpclient.lib(CurlHandle.obj) : error LNK2001: unresolved external symbol __imp__curl_global_init.
1>ftpclient.lib(CurlHandle.obj) : error LNK2001: unresolved external symbol __imp__curl_global_cleanup.
1>C:\Users\FireRun\Desktop\ftp\ftp\Release\ftp.exe : fatal error LNK1120: unresolved external elements: 11

For testing I used minimal code:

#include <iostream>
#include "FTP/FTPClient.h"
#pragma comment(lib, "ftpclient.lib")

int main()
{
    embeddedmz::CFTPClient FTPClient([](const std::string& strLogMsg) { std::cout << strLogMsg << std::endl; });
    std::cout << "Hello World!\n";
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions