curl: Set build options the way we need for CMake

Also restore commit a8d91e2719 (curl: Precompile common expensive
headers, 2023-06-16) with new curl library target.
2 files changed