curl-library
RE: RE: Linker errors when statically compiled linking libcurl+openssl to my project
Date: Thu, 25 Aug 2011 14:57:47 +0300
('binary' encoding is not supported, stored as-is) ('binary' encoding is not supported, stored as-is) >Looking at rand_win.c it uses CreateDCA, CreateCompatiableDC(),
> GetDeciceCaps() etc... which are defined in gdi32.lib.
>
>
> These are defined in ws2_32.lib.
>
> What libraries is your application linking against? I'm not a MinGW
/
> Eclipse user but it looks like you will need to add gdi32.lib and
ws2_32.lib
> to your project.
>
>
ws2_32.lib was already linked, I added gdi32.lib. Errors decreased.
The following remain
>
>
g++ -DCURL_STATICLIB -DUSE_LIBSSH2 -DHAVE_LIBSSH2 -DCURL_DISABLE_LDAP
-DHAVE_LIBSSH2_H -DLIBSSH2_WIN32 -DLIBSSH2_LIBRARY -DUSE_SSLEAY -O0
-g3 -Wall -c -fmessage-length=0 -osrc\CURLDown.o ..\src\CURLDown.cpp
> ..\src\CURLDown.cpp:18: warning: 'int writer(char*, size_t, size_t,
std::string*)' defined but not used
g++ -L../lib -oCURLDown.exe src\CURLDown.o -lcurl -lcrypto -lws2_32
-lwldap32 -leay32 -lidn -lrtmp -lssh2 -lz -lssl32 -lssl -lgdi32
../lib/librtmp.a(rtmp.o):rtmp.c:(.text+0x1b3b): undefined reference to
`inet_addr_at_4'
../lib/librtmp.a(rtmp.o):rtmp.c:(.text+0x1ba4): undefined reference to
`inet_addr_at_4'
../lib/librtmp.a(rtmp.o):rtmp.c:(.text+0x5d1e): undefined reference to
`htonl_at_4'
../lib/librtmp.a(rtmp.o):rtmp.c:(.text+0x5eed): undefined reference to
`ntohl_at_4'
../lib/librtmp.a(rtmp.o):rtmp.c:(.text+0x6f9a): undefined reference to
`htonl_at_4'
../lib/librtmp.a(rtmp.o):rtmp.c:(.text+0x728d): undefined reference to
`htonl_at_4'
../lib/librtmp.a(rtmp.o):rtmp.c:(.text+0x732c): undefined reference to
`htonl_at_4'
../lib/librtmp.a(rtmp.o):rtmp.c:(.text+0x757f): undefined reference to
`ntohl_at_4'
../lib/librtmp.a(rtmp.o):rtmp.c:(.text+0xb45): undefined reference to
`timeGetTime_at_0'
../lib/librtmp.a(hashswf.o):hashswf.c:(.text+0x164): undefined
reference to `inet_addr_at_4'
('binary' encoding is not supported, stored as-is)
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-08-25