]> git.baikalelectronics.ru Git - kernel.git/commit
fs/proc: Add compiler check for -Wno-override-init to support gcc < 4.2
authorGeert Uytterhoeven <geert@linux-m68k.org>
Wed, 3 Aug 2016 15:33:32 +0000 (17:33 +0200)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 3 Aug 2016 16:45:23 +0000 (12:45 -0400)
commit23035a34c7f68d69a349777065769b6dca7ffb70
tree95481a0c2f12d173b19b320385534619701a6db9
parent1880a84f05c945209b6550437179499391217c5c
fs/proc: Add compiler check for -Wno-override-init to support gcc < 4.2

With gcc < 4.2 (e.g. 4.1.2):

      CC      fs/proc/task_mmu.o
    cc1: error: unrecognized command line option "-Wno-override-init"

To fix this, only enable the compiler option when it is actually
supported by the compiler.

Fixes: f9ee44d81766 ("fs/proc/task_mmu.c: suppress compilation warnings with W=1")
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Valdis Kletnieks <valdis.kletnieks@vt.edu>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/proc/Makefile