public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "mikpelinux at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug bootstrap/98590] New: [11 regression] Bootstrap failure with Ada on Cygwin since switch to C++11 Date: Thu, 07 Jan 2021 20:07:34 +0000 [thread overview] Message-ID: <bug-98590-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98590 Bug ID: 98590 Summary: [11 regression] Bootstrap failure with Ada on Cygwin since switch to C++11 Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: bootstrap Assignee: unassigned at gcc dot gnu.org Reporter: mikpelinux at gmail dot com Target Milestone: --- Attempting to bootstrap gcc-11-20210103 with Ada on x86_64-pc-cygwin fails with: g++ -std=c++11 -fno-PIE -c -DIN_GCC_FRONTEND -g -DIN_GCC -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wno-error=format-diag -Wno-format -Wmissing-format-attribute -Woverloaded-virtual -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -DHAVE_CONFIG_H -I. -Iada -I/tmp/gcc-11-20210103/gcc -I/tmp/gcc-11-20210103/gcc/ada -I/tmp/gcc-11-20210103/gcc/../include -I/tmp/gcc-11-20210103/gcc/../libcpp/include -I/tmp/gcc-11-20210103/gcc/../libcody -I/home/mikpe/pkgs/cygwin-x86_64/gmp-6.2.1/include -I/home/mikpe/pkgs/cygwin-x86_64/mpfr-4.1.0/include -I/home/mikpe/pkgs/cygwin-x86_64/mpc-1.2.1/include -I/tmp/gcc-11-20210103/gcc/../libdecnumber -I/tmp/gcc-11-20210103/gcc/../libdecnumber/bid -I../libdecnumber -I/tmp/gcc-11-20210103/gcc/../libbacktrace -o ada/cstreams.o -MT ada/cstreams.o -MMD -MP -MF ada/.deps/cstreams.TPo /tmp/gcc-11-20210103/gcc/ada/cstreams.c In file included from /tmp/gcc-11-20210103/gcc/ada/cstreams.c:59: /tmp/gcc-11-20210103/gcc/ada/cstreams.c: In function 'int __gnat_fileno(FILE*)': /tmp/gcc-11-20210103/gcc/system.h:122:26: error: 'fileno_unlocked' was not declared in this scope; did you mean 'fopen_unlocked'? 122 | # define fileno(Stream) fileno_unlocked (Stream) | ^~~~~~~~~~~~~~~ /tmp/gcc-11-20210103/gcc/ada/cstreams.c:117:12: note: in expansion of macro 'fileno' 117 | return (fileno (stream)); | ^~~~~~ make[3]: *** [Makefile:1131: ada/cstreams.o] Error 1 make[3]: Leaving directory '/tmp/objdir/gcc' make[2]: *** [Makefile:4778: all-stage1-gcc] Error 2 make[2]: Leaving directory '/tmp/objdir' make[1]: *** [Makefile:22181: stage1-bubble] Error 2 make[1]: Leaving directory '/tmp/objdir' make: *** [Makefile:22518: bootstrap] Error 2 GCC 7/8/9/10 all bootstrap fine with Ada (if a pending patch for PR94918 is applied). A git bisect identified that this error started when GCC 11 switched to requiring C++11 during bootstrap: # first bad commit: [5329b59a2e13dabbe2038af0fe2e3cf5fc7f98ed] bootstrap: Update requirement to C++11. Cygwin's <stdio.h> only declares fileno_unlocked() if _GNU_SOURCE or similar is defined. With g++ -std=c++11 or gcc -std=c11 the function is _not_ declared, but if the -std= option is omitted or changed to a GNU dialect then the function is declared. For some reason however the configure checks for fileno_unlocked all succeeded: > fgrep fileno_unlocked build.log checking for fileno_unlocked... yes checking whether fileno_unlocked is declared... yes checking for fileno_unlocked... yes checking whether fileno_unlocked is declared... yes checking for fileno_unlocked... yes checking whether fileno_unlocked is declared... yes checking for fileno_unlocked... yes checking whether fileno_unlocked is declared... yes and left the generated config.h and auto-host.h files declaring it: > grep -F -r HAVE_FILENO_UNLOCKED --include="*.h" . ./build-x86_64-pc-cygwin/fixincludes/config.h:#define HAVE_FILENO_UNLOCKED 1 ./build-x86_64-pc-cygwin/libcpp/config.h:#define HAVE_FILENO_UNLOCKED 1 ./gcc/auto-host.h:#define HAVE_FILENO_UNLOCKED 1 ./libcpp/config.h:#define HAVE_FILENO_UNLOCKED 1 Seems there's a discrepancy between the configure tests and what GCC proper does, leading to a reference to an undefined symbol.
next reply other threads:[~2021-01-07 20:07 UTC|newest] Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-01-07 20:07 mikpelinux at gmail dot com [this message] 2021-01-07 20:10 ` [Bug bootstrap/98590] " mikpelinux at gmail dot com 2021-01-07 20:12 ` mikpelinux at gmail dot com 2021-01-07 20:25 ` ebotcazou at gcc dot gnu.org 2021-01-08 8:32 ` rguenth at gcc dot gnu.org 2021-01-08 10:03 ` ebotcazou at gcc dot gnu.org 2021-01-08 10:23 ` jakub at gcc dot gnu.org 2021-01-08 10:42 ` ebotcazou at gcc dot gnu.org 2021-01-08 10:47 ` jakub at gcc dot gnu.org 2021-01-09 14:05 ` mikpelinux at gmail dot com 2021-02-01 11:32 ` ebotcazou at gcc dot gnu.org 2021-02-03 16:45 ` mikpelinux at gmail dot com 2021-02-26 12:30 ` rguenth at gcc dot gnu.org 2021-03-02 22:20 ` cvs-commit at gcc dot gnu.org 2021-03-07 17:02 ` mikpelinux at gmail dot com
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-98590-4@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).