1From 8a4cad5e2f2cbb6a34bdc6e877fe499502b8c4c8 Mon Sep 17 00:00:00 2001
2From: Marcel Ziswiler <marcel.ziswiler@toradex.com>
3Date: Fri, 23 Dec 2016 18:12:29 +0100
4Subject: [PATCH] linuxptp: Use cross cpp in incdefs
5
6Use cross cpp incdefs.sh shell script since we are doing cross compiling
7we need to ensure we use correct setttings from toolchain
8
9Upstream-Status: Inappropriate [OE-Specific]
10Signed-off-by: Khem Raj <raj.khem@gmail.com>
11---
12
13 makefile | 2 +-
14 1 file changed, 1 insertion(+), 1 deletion(-)
15
16--- a/incdefs.sh
17+++ b/incdefs.sh
18@@ -27,7 +27,7 @@ user_flags()
19 	printf " -D_GNU_SOURCE"
20
21 	# Get list of directories searched for header files.
22-	dirs=$(echo "" | ${CROSS_COMPILE}cpp -Wp,-v 2>&1 >/dev/null | grep ^" /")
23+	dirs=$(${CPP} -Wp,-v -xc /dev/null 2>&1 >/dev/null | grep ^" /")
24
25 	# Look for clock_adjtime().
26 	for d in $dirs; do
27