From: Keir Fraser <keir.xen@gmail.com>
To: Tim Deegan <Tim.Deegan@citrix.com>,
Ian Campbell <Ian.Campbell@eu.citrix.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Subject: Re: [PATCH 8 of 8] xen: add "clang=y" option to build Xen with clang/llvm instead of gcc
Date: Mon, 07 Mar 2011 17:01:58 +0000 [thread overview]
Message-ID: <C99AC006.14450%keir.xen@gmail.com> (raw)
In-Reply-To: <20110307162934.GD28479@whitby.uk.xensource.com>
On 07/03/2011 16:29, "Tim Deegan" <Tim.Deegan@citrix.com> wrote:
> At 14:54 +0000 on 07 Mar (1299509669), Ian Campbell wrote:
>> Is it worth arranging for "gcc := y" when clang is not enabled? Then a
>> whole bunch of this sort of thing devolves into the
>> CFLAGS-$(a-particular-cc) += -Wfoo
>> pattern.
>
> Something like the attached? It tidies up four such ifeqs, at the cost
> of one new one to define $(gcc).
> (4 files changed, 17 insertions(+), 16 deletions(-))
This looks like a definite improvement in readability, to me. I'd like it to
be applied.
-- Keir
>>> @@ -1,6 +1,11 @@
>>> AS = $(CROSS_COMPILE)as
>>> +ifeq ($(clang),y)
>>> +LD = $(CROSS_COMPILE)gold
>>> +CC = $(CROSS_COMPILE)clang
>>> +else
>>> LD = $(CROSS_COMPILE)ld
>>> CC = $(CROSS_COMPILE)gcc
>>> +endif
>>> CPP = $(CC) -E
>>> AR = $(CROSS_COMPILE)ar
>>> RANLIB = $(CROSS_COMPILE)ranlib
>>
>> LD-$(clang) = ...
>> LD-$(gcc) = ...
>>
>> LD := $(LD-y)
>
> I tried that but it looks about as bad, and actually has more
> repetition.
>
> Tim.
next prev parent reply other threads:[~2011-03-07 17:01 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-07 11:26 [PATCH 0 of 8] Allow building xen with clang/llvm Tim Deegan
2011-03-07 11:26 ` [PATCH 1 of 8] x86: make spinlock's 16-bit asm operand explicitly 16-bit Tim Deegan
2011-03-07 11:26 ` [PATCH 2 of 8] x86: add explicit size suffixes to some assembly instructions Tim Deegan
2011-03-08 9:27 ` Jan Beulich
2011-03-08 10:44 ` Tim Deegan
2011-03-08 11:01 ` Jan Beulich
2011-03-08 16:29 ` Keir Fraser
2011-03-07 11:26 ` [PATCH 3 of 8] x86: redefine a few empty macros as explicit nops Tim Deegan
2011-03-07 11:26 ` [PATCH 4 of 8] xen: adjust cpumask initializers to suit clang's incomplete gccisms Tim Deegan
2011-03-07 11:26 ` [PATCH 5 of 8] credit2: remove two nested functions, replacing them with static ones Tim Deegan
2011-03-07 15:22 ` George Dunlap
2011-03-07 11:26 ` [PATCH 6 of 8] Xen: remove run_in_exception_handler() and recode its only caller Tim Deegan
2011-03-07 15:05 ` Keir Fraser
2011-03-07 15:15 ` Keir Fraser
2011-03-07 15:38 ` Tim Deegan
2011-03-07 15:44 ` Keir Fraser
2011-03-07 15:49 ` Keir Fraser
2011-03-07 15:56 ` Tim Deegan
2011-03-07 16:00 ` Keir Fraser
2011-03-07 16:06 ` Tim Deegan
2011-03-07 11:26 ` [PATCH 7 of 8] x86: redefine REX64_PREFIX for clang, which doesn't like 'rex64/' Tim Deegan
2011-03-07 11:26 ` [PATCH 8 of 8] xen: add "clang=y" option to build Xen with clang/llvm instead of gcc Tim Deegan
2011-03-07 14:54 ` Ian Campbell
2011-03-07 16:29 ` Tim Deegan
2011-03-07 17:01 ` Keir Fraser [this message]
2011-03-08 10:29 ` Tim Deegan
2011-03-08 10:00 ` Ian Campbell
2011-03-07 12:03 ` [PATCH 0 of 8] Allow building xen with clang/llvm Keir Fraser
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=C99AC006.14450%keir.xen@gmail.com \
--to=keir.xen@gmail.com \
--cc=Ian.Campbell@eu.citrix.com \
--cc=Tim.Deegan@citrix.com \
--cc=xen-devel@lists.xensource.com \
/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;
as well as URLs for NNTP newsgroup(s).