grub-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] module-verifier: make it possible to run checkers on grub-mo


From: Daniel Kiper
Subject: Re: [PATCH] module-verifier: make it possible to run checkers on grub-module-verifierxx.c
Date: Mon, 3 Sep 2018 17:40:22 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

On Thu, Aug 02, 2018 at 10:36:33AM -0400, Peter Jones wrote:
> This makes it so you can treat grub-module-verifierxx.c as a file you can
> build directly, so syntax checkers like vim's "syntastic" plugin, which uses
> "gcc -x c -fsyntax-only" to build it, will work.
>
> One still has to do whatever setup is required to make it pick the right
> include dirs, which -W options we use, etc., but this makes it so you can do

s/-W/-I/?

> the checking on the file you're editing, rather than on a different file.
>
> v2: fix the typo in the #else clause in util/grub-module-verifierXX.c
>
> Signed-off-by: Peter Jones <address@hidden>

If apply your patch and call this:

  gcc -x c -fsyntax-only -Iinclude -I. util/grub-module-verifierXX.c

I see following warnings:

  util/grub-module-verifierXX.c:49:0: warning: "ELF_R_SYM" redefined [enabled 
by default]
  In file included from util/grub-module-verifierXX.c:12:0:
  include/grub/elf.h:2498:0: note: this is the location of the previous 
definition
  util/grub-module-verifierXX.c:50:0: warning: "ELF_R_TYPE" redefined [enabled 
by default]
  In file included from util/grub-module-verifierXX.c:12:0:
  include/grub/elf.h:2499:0: note: this is the location of the previous 
definition
  util/grub-module-verifierXX.c:51:0: warning: "ELF_ST_TYPE" redefined [enabled 
by default]
  In file included from util/grub-module-verifierXX.c:12:0:
  include/grub/elf.h:2495:0: note: this is the location of the previous 
definition

Should not we drop ELF_R_SYM, ELF_R_TYPE and ELF_ST_TYPE definitions for
64-bits from util/grub-module-verifierXX.c?

Daniel



reply via email to

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