]> git.droids-corp.org - dpdk.git/blobdiff - examples/qos_meter/Makefile
examples: detect default build directory
[dpdk.git] / examples / qos_meter / Makefile
index fe44e6418472389643fdd87b9df8f36f6512f683..fbcda09b20ff4890396fd7e8314dc7af4265c23b 100644 (file)
@@ -45,8 +45,8 @@ ifeq ($(RTE_SDK),)
 $(error "Please define RTE_SDK environment variable")
 endif
 
-# Default target, can be overridden by command line or environment
-RTE_TARGET ?= x86_64-native-linux-gcc
+# Default target, detect a build directory, by looking for a path with a .config
+RTE_TARGET ?= $(notdir $(abspath $(dir $(firstword $(wildcard $(RTE_SDK)/*/.config)))))
 
 include $(RTE_SDK)/mk/rte.vars.mk