cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Asking about compiling libcurl with libssh2 in Windows VC98

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Sun, 21 Jan 2007 23:40:42 +0100 (CET)

On Sat, 20 Jan 2007, Anh Viet DAO wrote:

> How does Curl support SFTP and SCP in Windows ?

I'm not sure anyone has tried it yet. But please help us smoothen it out.

> I would to try to compile libcurl version snapshot 7.16.1-20070111, libcurl
> was compiled in static lib with parameter -DCURL_STATICLIB in Windows to use
> with others libraries.
>
> And the I add the following three parameters to compile libcurl in static
> mode with libssh2 /DUSE_LIBSSH2, /DHAVE_LIBSSH2 /DHAVE_LIBSSH2_H in my
> CFLAGS.

Sounds like a good start. The defines could of course also be added in
lib/config-win32.h if you'd prefer that.

> These parameters were added in file Makefile.vc6 in two directory
> $CURLROOT/lib and $CURLROOT/src the step of compilation with cl.exe was
> passed well. But in the step of linking with link.exe, i have had the
> problem of linking error as following :
>
> libcurl.lib(ssh.obj) : error LNK2001: unresolved external symbol
> _Curl_scp_recv libcurl.lib(ssh.obj) ... and other unresolved symbol

You haven't added lib/ssh.o to the makefile then so it hasn't compiled it and
doesn't link with it - which it must for the SSH-related protocols to work.

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2007-01-21