cmake: pre-fill HAVE_PIPE2 for two more platforms

For DragonFlyBSD and SunOS.

Also opt-in `BSD`, which is covering those listed explicitly, when using
CMake 3.25+.

Follow-up to 131a2fd5aa #16987

Closes #21243
This commit is contained in:
Viktor Szakats 2026-04-06 21:52:20 +02:00
parent 9f5d1a38d1
commit fc3261b284
No known key found for this signature in database

View File

@ -194,9 +194,12 @@ if(APPLE OR
CYGWIN)
set(HAVE_PIPE2 0)
elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR
BSD OR
CMAKE_SYSTEM_NAME STREQUAL "DragonFlyBSD" OR
CMAKE_SYSTEM_NAME STREQUAL "FreeBSD" OR
CMAKE_SYSTEM_NAME STREQUAL "NetBSD" OR
CMAKE_SYSTEM_NAME STREQUAL "OpenBSD")
CMAKE_SYSTEM_NAME STREQUAL "OpenBSD" OR
CMAKE_SYSTEM_NAME STREQUAL "SunOS")
set(HAVE_PIPE2 1)
endif()
set(HAVE_POLL 1)