Hash :
8cf7746a
Author :
Date :
2020-12-24T22:14:38
posix_spawn* tests: Add support for native Windows. * tests/test-posix_spawn-open1.c (DATA_FILENAME): Treat native Windows like Cygwin. * tests/test-posix_spawn-dup2-stdin.c (main): Don't assume the signals SIGHUP and SIGPIPE. On native Windows, don't call posix_spawnattr_setsigmask. * tests/test-posix_spawn-dup2-stdout.c (main): Likewise. * tests/test-posix_spawn-fchdir.c (main): Likewise. * tests/test-posix_spawn-chdir.c (test): Likewise. Accept the child output from Cygwin's 'pwd' program. * tests/test-posix_spawn-script.c (main): On native Windows, skip the executable-shell-script part of the test. * tests/test-posix_spawnp-script.c (main): Likewise. * modules/posix_spawn-tests (Depends-on): Add freopen, waitpid. (configure.ac): Don't define the POSIX_SPAWN_PORTED conditional. (Makefile.am): Don't test the POSIX_SPAWN_PORTED conditional. * modules/posix_spawnp-tests (Depends-on): Add waitpid. (configure.ac): Don't define the POSIX_SPAWN_PORTED conditional. (Makefile.am): Don't test the POSIX_SPAWN_PORTED conditional. * modules/posix_spawn_file_actions_addchdir-tests (Makefile.am): Don't test the POSIX_SPAWN_PORTED conditional. * modules/posix_spawn_file_actions_addfchdir-tests (configure.ac): Define the POSIX_SPAWN_PORTED conditional here.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
Files:
tests/test-posix_spawn-open1.c
tests/test-posix_spawn-open2.c
tests/test-posix_spawn-inherit0.c
tests/test-posix_spawn-inherit1.c
tests/test-posix_spawn-script.c
tests/executable-script
tests/executable-script.sh
tests/executable-shell-script
tests/signature.h
Depends-on:
posix_spawn_file_actions_init
posix_spawn_file_actions_addopen
posix_spawn_file_actions_destroy
stdbool
unistd
sys_wait
environ
fflush
freopen
waitpid
configure.ac:
Makefile.am:
TESTS += \
test-posix_spawn-open1 \
test-posix_spawn-open2 \
test-posix_spawn-inherit0 \
test-posix_spawn-inherit1 \
test-posix_spawn-script
check_PROGRAMS += \
test-posix_spawn-open1 \
test-posix_spawn-open2 \
test-posix_spawn-inherit0 \
test-posix_spawn-inherit1 \
test-posix_spawn-script
test_posix_spawn_script_CPPFLAGS = $(AM_CPPFLAGS) -DSRCDIR=\"$(srcdir)/\"