On 2025-08-13 12:44, Denis Excoffier via Cygwin wrote:
On 2025-08-12, 19:33, Denis Excoffier wrote:
Today i was using cygwin-3.7.0-0.266… (found under /x86_64/release/cygwin, installed also the corresponding cygwin-doc and cygwin-devel) and built the new GCC 15.2.0. Then i built many (about 100) GNU or not-so-GNU software with no errors at all until i found in tcl-9.0.2 that GCC returns with status 2 (i.e. not 0, not 1, not 4) for compilation of tclStubLib.o (and compilation fails). Similarly, same return code (2) with fastcwd.o (and others, fastcwd is the first one) under winsup/cygwin/x86_64.

Same with GCC 15.1.0. But this was surely not the case when i installed GCC 
15.1.0 in April.
Same with cygwin-3.7.0-0.277… (the more recent one).

But not the same with cygwin-3.7.0-0.124... that i fetched on the 6th of June. 
In this case, compilation is ok (i checked with tcl only, not fastcwd.o).

Then i started to bisect between cygwin-3.7.0-0.124… and cygwin-3.7.0-0.277…

Unfortunately, cygwin-3.7.0 revisions from -124 to -246 are gone!

Please don’t remove cygwin test releases too early.

Well, i’m lucky since cygwin-3.7.0-0.247 does not show up the problem (which
is: GCC returns sometimes with $status=2, e.g. in tcl-9.0.2 and for cygwin sources).

After bisection, it appears that the problem can be located between 
cygwin-3.7.0-250… and cygwin-3.7.0-256.
Three commits there on the trunk (and three on the branch):

[newlib-cygwin] Cygwin: cygheap: Add lock()/unlock() method   Takashi Yano
[newlib-cygwin] Cygwin: spawn: Lock cygheap from refresh_cygheap() until 
child_copy()   Takashi Yano
[newlib-cygwin] Cygwin: spawn: Make system() thread-safe   Takashi Yano

The third one seems promising. Indeed:
- i install cygwin1.dll from cygwin-3.7.0-0.250
- i build cygwin-3.7.0-0.277 with the commit 'Cygwin: spawn: Make system() 
thread-safe’ reverted. It builds.
- i install cygwin1.dll from the newly built cygwin-3.7.0-277 (again with 
commit reverted)
- i build cygwin-3.7.0-0.277 with the commit reverted. Now it builds without 
problem.

Similary, tcl (see above) no longer fails to build. The return code 2 from GCC 
seems gone.

Some additional information: under W10, no such difficulties. The problem seems 
to arise only with W11 (CYGWIN_NT-10.0-26100).

Please someone have a look into this commit. Sorry not being able to do it 
myself. Hope this however helps.
Last remark: i didn’t try with the regular GCC from the cygwin distribution;
and perhaps something is missing in my GCC 15 build configuration.
Possibly! Now for the obvious questions for you to review.

Did you have all cygport dependencies installed when you built gcc and tcl:

autoconf, automake, binutils, bzip2, diffstat, dos2unix, gcc-core, gcc-g++, lftp, libtool, lndir, lzip, make, openssh, patch, perl-Authen-SASL, perl-MIME-tools, perl-Net-SMTP-SSL, perl-common-sense, perl_base, pkg-config, rsync, texinfo, unzip, wget, xz?

Did you use the current gcc.cygport source to drive the gcc build?

Did you also have all cygwin build dependencies installed when you built cygwin:

cocom, dblatex, dejagnu, docbook-xml45, docbook-xsl, docbook2X, gettext-devel, libiconv, libiconv-devel, libzstd-devel, mingw64-x86_64-gcc-g++,
mingw64-x86_64-zlib, python39-lxml, python39-ply,
texlive-collection-fontsrecommended, texlive-collection-latexrecommended,
texlive-collection-pictures, xmlto, zlib-devel?

Did you use the current cygwin.cygport source to drive the cygwin build?

Did you use the current tcl.cygport source to drive the tcl build?

--
Take care. Thanks, Brian Inglis              Calgary, Alberta, Canada

La perfection est atteinte                   Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter  not when there is no more to add
mais lorsqu'il n'y a plus rien à retrancher  but when there is no more to cut
                                -- Antoine de Saint-Exupéry

--
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

Reply via email to