ygrek / ocurl

OCaml bindings to libcurl
https://ygrek.org/p/ocurl
MIT License
59 stars 32 forks source link

Enable `configure` to generate `config.h` on Windows #53

Closed nojb closed 2 years ago

nojb commented 3 years ago

Producing config.h for the Windows version of libcurl is an error-prone manual process. It would be nice to use configure for that.

To enable this I modified the configure script so that one can manually specify the variables CURLCFLAGS, CURLLIBS and LIBCURL_VERSION. NB: this is not enough to get a working Makefile, only to get an accurate config.h, so this feature should probably be left undocumented for the time being.

I tested with the official upstream Windows build of libcurl https://curl.se/windows/ and the MSVC compiler.

ygrek commented 2 years ago

Didn't test on windows, but it looks straightforwardly correct and appveyor build passes, so I will trust you that it works :) Cherry-picked as e99ddbcb54be7d11851cbfb9f8fd84a1ea9ffa46, thanks!