Re: Crashes in cmake subprocesses since 3.6.0

2025-04-03 Thread Takashi Yano via Cygwin
On Wed, 2 Apr 2025 23:41:46 -0700 (PDT) Jeremy Drake wrote: > On Thu, 3 Apr 2025, Takashi Yano via Cygwin wrote: > > > It seems that raw_write() is called before returning from > > pthread::atforkchild() in fork::child(). > > > > Moving _my_tls.fixup_after_fork() before atforkchild() seems > > to

Re: Crashes in cmake subprocesses since 3.6.0

2025-04-02 Thread Jeremy Drake via Cygwin
On Thu, 3 Apr 2025, Takashi Yano via Cygwin wrote: > It seems that raw_write() is called before returning from > pthread::atforkchild() in fork::child(). > > Moving _my_tls.fixup_after_fork() before atforkchild() seems > to solve the issue. > > What about: > ld_preload (); > fixup_hooks_after_fork

Re: Crashes in cmake subprocesses since 3.6.0

2025-04-02 Thread Takashi Yano via Cygwin
On Thu, 3 Apr 2025 12:32:35 +0900 Takashi Yano wrote: > > Still, I wonder in which thread raw_write is running during fork(). > > Weird enough, raw_write() is called in the main thread (_main_tls). > Any chance, fixup_after_fork() is not called? It seems that raw_write() is called before returnin

Re: Crashes in cmake subprocesses since 3.6.0

2025-04-02 Thread Takashi Yano via Cygwin
On Wed, 2 Apr 2025 20:15:54 +0200 Corinna Vinschen wrote: > Hi Takashi, > > On Apr 3 01:52, Takashi Yano via Cygwin wrote: > > > Currently, I am looking into this problem. > > > > > > What I noticed so far is: > > > * The problem occurs after the commit 7ed9adb356df. > > > * This problem is happ

Re: Crashes in cmake subprocesses since 3.6.0

2025-04-02 Thread Corinna Vinschen via Cygwin
Hi Takashi, On Apr 3 01:52, Takashi Yano via Cygwin wrote: > > Currently, I am looking into this problem. > > > > What I noticed so far is: > > * The problem occurs after the commit 7ed9adb356df. > > * This problem is happen when fhandler_fifo_pipe::raw_write() returns > > error because cygwai

Re: Crashes in cmake subprocesses since 3.6.0

2025-04-02 Thread David via Cygwin
On 4/2/25 9:52 AM, Takashi Yano via Cygwin wrote: The following patch also can solve the issue. The problem seems to be related to fork(). ... I posted "bash.exe crash" on 2025-03-25. There are similarities. In cygwin 3.6.x and 3.7.x, this bash command crashes silently: $ XXX=$(uname) Actual

Re: Crashes in cmake subprocesses since 3.6.0

2025-04-02 Thread Takashi Yano via Cygwin
On Wed, 2 Apr 2025 22:01:25 +0900 Takashi Yano via Cygwin wrote: > Hi Corinna, > > On Mon, 31 Mar 2025 11:28:44 +0200 > Corinna Vinschen wrote: > > On Mar 30 22:58, Jeremy Drake via Cygwin wrote: > > > On Mon, 31 Mar 2025, Christoph Reiter via Cygwin wrote: > > > > > > > Starting with 3.6.0 whe

Re: Crashes in cmake subprocesses since 3.6.0

2025-04-02 Thread Takashi Yano via Cygwin
Hi Corinna, On Mon, 31 Mar 2025 11:28:44 +0200 Corinna Vinschen wrote: > On Mar 30 22:58, Jeremy Drake via Cygwin wrote: > > On Mon, 31 Mar 2025, Christoph Reiter via Cygwin wrote: > > > > > Starting with 3.6.0 when cmake calls into make/ninja/gcc there is a > > > chance of > > > that failing, f

Re: Crashes in cmake subprocesses since 3.6.0

2025-03-31 Thread Corinna Vinschen via Cygwin
On Mar 30 22:58, Jeremy Drake via Cygwin wrote: > On Mon, 31 Mar 2025, Christoph Reiter via Cygwin wrote: > > > Starting with 3.6.0 when cmake calls into make/ninja/gcc there is a chance > > of > > that failing, for example like this: > > > > CMake Error: Generator: build tool execution failed, c

Re: Crashes in cmake subprocesses since 3.6.0

2025-03-30 Thread Jeremy Drake via Cygwin
On Mon, 31 Mar 2025, Christoph Reiter via Cygwin wrote: > Starting with 3.6.0 when cmake calls into make/ninja/gcc there is a chance of > that failing, for example like this: > > CMake Error: Generator: build tool execution failed, command was: > /usr/bin/cmake.exe -E env VERBOSE=1 /usr/bin/make.e