[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Minios-devel] [UNIKRAFT PATCHv4 02/43] build: Introduce a new variable UK_FAMILY


  • To: <minios-devel@xxxxxxxxxxxxxxxxxxxx>, <simon.kuenzer@xxxxxxxxx>
  • From: Wei Chen <Wei.Chen@xxxxxxx>
  • Date: Fri, 6 Jul 2018 09:03:15 +0000
  • Authentication-results: spf=fail (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; lists.xenproject.org; dkim=none (message not signed) header.d=none;lists.xenproject.org; dmarc=none action=none header.from=arm.com;
  • Cc: Kaly.Xin@xxxxxxx, nd@xxxxxxx, wei.chen@xxxxxxx
  • Delivery-date: Fri, 06 Jul 2018 09:04:19 +0000
  • List-id: Mini-os development list <minios-devel.lists.xenproject.org>
  • Nodisclaimer: True
  • Spamdiagnosticmetadata: NSPM
  • Spamdiagnosticoutput: 1:99

This patch series modifies the folder layout organized by CPU
families like:
unikraft----arch----arm----arm
              |      |-----arm64
              |
              |-----x86----x86
                     |-----x86_64

In this case, we introduce a new variable UK_FAMILY for build scipts.
we should not expect the user to set or select UK_FAMILY in a menu or
by setting the variable externally. So we retrieve UK_FAMILY directly
from CONFIG_UK_ARCH. Because of this we can keep Compiler.uk, Makefile.uk,
and Config.uk directly under the UK_FAMILY directory.

Signed-off-by: Wei Chen <Wei.Chen@xxxxxxx>
---
 Makefile | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/Makefile b/Makefile
index adeaac9..178ebbc 100644
--- a/Makefile
+++ b/Makefile
@@ -338,6 +338,16 @@ endif
 override ARCH := $(CONFIG_UK_ARCH)
 export CONFIG_UK_ARCH ARCH
 
+export UK_FAMILY ?= $(shell echo "$(CONFIG_UK_ARCH)" | \
+                  sed -e "s/-.*//" \
+                      -e 's//\1/' \
+                      -e 's/x86.*/x86/' \
+                      -e 's/sparc64/sparc/' \
+                      -e 's/arm.*/arm/' \
+                      -e 's/powerpc.*/powerpc/' \
+                      -e 's/sh.*/sh/' )
+
+
 # Quick-check if architecture exists
 ifeq ($(filter $(null_targets) print-vars,$(MAKECMDGOALS)),)
 ifeq ($(wildcard $(CONFIG_UK_BASE)/arch/$(ARCH)/Makefile.uk),)
-- 
2.17.1


_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.