From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E6F1A384AB43; Tue, 30 Apr 2024 06:54:31 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E6F1A384AB43 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1714460071; bh=jDRnnV+JDk3Kn1x+QGYUsDx8omVB6KIdkxXPk2cO+JU=; h=From:To:Subject:Date:From; b=ekd5bGlB1Fkm7PK+D4dg0MHtNL59XhpLzZXibAHWhL6rUCv0G6M1So4qSYjiWoCQP 9OhUNyaSSirg6hIio8JTXKSXwZ/qvURxbk1dE8Uqs+HirJd1Us4zp9vncFmcSLh22q GKglA7JOWFK4RavEDXDcDa0Pdg6lKDeXqc4/NGSY= From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libfortran/114895] New: Build failure with !HAVE_WORKING_STAT Date: Tue, 30 Apr 2024 06:54:31 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libfortran X-Bugzilla-Version: 14.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D114895 Bug ID: 114895 Summary: Build failure with !HAVE_WORKING_STAT Product: gcc Version: 14.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libfortran Assignee: unassigned at gcc dot gnu.org Reporter: rguenth at gcc dot gnu.org Target Milestone: --- [31724s] libtool: compile:=20 /home/abuild/rpmbuild/BUILD/gcc-14.0.1+git9885/obj-x86_64-suse-linux/./gcc/= xgcc -B/home/abuild/rpmbuild/BUILD/gcc-14.0.1+git9885/obj-x86_64-suse-linux/./gc= c/ -B/usr/x86_64-suse-linux/bin/ -B/usr/x86_64-suse-linux/lib/ -isystem /usr/x86_64-suse-linux/include -isystem /usr/x86_64-suse-linux/sys-include -DHAVE_CONFIG_H -I. -I../../../../libgfortran -iquote../../../../libgfortra= n/io -I../../../../libgfortran/../gcc -I../../../../libgfortran/../gcc/config -I../../.././gcc -I../../../../libgfortran/../libgcc -I../../libgcc -I../../../../libgfortran/../libbacktrace -I../../libbacktrace -I../libbacktrace -std=3Dgnu11 -Wall -Wstrict-prototypes -Wmissing-prototyp= es -Wold-style-definition -Wextra -Wwrite-strings -Werror=3Dimplicit-function-declaration -Werror=3Dvla -fcf-protection -mshs= tk -fcx-fortran-rules -ffunction-sections -fdata-sections -g -O2 -funwind-tabl= es -fasynchronous-unwind-tables -fstack-clash-protection -Werror=3Dreturn-type= -m32 -MT unix.lo -MD -MP -MF .deps/unix.Tpo -c ../../../../libgfortran/io/unix.c= =20 -fPIC -DPIC -o .libs/unix.o [31724s] ../../../../libgfortran/io/unix.c: In function =E2=80=98find_file= =E2=80=99: [31724s] ../../../../libgfortran/io/unix.c:1704:26: error: =E2=80=98id=E2= =80=99 undeclared (first use in this function) [31724s] 1704 | # define FIND_FILE0_ARGS id, path [31724s] | ^~ [31724s] ../../../../libgfortran/io/unix.c:1778:30: note: in expansion of m= acro =E2=80=98FIND_FILE0_ARGS=E2=80=99 [31724s] 1778 | u =3D find_file0 (unit_root, FIND_FILE0_ARGS); [31724s] | ^~~~~~~~~~~~~~~ [31724s] ../../../../libgfortran/io/unix.c:1704:26: note: each undeclared identifier is reported only once for each function it appears in [31724s] 1704 | # define FIND_FILE0_ARGS id, path [31724s] | ^~ [31724s] ../../../../libgfortran/io/unix.c:1778:30: note: in expansion of m= acro =E2=80=98FIND_FILE0_ARGS=E2=80=99 [31724s] 1778 | u =3D find_file0 (unit_root, FIND_FILE0_ARGS); [31724s] | ^~~~~~~~~~~~~~~ [31724s] make[6]: *** [Makefile:6863: unix.lo] Error 1 which is because find_file does #if defined(__MINGW32__) && !HAVE_WORKING_STAT id =3D id_from_path (path); #endif RDLOCK (&unit_rwlock); retry: u =3D find_file0 (unit_root, FIND_FILE0_ARGS); so as long as __MINGW32__ is not defined this won't work. The fix might be to remove the __MINGW32__ part of the conditional. (and no, I didn't yet know how we arrived at !HAVE_WORKING_STAT - this is on x86_64 linux, but with a -j1 build - see https://bugzilla.suse.com/show_bug.cgi?id=3D1223169)=