[Bug libstdc++/109814] [13/14 Regression] freestanding using cmath does not compile anymore

arsen at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Jul 28 10:54:49 GMT 2023


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109814

--- Comment #13 from Arsen Arsenović <arsen at gcc dot gnu.org> ---
(In reply to Jonathan Wakely from comment #12)

> I suppose we could enable <cmath> if hosted || newlib, but that wouldn't
> always be right because (IIUC) you can configure newlib without any of the
> libm functions. I suppose if you use such a newlib and then include <cmath>
> that's your own fault and you get to keep both pieces.

that seems reasonable, though my thinking is that maybe we can bring newlib
closer to hosted in general.  it even features C buffered IO (AFAIU) and
malloc, so it could provide the stuff that 'blocks' other features from working
on freestanding (besides threading, presumably?  I'd need to check what exactly
newlib provides)


More information about the Gcc-bugs mailing list