Skip to content
Commit 04130cc9 authored by Daniel Tang's avatar Daniel Tang Committed by Michal Marek
Browse files

Fix a build warning in scripts/mod/file2alias.c



On some systems, __used is already defined in sys/cdefs.h and causes
a build warning:

scripts/mod/file2alias.c:85:1: warning: "__used" redefined
In file included from /usr/include/stdio.h:64,
                 from scripts/mod/modpost.h:1,
		                  from scripts/mod/file2alias.c:13:
				  /usr/include/sys/cdefs.h:146:1: warning: this is the location of the previous definition

This adds an extra check before defining the __used macro to see if
the macro was already defined elsewhere.

Signed-off-by: default avatarDaniel Tang <dt.tangr@gmail.com>
Signed-off-by: default avatarMichal Marek <mmarek@suse.cz>
parent bd701343
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment