diff mbox

[dpdk-dev,5/6] fix build error in app/test with gcc4.3

Message ID 1426735018-19411-8-git-send-email-yong.liu@intel.com (mailing list archive)
State Accepted, archived
Headers show

Commit Message

Liu, Yong March 19, 2015, 3:16 a.m. UTC
From: Marvin Liu <yong.liu@intel.com>

Option var-tracking-assignments supported in gcc from 4.4.
Add gcc version check wil fix this issue.

error: unrecognized command line option "-fno-var-tracking-assignments"

Signed-off-by: Marvin Liu <yong.liu@intel.com>
diff mbox

Patch

diff --git a/app/test/Makefile b/app/test/Makefile
index 9f0262c..4aca77c 100644
--- a/app/test/Makefile
+++ b/app/test/Makefile
@@ -152,9 +152,11 @@  CFLAGS += -D_GNU_SOURCE
 
 # Disable VTA for memcpy test
 ifeq ($(CC), gcc)
+ifeq ($(shell test $(GCC_VERSION) -ge 44 && echo 1), 1)
 CFLAGS_test_memcpy.o += -fno-var-tracking-assignments
 CFLAGS_test_memcpy_perf.o += -fno-var-tracking-assignments
 endif
+endif
 
 # this application needs libraries first
 DEPDIRS-y += lib