qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 3/4] Refactoring MonitorDef array


From: Peter Maydell
Subject: Re: [Qemu-devel] [PATCH 3/4] Refactoring MonitorDef array
Date: Mon, 7 Oct 2013 22:29:05 +0900

On 7 October 2013 22:06, Fabien Chouteau <address@hidden> wrote:
> On 10/07/2013 01:45 PM, Peter Maydell wrote:
>> On 7 October 2013 19:11, Fabien Chouteau <address@hidden> wrote:
>>> On 10/04/2013 07:49 PM, Peter Maydell wrote:
>>>> On 5 October 2013 01:57, Fabien Chouteau <address@hidden> wrote:
>>>>> +extern const MonitorDef i386_monitor_defs[];
>>>>
>>>> Declare this in cpu-qom.h, rather than having an
>>>> extern declaration in a .c file.

> Sorry I sent the email too quickly. It looks like a circular dependency
>
> In file included from /home/chouteau/src/qemu-main/target-arm/cpu.h:294:0,
>                  from 
> /home/chouteau/src/qemu-main/include/monitor/monitor_def.h:4,
>                  from /home/chouteau/src/qemu-main/target-arm/monitor.c:20:
> /home/chouteau/src/qemu-main/target-arm/cpu-qom.h:184:25: error: array type 
> has incomplete element type
> make[1]: *** [target-arm/monitor.o] Error 1

I think you should be able to declare it as
  extern const MonitorDef *i386_monitor_defs;

then you don't need to include monitor_def.h from cpu-qom.h.
(untested, but the typedef should be sufficient for this)

-- PMM



reply via email to

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