[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2 40/47] trace: switch target/s390x/ directory

From: Lluís Vilanova
Subject: Re: [Qemu-devel] [PATCH v2 40/47] trace: switch target/s390x/ directory to modular trace.h file
Date: Fri, 06 Jan 2017 21:45:08 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux)

Daniel P Berrange writes:

> On Fri, Jan 06, 2017 at 06:09:16PM +0100, Lluís Vilanova wrote:
>> Daniel P Berrange writes:
>> > Switch files in the target/s390x/ directory to include the
>> > target/s390x/trace.h file instead of the global trace.h
>> > file.
>> > The make rules for gen-features.{h,c} need to be moved
>> > out into the top level Makefile.objs, otherwise make
>> > complains about the rules being defined multiple times
>> > due to target/s390x/Makefile.objs being included
>> > multiple times when expanding different subdir object
>> > lists.
>> If the problem is re-definition, you can instead add a guard around the 
>> rules in
>> target/s390x/Makefile.objs. This avoids defining the rules multiple times but
>> still keeps the target-specific rules in the target-specific makefile.

> What kind of guard to you mean ? What's happening is that the top
> level Makefile.target is including target/s390x/Makefile.objs
> multiple times to expand multiple vars. I don't see a way to
> distinguish which include we're being called from.

I think I did something like this to ensure rules are defined only once:

  # ... rules ...

It's not the cleanest solution, but neither is having target-specific rules in a
generic makefile. Choose your least evil.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]