Ian Jackson
2008-Oct-23 16:45 UTC
[Xen-devel] [PATCH] minios: do not expose #define current to applications
Currently the minios headers do this: #define current get_current() Obviously when porting general code to this environment, this can cause problems ! The attached patch arranges for this only to be done if the .c file in question declares #define _INSIDE_MINIOS Suppressing the namespace pollution is necessary to get recent upstream qemu''s to compile, since they (quite properly) use `current'' as an ordinary identifier. Ian. Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com> _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Ian Jackson
2008-Oct-27 16:32 UTC
[Xen-devel] [PATCH] minios: do not expose #define current to applications
Currently the minios headers do this: #define current get_current() Obviously when porting general code to this environment, this can cause problems ! The attached patch arranges for this only to be done if #define __MINIOS__ is declared, which is set up by the makefile in extras/mini-os. Suppressing the namespace pollution is necessary to get recent upstream qemu''s to compile, since they (quite properly) use `current'' as an ordinary identifier. (This is a revised version of my earlier patch, and supersedes it.) Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com> _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Ian Jackson
2008-Oct-29 12:01 UTC
[Xen-devel] Re: [PATCH] minios: do not expose #define current to applications
I wrote:> The attached patch arranges for this only to be done if > #define __MINIOS__ > is declared, which is set up by the makefile in extras/mini-os.It turns out that __MINIOS__ is already used to mean `we are running under minios'' rather than `this is a source file which is part of minios. This causes a build failure (but apparently on amd64 only!) The attached patch changes the __MINIOS__ introduced in c/s 18727 to __INSIDE__MINIOS__. It also arranges to define it for the arch/ subdirectories too. Ian. _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel