Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Jul 2024 22:01:47 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 280482] Buildworld fails with error: invalid argument '-std=gnu99' not allowed with 'C++'
Message-ID:  <bug-280482-227-53euftGzX9@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-280482-227@https.bugs.freebsd.org/bugzilla/>
References:  <bug-280482-227@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D280482

Brooks Davis <brooks@FreeBSD.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|New                         |Closed
                 CC|                            |brooks@FreeBSD.org
         Resolution|---                         |Not A Bug

--- Comment #1 from Brooks Davis <brooks@FreeBSD.org> ---
This line is almost certainly your issue:

CXXFLAGS+=3D${CFLAGS}

This adds the entire contents of CFLAGS at the time the CXXFLAGS variable is
expanded to the end of the current value of CXXFLAGS.  That means it's addi=
ng
-std=3Dgnu99 to CXXFLAGS.

If you want to have one place to set these (mostly pointless) flags, then y=
ou
need to do something like:

MY_CUSTOM_CFLAGS=3D -march=3D${CPUTYPE}
CFLAGS+=3D${MY_CUSTOM_CFLAGS}
CXXFLAGS+=3D${MY_CUSTOM_CFLAGS}

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-280482-227-53euftGzX9>