Paolo Bonzini <pbonz...@redhat.com> writes: > On 30/06/2016 14:53, Markus Armbruster wrote: >> +bad-header-comment := /* FIXME Does not pass make >> check-headers$(bad-header-with-y), yet! >> +bad-headers := $(shell cd $(SRC_PATH) && fgrep -l '$(bad-header-comment)' >> $(src-headers)) >> +bad-headers += $(shell fgrep -l '$(bad-header-comment)' $(gen-headers)) >> +# Headers that require -DNEED_CPU_H etc. >> +target-header-comment := /* NOTE: May only be included into >> target-dependent code */ > > Perhaps accept a "FIXME" as well here? You don't have to use the right > one in the patch of course.
Makes sense. I guess the same argument could be made for the other magic comments. >> diff --git a/target-sparc/cpu-qom.h b/target-sparc/cpu-qom.h >> index f63af72..30d112c 100644 >> --- a/target-sparc/cpu-qom.h >> +++ b/target-sparc/cpu-qom.h >> @@ -17,6 +17,9 @@ >> * License along with this library; if not, see >> * <http://www.gnu.org/licenses/lgpl-2.1.html> >> */ >> + >> +/* NOTE: May only be included into target-dependent code */ > > This shouldn't be true for cpu-qom.h. > > Perhaps > Paolo Here's what made me mark the header: $ make tests/headers/target-sparc/cpu-qom.o [...] CC tests/headers/target-sparc/cpu-qom.o In file included from tests/headers/target-sparc/cpu-qom.c:14:0: /work/armbru/qemu/target-sparc/cpu-qom.h:28:8: error: attempt to use poisoned "TARGET_SPARC64" #ifdef TARGET_SPARC64 ^ /work/armbru/qemu/rules.mak:59: recipe for target 'tests/headers/target-sparc/cpu-qom.o' failed make: *** [tests/headers/target-sparc/cpu-qom.o] Error 1 Error context: #ifdef TARGET_SPARC64 #define TYPE_SPARC_CPU "sparc64-cpu" #else #define TYPE_SPARC_CPU "sparc-cpu" #endif