curl / Mailing Lists / curl-library / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

About building curl with libssh on Windows by MSVC

From: ÃÎÖÕÎÞºÛ via curl-library <curl-library_at_lists.haxx.se>
Date: Fri, 25 Feb 2022 20:19:59 +0800

Hi,
&nbsp;&nbsp;&nbsp; I meet some questions while trying to build curl on Windows. According to documents, my steps were:
&nbsp;&nbsp;&nbsp; 1.&nbsp;vcvars64.bat
&nbsp;&nbsp;&nbsp; 2. cd curl/winbuild
&nbsp;&nbsp;&nbsp; 3. nmake -f ./Makefile.vc MACHINE=X64 mode=dll WITH_DEVEL=/path/to/deps WITH_SSH=dll ....(other parameters)


&nbsp;&nbsp;&nbsp; And my enviromnent was:
&nbsp;&nbsp;&nbsp; OS:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Windows 10.0.22000.527
&nbsp;&nbsp;&nbsp; MSVC compiler from VS2019:&nbsp;&nbsp; 16.11.10
&nbsp;&nbsp;&nbsp; curl:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 7.81.0
&nbsp;&nbsp;&nbsp; libssh:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0.9.6



&nbsp;&nbsp;&nbsp; Then I found it couldn't work because 'WITH_SSH' is not a proper parameter. It seems only support 'WITH_SSH2' but not 'WITH_SSH'.
&nbsp;&nbsp;&nbsp; So I tried to modify the curl/winbuild/Makefile.vc. After inserting necessary environment variables to file, such as 'USE_LIBSSH' and 'HAVE_LIBSSH_LIBSSH_H', I built it again. But I got a new error: ..\lib\vssh\libssh.c(88): fatal error C1083: cannot open include file: "unistd.h": No such file or directory


&nbsp;&nbsp;&nbsp; Does it mean curl only support libssh on linux?



Thanks sincerely,
Li
Ñ


-- 
Unsubscribe: https://lists.haxx.se/listinfo/curl-library
Etiquette:   https://curl.haxx.se/mail/etiquette.html
Ñ
Received on 2022-02-25