All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Bergner <bergner@borg.umn.edu>
To: Linux Kernel <linux-kernel@vger.kernel.org>
Cc: bergner@us.ibm.com
Subject: Different CFLAGS for arch and non-arch files.
Date: Tue, 20 Feb 2001 21:08:02 -0600	[thread overview]
Message-ID: <20010220210802.A451159@brule.borg> (raw)

Hopefully someone can point me in the right direction here.
I need to use different CFLAGS options depending on whether
I'm compiling arch dependent code or arch independent code.
It seems the arch/XXX/Makefile only adds extra options to
CFLAGS and doesn't allow me specify options I want to apply
only to arch dependent code and others I'd like to apply
only to arch independent code.  Has anyone done such a thing?

I guess I'd like to have CFLAGS, CFLAGS_ARCH and CFLAGS_NONARCH
vars that would be set in the arch/XXX/Makefile and then break
up the SUBDIRS var in the toplevel Makefile into SUBDIRS and
ARCHSUBDIRS so we could iterate over them with the different
CFLAGS options (ie, CFLAGS + CFLAGS_NONARCH for the arch independent
files and CFLAGS + CFLAGS_ARCH for the arch dependent files).

My reason for doing this is that our new architecture's ABI
specifies the use of a TOC (table of contents) and we're running
into a TOC overflow problem.  I can use GCC's -mminimal-toc option,
but not for routines that will be called before relocation is turned
on (the global TOC contains virtual addrs of the private TOCs).
My idea is to compile all the arch dependent code without the
-minimal-toc option and all the arch independent code with the
-minimal-toc option.

Any clues on what I can/need to do would be appreciated.

Peter

--
Peter Bergner
SLIC Optimizing Translator Development / Linux PPC64 Kernel Development
IBM Rochester, MN
bergner@us.ibm.com


             reply	other threads:[~2001-02-21  2:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-02-21  3:08 Peter Bergner [this message]
2001-02-21  4:48 ` Different CFLAGS for arch and non-arch files Peter Samuelson

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=20010220210802.A451159@brule.borg \
    --to=bergner@borg.umn.edu \
    --cc=bergner@us.ibm.com \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.