There is an apparent bug in Windows 11 (not Windows 10) where,
when reading from an fd backed by the Console, a single
return character will always be available.
* libguile/posix-w32.c (console_has_return_keyevent_w32): new procedure
* libguile/posix-w32.h: declare console_has_return_keyevent_w32
* libguile/fports.c [__MINGW32__](fport_input_waiting): ignore return keyevent
Now that Guile uses the posix_spawn gnulib module, several of Guile's
custom w32 functions substitutes no longer work. Some functions
relied on populating and maintaining an internal PID-to-Handle database,
which is no longer possible.
kill, getpriority, setpriority, getaffinity and setaffinity
are removed. waitpid is simplified and does not handle ENOHANG.
* NEWS: updated
* libguile/posix-w32.c (struct proc_record, find_proc, proc_handle): removed
(record_proc, delete_proc, prepare_child_handle, compenv): removed
(prepare_envblk, lookup_cmd, prepare_cmdline, start_child): removed
(kill, getpriority, setpriority, sched_getaffinity): removed
(sched_setaffinity): removed
(waitpid): modified to just use _cwait. ENOHANG emlation removed.
* libguile/posix-w32.h (CPU_ZERO, CPU_ISSET, CPU_SET, CPU_SETSIZE): removed
(cpu_set_t, PRIO_PROCESS, PRIO_PGRP, PRIO_USER): removed
(HAVE_START_CHILD, HAVE_KILL, HAVE_GETPRIORITY): removed
(HAVE_SETPRIORITY, HAVE_SCHED_GETAFFINITY, HAVE_SCHED_SETAFFINITY): removed
declarations for waitpid, start_child, kill, getpriority: removed
declarations for setpriority, sched_getaffinity, sched_set_affinity: Removed
* libguile/posix-w32.c (getpagesize_w32): new procedure
* libguile/posix-w32.h: declaration of getpagesize_w32
* libguile/loader.c [__MINGW32__](scm_bootstrap_loader): use new procedure
* libguile/vm.c [__MINGW32__](scm_i_vm_prepare_stack): use new procedure
As the FSF advises, 'There is no legal significance to using the
three-character sequence “(C)”, but it does no harm.' It does take up
space though! For that reason, we remove it here from our C files.
* libguile/posix-w32.h:
* libguile/posix-w32.c (kill, waitpid, getpriority, setpriority)
(sched_getaffinity, sched_setaffinity): Add MinGW implementations.
Also, provides macros that on Posix hosts are in sys/wait.h, like
WIFEXITED and WTERMSIG.
(start_child): Add implementation.