cURL / Mailing Lists / curl-library / Single Mail

curl-library

RE: Compiling and linking a libcurl app in UEFI

From: Sourjo Basu <SourjoB_at_ami.com>
Date: Fri, 29 Aug 2008 18:04:21 -0400

On Behalf Of Sourjo Basu
> > > main.obj : error LNK2019: unresolved external symbol
> __imp__curl_global_cleanup referenced in function _main
> > > main.obj : error LNK2019: unresolved external symbol
> __imp__curl_easy_cleanup referenced in function _main
> > > main.obj : error LNK2019: unresolved external symbol
> __imp__curl_easy_perform referenced in function _main
> > > main.obj : error LNK2019: unresolved external symbol
> __imp__curl_easy_setopt referenced in function _main
> > > main.obj : error LNK2019: unresolved external symbol
> __imp__curl_easy_init referenced in function _main
> > > main.obj : error LNK2019: unresolved external symbol
> __imp__curl_global_init referenced in function _main
> >
> > This isn't a regular Windows target, so the build procedure
> > might be a bit different. Did you build the library with
> > BUILDING_LIBCURL set?
>
> Here are my cflags for my libcurl.mak file:
> C_FLAGS = /D __STDC__ /D BUILDING_LIBCURL /D CURL_STATICLIB $(C_FLAGS)
>
> And here are my cflags and library options for my ftp proxy
> makefile: C_FLAGS = /D __STDC__ -DCURL_STATICLIB $(C_FLAGS)
> LIB_CURL_LIB =
> $(PROJECT_ROOT)\Build\$(SDK_BUILD_ENV)\THIRD_PARTY\libcurl\libcurl.lib
> LIBS = $(LIBS) $(LIB_CURL_LIB) \
> $(SDK_BUILD_DIR)\lib\libc\libc.lib \
> $(LIB_SOCKET_LIB) \
> $(SDK_BUILD_DIR)\lib\libefi\libefi.lib \
>
> I am still getting the same errors, I feel I am missing
> something simple here.. Any tips would be appreciated :)

Well I forced a #define CURL_EXTERN in curl.h to try and fix the static
library issue. But now I can't build the library anymore.. I am getting
tons of redifinition errors. Here is an attached error output file.

Regards,
Sourjo

Received on 2008-08-30