summaryrefslogtreecommitdiffstats
path: root/src/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'src/Makefile')
-rw-r--r--src/Makefile26
1 files changed, 16 insertions, 10 deletions
diff --git a/src/Makefile b/src/Makefile
index 0b62da3e..81143ae9 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -19,22 +19,28 @@
# Contributors:
# Aihua Li, Huawei Technologies.
-include mk/master.mk
+SUBBUILDS = src_cuse src_vanilla
+.PHONY: vhost subbuilds $(SUBBUILDS)
-export VHOST_USER
+all: vhost subbuilds
-# specify upstream package as SUBDIRS - common terms as suggest by gnu-make
+subbuilds: $(SUBBUILDS)
+$(SUBBUILDS): vhost
+ $(AT)mkdir -p ../$@/mk
+ $(AT)cp -rf mk/* ../$@/mk
+ $(AT)cp -rf package-list.mk ../$@/
+ $(AT)cp Makefile.$@ ../$@/Makefile
+ $(AT)$(MAKE) -C ../$@
+
+vhost:
+export VHOST_USER
+include mk/master.mk
SUBDIRS =
SUBDIRS += l2fwd
-ifeq ($(WITH_LINUX),)
SUBDIRS += dpdk
-endif
SUBDIRS += ovs
SUBDIRS += qemu
-
-ifeq ($(WITH_LINUX),)
-# specify package dependency here if needed
ovs: dpdk
-endif
-
+WITH_LINUX =
+VHOST_USER = y
include mk/make-subsys.mk