mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-02 23:27:06 +00:00
3a1e4a91aa
_GNU_SOURCE is defined in resctrl.h. Defining _GNU_SOURCE has a large impact on what gets defined when including headers either before or after it. This can result in compile failures if .c file decides to include a standard header file before resctrl.h. It is safer to define _GNU_SOURCE in Makefile so it is always defined regardless of in which order includes are done. Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Tested-by: Shaopeng Tan <tan.shaopeng@jp.fujitsu.com> Reviewed-by: Reinette Chatre <reinette.chatre@intel.com> Reviewed-by: Shaopeng Tan <tan.shaopeng@jp.fujitsu.com> Cc: <stable@vger.kernel.org> Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
10 lines
216 B
Makefile
10 lines
216 B
Makefile
# SPDX-License-Identifier: GPL-2.0
|
|
|
|
CFLAGS = -g -Wall -O2 -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE
|
|
CFLAGS += $(KHDR_INCLUDES)
|
|
|
|
TEST_GEN_PROGS := resctrl_tests
|
|
|
|
include ../lib.mk
|
|
|
|
$(OUTPUT)/resctrl_tests: $(wildcard *.[ch])
|