curl/CMake
Viktor Szakats fbcce4da85
build: enable thread-safe getaddrinfo() for OpenBSD, and other tidy-ups
Aka `HAVE_GETADDRINFO_THREADSAFE`.

- enable it for OpenBSD 5.4+ (2013-11-01).
  Also adjust cmake pre-fill.

- explicitly opt-in DragonFly BSD, for 2.2.0+ (2009-02-17).
  Assuming this commit implemented this feature:
  21fcee4d6e (diff-498ff649e8770eb9a94e99a399a4b473fcea41ef58b033a2a2dae3809e17bb04)
  Prior to this patch it was enabled in autotools by accident, because
  its host ID misses `bsd` so the global BSD disable was not applied.

- autotools: fix to enable for Darwin 9+ / macOS 10.5+ (2007-10-26).
  Prior to this patch it was Darwin 6 / macOS 10.2.
  Source: https://github.com/python/cpython/issues/70112
  Ref: https://en.wikipedia.org/wiki/MacOS_version_history
  10.5 was the first one UNIX '03 certified, which requires this
  feature. iOS and others were forked from this codebase, so they also
  have support.

- cmake: add version numbers as comments.
  Sadly the OS versions are not verified. This and the autotools logic
  could possibly be implemented in `curl-setup.h` more accurately, for
  all build systems, without duplicating logic.

Also:
- cmake: `BSD` variable requires CMake 3.25+, add fallback code where
  missing.
  Ref: https://cmake.org/cmake/help/v3.25/variable/BSD.html
- unix-cache.cmake: stop listing all BSDs for `HAVE_PIPE2`,
  and fix generic BSD filter for CMake <3.25.
- unix-cache.cmake: stop listing all BSDs, since it's prefilled anyway
  for those via `OtherTests.cmake`.

Ref: https://github.com/curl/curl/pull/22138#issuecomment-4773617195

Closes #22148
2026-06-25 11:32:36 +02:00
..
cmake_uninstall.in.cmake cmake: match filename suffixes with file content 2025-12-20 11:34:27 +01:00
curl-config.in.cmake cmake: quote COMPONENTS string in curl-config.in.cmake 2026-05-20 19:24:50 +02:00
CurlSymbolHiding.cmake build: merge TrackMemory (CURLDEBUG) into debug-enabled option 2026-01-19 18:43:17 +01:00
CurlTests.c tidy-up: miscellaneous 2026-05-16 01:56:17 +02:00
FindBrotli.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindCares.cmake cmake: add CMake Config-based dependency detection for c-ares, wolfSSL 2026-03-26 11:20:03 +01:00
FindGnuTLS.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindGSS.cmake cmake/FindGSS: drop CMake <3.16 compatibility logic 2026-06-17 18:38:46 +02:00
FindLDAP.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindLibbacktrace.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindLibgsasl.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindLibidn2.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindLibpsl.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindLibssh.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindLibssh2.cmake cmake: add CMake Config-based dependency detection 2026-03-21 18:52:31 +01:00
FindLibuv.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindMbedTLS.cmake cmake: add CMake Config-based dependency detection 2026-03-21 18:52:31 +01:00
FindNettle.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindNGHTTP2.cmake cmake: auto-select static nghttp2/nghttp3/ngtcp2 Config 2026-05-11 11:57:25 +02:00
FindNGHTTP3.cmake cmake: auto-select static nghttp2/nghttp3/ngtcp2 Config 2026-05-11 11:57:25 +02:00
FindNGTCP2.cmake cmake: export/forward NGTCP2_CRYPTO_BACKEND 2026-05-11 21:53:39 +02:00
FindQuiche.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindRustls.cmake cmake: drop support for CMake 3.17 and older 2026-03-21 13:24:47 +01:00
FindWolfSSL.cmake cmake: add CMake Config-based dependency detection for c-ares, wolfSSL 2026-03-26 11:20:03 +01:00
FindZstd.cmake cmake: fix zstd CMake config name 2026-05-11 12:08:32 +02:00
Macros.cmake cmake: simplify LINK_ONLY imported target extraction 2026-06-17 15:16:19 +02:00
OtherTests.cmake build: enable thread-safe getaddrinfo() for OpenBSD, and other tidy-ups 2026-06-25 11:32:36 +02:00
PickyWarnings.cmake build: enable -Wlogical-op picky warning for GCC 4.4+ 2026-06-12 23:37:37 +02:00
unix-cache.cmake build: enable thread-safe getaddrinfo() for OpenBSD, and other tidy-ups 2026-06-25 11:32:36 +02:00
Utilities.cmake cmake: fix LOCATION property access condition (debug) 2026-03-06 15:35:27 +01:00
win32-cache.cmake src: drop detecting and redefining system symbol ftruncate 2026-03-30 13:46:14 +02:00