summaryrefslogtreecommitdiff
path: root/Makefile.toolchain
diff options
context:
space:
mode:
authorAllen Webb <allenwebb@google.com>2018-11-15 16:41:17 -0800
committerchrome-bot <chrome-bot@chromium.org>2018-11-16 19:50:43 -0800
commitda4d64502178778db56fda6419fd9cf2dc9f6df2 (patch)
tree00eaada93b781f00afceb5fd00f92951efafed12 /Makefile.toolchain
parent65a3697907899c90780fe8419e69b4dba54797ac (diff)
downloadchrome-ec-da4d64502178778db56fda6419fd9cf2dc9f6df2.tar.gz
Makefile.toolchain: Add TEST_FUZZ checks.
This prevents a bunch of warnings that show when trying to run pkg-config for libprotobuf-mutator when not building the fuzzer targets. BRANCH=None BUG=None TEST=make -j buildall Change-Id: Idf8de959d86db744754cd237796ccaacd3668a63 Signed-off-by: Allen Webb <allenwebb@google.com> Reviewed-on: https://chromium-review.googlesource.com/1338605 Reviewed-by: Mike Frysinger <vapier@chromium.org>
Diffstat (limited to 'Makefile.toolchain')
-rw-r--r--Makefile.toolchain2
1 files changed, 2 insertions, 0 deletions
diff --git a/Makefile.toolchain b/Makefile.toolchain
index fb2f9b3f1f..7cb8e212d1 100644
--- a/Makefile.toolchain
+++ b/Makefile.toolchain
@@ -106,6 +106,7 @@ endif
LIBFTDI_CFLAGS:=$(shell $(PKG_CONFIG) --cflags lib${LIBFTDI_NAME})
LIBFTDI_LDLIBS:=$(shell $(PKG_CONFIG) --libs lib${LIBFTDI_NAME})
+ifeq ($(TEST_FUZZ),y)
LIBPROTOBUF_CFLAGS:=$(shell $(PKG_CONFIG) --cflags protobuf)
LIBPROTOBUF_LDLIBS:=$(shell $(PKG_CONFIG) --libs protobuf)
@@ -113,6 +114,7 @@ LIBPROTOBUF_MUTATOR_CFLAGS:=${LIBPROTOBUF_CFLAGS} \
$(shell $(PKG_CONFIG) --cflags libprotobuf-mutator)
LIBPROTOBUF_MUTATOR_LDLIBS:=$(shell $(PKG_CONFIG) --libs libprotobuf-mutator) \
${LIBPROTOBUF_LDLIBS}
+endif
BUILD_CFLAGS= $(LIBFTDI_CFLAGS) $(BUILD_CPPFLAGS) -O3 $(CFLAGS_DEBUG) $(CFLAGS_WARN)
HOST_CFLAGS=$(HOST_CPPFLAGS) -O3 $(CFLAGS_DEBUG) $(CFLAGS_WARN) -DHOST_TOOLS_BUILD