You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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.
The text was updated successfully, but these errors were encountered:
Details from apple#1271
> 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.
rdar://127797048
Amazon Linux 2 and CentOS 7 have a glibc that doesn’t support
posix_spawn_file_actions_addchdir_np
and thusTSCBasic.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 runschdir
on the current process for Posix platforms, which is racy if there are multiple subprocesses being spawned simultaneously. On WindowsTSCBasic.Processs
usesFoundation.Process
andFoundation.Process
properly set the working directory of the subprocesses on Windows, so Windows is not a problem.The text was updated successfully, but these errors were encountered: