[PATCH] D35780: Introduce -nostdlib++ flag to disable linking the C++ standard library.

Joerg Sonnenberger via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 25 12:50:35 PDT 2017


On Tue, Jul 25, 2017 at 03:09:00PM -0400, Nico Weber via cfe-commits wrote:
> On Tue, Jul 25, 2017 at 2:53 PM, Joerg Sonnenberger <joerg at bec.de> wrote:
> 
> > On Sun, Jul 23, 2017 at 07:06:25PM -0400, Nico Weber via cfe-commits wrote:
> > > If you need this behavior for something, that sounds like something a
> > > -nodefaultlibs++ could do. -nostdlib++ is really meant to disable the c++
> > > stdlib and nothing else.
> >
> > But the -lm is only there because -lc++ alone (or -lstdc++ for that
> > matter) wouldn't really work.
> >
> 
> Do you have a reference for that? Several toolchains link in -lm in C mode
> even.

UNIX history?

Joerg


More information about the cfe-commits mailing list