I don't need proxy authentication, but SSL and I want to use the new SChannelAPI support, so I have defined both CURL_DISABLE_PROXY and USE_WINDOWS_SSPI. This results in a compile error in socks.c.
The line '#if !defined(CURL_DISABLE_PROXY) || defined(USE_WINDOWS_SSPI)' in socks.c should be changed to only '#if !defined(CURL_DISABLE_PROXY)' to resolve the error.
What compiler error?
And if you switch off the compiling of these functions, how can the socks_sspi.c source compile error free? It uses Curl_blockread_all() so I figure that file needs an adjusted #ifdef line as well?
The error is double definition of Curl_SOCKS4 and Curl_SOCKS5 (as CURLE_NOT_BUILT_IN in the header file and as a function in the .c file).
socks_sspi.c compiles without errors when I compile libcurl as a static library as Curl_SOCKS5_gssapi_negotiate is never called in my application. But you're right, the #ifdef line in socks_sspi.c should also be changed to '#if (defined(USE_WINDOWS_SSPI) && !defined(CURL_DISABLE_PROXY))'.
Patch for socks.c and socks_sspi.c
I have attached a patch that fixes the problem.
Thanks for the report, this problem is now fixed in the git repository.
To try it out, you either checkout/update your git clone: http://curl.haxx.se/source.html
or you try tomorrow's daily snapshot: http://curl.haxx.se/snapshots/