Re: [PATCH] selftests: proc: Fix _GNU_SOURCE redefined build warns

From: Shuah Khan
Date: Tue Sep 24 2019 - 16:05:23 EST


On 9/24/19 1:52 PM, Alexey Dobriyan wrote:
On Tue, Sep 24, 2019 at 12:19:10PM -0600, Shuah Khan wrote:
Fix the following _GNU_SOURCE redefined build warns:

proc-loadavg-001.c:17: warning: "_GNU_SOURCE" redefined
proc-self-syscall.c:16: warning: "_GNU_SOURCE" redefined
proc-uptime-002.c:18: warning: "_GNU_SOURCE" redefined

+#ifndef _GNU_SOURCE
#define _GNU_SOURCE
+#endif

Why are you doing this.

There are 140 redefinitions of _GNU_SOURCE



Is there something wrong with getting rid of this warning?

thanks,
-- Shuah