public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "doko at debian dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug modula2/104065] [12 Regression] trunk 20220117 fails to build modula2 Date: Wed, 19 Jan 2022 10:50:35 +0000 [thread overview] Message-ID: <bug-104065-4-fgTyjIWsFY@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-104065-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104065 Matthias Klose <doko at debian dot org> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|FIXED |--- Status|RESOLVED |NEW --- Comment #4 from Matthias Klose <doko at debian dot org> --- reopening. the build failure is still there. the branch currently has: --- a/gcc/hwint.h +++ b/gcc/hwint.h @@ -257,11 +257,14 @@ exact_log2 (unsigned HOST_WIDE_INT x) (HOST_WIDE_INT_1U << (HOST_BITS_PER_WIDE_INT - 1)) #define HOST_WIDE_INT_MAX (~(HOST_WIDE_INT_MIN)) +#ifndef __cplusplus extern HOST_WIDE_INT abs_hwi (HOST_WIDE_INT); extern unsigned HOST_WIDE_INT absu_hwi (HOST_WIDE_INT); -extern HOST_WIDE_INT gcd (HOST_WIDE_INT, HOST_WIDE_INT); extern HOST_WIDE_INT pos_mul_hwi (HOST_WIDE_INT, HOST_WIDE_INT); extern HOST_WIDE_INT mul_hwi (HOST_WIDE_INT, HOST_WIDE_INT); +#endif /* !cplusplus. */ + +extern HOST_WIDE_INT gcd (HOST_WIDE_INT, HOST_WIDE_INT); extern HOST_WIDE_INT least_common_multiple (HOST_WIDE_INT, HOST_WIDE_INT); /* Like ctz_hwi, except 0 when x == 0. */ @@ -316,6 +319,7 @@ zext_hwi (unsigned HOST_WIDE_INT src, unsigned int prec) } } +#ifdef __cplusplus /* Compute the absolute value of X. */ inline HOST_WIDE_INT @@ -374,5 +378,6 @@ mul_hwi (HOST_WIDE_INT a, HOST_WIDE_INT b, bool *overflow) return result; #endif } +#endif /* ! __cplusplus */ #endif /* ! GCC_HWINT_H */ and the file is compiled using gcc (at least in stage1). Looks like m2/Make-lang.in uses it's own definition HOSTCC to build these files. So maybe define a HOSTCXX and build with that instead? There's also a macro CPLUS which is unused. However, these macros should be taken from the parent Makefile, so maybe just use CC and CXX instead? Trying --- a/gcc/m2/Make-lang.in +++ b/gcc/m2/Make-lang.in @@ -32,7 +32,7 @@ GM2_1 = ./gm2 -B./stage1/m2 -g -fm2-g XGCC = ./xgcc -B./ GM2_2 = ./gm2 -B./stage2/m2 -g -fm2-g -HOSTCC = gcc +HOSTCC = $(CXX) CFLAGS=-g ## remove this LDLAGS=-g ## remove this doesn't work, gm2 isn't yet C++ ready. Jakub confirmed on irc: <jakub> compiling with hwint.h includes with C is not supported anymore...
next prev parent reply other threads:[~2022-01-19 10:50 UTC|newest] Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-01-17 11:42 [Bug modula2/104065] New: " doko at debian dot org 2022-01-18 4:34 ` [Bug modula2/104065] " pinskia at gcc dot gnu.org 2022-01-18 7:26 ` rguenth at gcc dot gnu.org 2022-01-18 11:21 ` gaius at gcc dot gnu.org 2022-01-18 14:19 ` gaius at gcc dot gnu.org 2022-01-18 14:33 ` gaius at gcc dot gnu.org 2022-01-19 10:50 ` doko at debian dot org [this message] 2022-01-20 16:14 ` gaius at gcc dot gnu.org 2022-01-21 14:40 ` gaius at gcc dot gnu.org 2022-01-22 0:58 ` gaius at gcc dot gnu.org 2022-03-09 13:29 ` rguenth at gcc dot gnu.org
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-104065-4-fgTyjIWsFY@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).