Skip to content

Commit 4d2834e

Browse files
dschoGit for Windows Build Agent
authored andcommitted
cmake: use writev(3p) wrapper as needed
This is a companion patch of 3b9b2c2 (compat/posix: introduce writev(3p) wrapper, 2026-03-13) where support for using the `writev()` wrapper was introduced in the `Makefile` and the Meson-based build, but the CMake build still needs that treatment, too. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
1 parent bbfde3b commit 4d2834e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

contrib/buildsystems/CMakeLists.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -414,7 +414,7 @@ endif()
414414
#function checks
415415
set(function_checks
416416
strcasestr memmem strlcpy strtoimax strtoumax strtoull
417-
setenv mkdtemp poll pread memmem)
417+
setenv mkdtemp poll pread memmem writev)
418418

419419
#unsetenv,hstrerror are incompatible with windows build
420420
if(NOT WIN32)
@@ -459,6 +459,10 @@ if(NOT HAVE_MEMMEM)
459459
list(APPEND compat_SOURCES compat/memmem.c)
460460
endif()
461461

462+
if(NOT HAVE_WRITEV)
463+
list(APPEND compat_SOURCES compat/writev.c)
464+
endif()
465+
462466
if(NOT WIN32)
463467
if(NOT HAVE_UNSETENV)
464468
list(APPEND compat_SOURCES compat/unsetenv.c)

0 commit comments

Comments
 (0)