Re: [PATCH 1/2] cgcc: gendeps for -MM, -MD & -MMD too

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

 



On 20.02.2019 16:34, Luc Van Oostenryck wrote:
> These flags must set '$gendeps', just like a plain '-M' do,
> since they implies '-M'.
> 
> Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
> ---

Hi.

Unlike simple '-M', '-MD' and '-MMD' doesn't imply '-E'. And according
to man: "Since -E is not implied, -MD can be used to generate a
dependency output file as a side-effect of the compilation process."

Open vSwitch uses "sparse" for static analysis in TravisCI and also
recommends it to developers. But this patch forces "sparse" to skip
almost all OVS source files. This happens because 'make' uses '-MD'
for dependency generation as a side effect within compiling commands.

Does this patch fixes any real issue with kernel? I think it should
be reverted or re-worked to handle 'MD|MMD' properly.
What do you think?

For now, we'll have to revert it locally before running CI builds:
    https://patchwork.ozlabs.org/patch/1090135/

Best regards, Ilya Maximets.

>  cgcc | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/cgcc b/cgcc
> index 629124b94..6d3b10a20 100755
> --- a/cgcc
> +++ b/cgcc
> @@ -49,7 +49,7 @@ while (@ARGV) {
>  
>      $m32 = 1 if /^-m32$/;
>      $m64 = 1 if /^-m64$/;
> -    $gendeps = 1 if /^-M$/;
> +    $gendeps = 1 if /^-(M|MM|MD|MMD)$/;
>  
>      if (/^-target=(.*)$/) {
>  	$check .= &add_specs ($1);
> 



[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux