summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorAnders Roxell <anders.roxell@linaro.org>2018-02-06 16:23:39 -0600
committerShuah Khan <shuahkh@osg.samsung.com>2018-02-13 11:34:51 -0700
commitb2c93e300a11b419b4c67ce08e16fa1436d8118c (patch)
treed5cf6442c20806a36f7fdfef21fd94905a7d4277 /tools
parent7928b2cbe55b2a410a0f5c1f154610059c57b1b2 (diff)
downloadlinux-b2c93e300a11b419b4c67ce08e16fa1436d8118c.tar.gz
linux-b2c93e300a11b419b4c67ce08e16fa1436d8118c.tar.bz2
linux-b2c93e300a11b419b4c67ce08e16fa1436d8118c.zip
selftests: sync: missing CFLAGS while compiling
Based on patch: https://patchwork.kernel.org/patch/10042045/ arch64-linux-gnu-gcc -c sync.c -o sync/sync.o sync.c:42:29: fatal error: linux/sync_file.h: No such file or directory #include <linux/sync_file.h> ^ CFLAGS is not used during the compile step, so the system instead of kernel headers are used. Fix this by adding CFLAGS to the OBJS compile rule. Reported-by: Lei Yang <Lei.Yang@windriver.com> Signed-off-by: Anders Roxell <anders.roxell@linaro.org> Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/testing/selftests/sync/Makefile2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/selftests/sync/Makefile b/tools/testing/selftests/sync/Makefile
index b3c8ba3cb668..d0121a8a3523 100644
--- a/tools/testing/selftests/sync/Makefile
+++ b/tools/testing/selftests/sync/Makefile
@@ -30,7 +30,7 @@ $(TEST_CUSTOM_PROGS): $(TESTS) $(OBJS)
$(CC) -o $(TEST_CUSTOM_PROGS) $(OBJS) $(TESTS) $(CFLAGS) $(LDFLAGS)
$(OBJS): $(OUTPUT)/%.o: %.c
- $(CC) -c $^ -o $@
+ $(CC) -c $^ -o $@ $(CFLAGS)
$(TESTS): $(OUTPUT)/%.o: %.c
$(CC) -c $^ -o $@