Description
Amazon Linux 2 and CentOS 7 have a glibc that doesn’t support posix_spawn_file_actions_addchdir_np
and thus TSCBasic.Process
can’t launch a process on these platforms with the working directory set. We currently fall back to launching the index tasks without a working directory on these platforms, which I think is fine because SwiftPM gives us compiler arguments with absolute paths. But we should figure something out.
Using Foundation.Process
is not an option because it runs chdir
on the current process for Posix platforms, which is racy if there are multiple subprocesses being spawned simultaneously. On Windows TSCBasic.Processs
uses Foundation.Process
and Foundation.Process
properly set the working directory of the subprocesses on Windows, so Windows is not a problem.