mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Keith Owens <kaos@ocs.com.au>
To: linux-kernel@vger.kernel.org
Subject: How to do -nostdinc?
Date: Sun, 15 Dec 2002 23:06:41 +1100	[thread overview]
Message-ID: <1357.1039954001@ocs3.intra.ocs.com.au> (raw)

There are two ways of setting the -nostdinc flag in the kernel Makefile :-

(1) -nostdinc $(shell $(CC) -print-search-dirs | sed -ne 's/install: \(.*\)/-I \1include/gp')
(2) -nostdinc -iwithprefix include

The first format breaks with non-English locales, however the fix is trivial.

(1a) -nostdinc $(shell LANG=C $(CC) -print-search-dirs | sed -ne 's/install: \(.*\)/-I \1include/gp')

The second format is simpler but there have been reports that it does
not work with some versions of gcc.  I have been unable to find a
definitive statement about which versions of gcc fail and whether the
problem has been fixed.  Anybody care to provide a definitive
statement?

If kernel build cannot rely on gcc working with -nostdinc -iwithprefix include
then we need to convert to (1a).


             reply	other threads:[~2002-12-15 11:58 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-12-15 12:06 Keith Owens [this message]
2002-12-15 13:47 ` Marius Gedminas
2002-12-15 15:11 ` Russell King
2002-12-16  0:17 ` Steffen Persvold
2002-12-16 18:29 ` Sam Ravnborg
2002-12-16 21:26   ` Keith Owens
2002-12-16 22:44     ` J.A. Magallon
2002-12-16 23:16     ` H. Peter Anvin

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=1357.1039954001@ocs3.intra.ocs.com.au \
    --to=kaos@ocs.com.au \
    --cc=linux-kernel@vger.kernel.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: link
Be 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

all inboxes | Powered by JetHome®