xen: Mini-OS source code with make links target applied

Mini-OS is a tiny OS kernel distributed with the Xen Project Hypervisor
sources. It is mainly used as operating system for stub domains that are
used for Dom0 Disaggregation.

The Mini-OS source tree is updated and released in coordination with Xen
releases. The Mini-OS source tree and architecture-specific symbolic
links are required for building the dependencies used to build Xen
stubodmains. For convenience, the make links target was executed before
packaging. Otherwise, this is a source package. The current build
methods for Xen stubdomains require either a source archive which
contains the Mini-OS source code or execution of a make target that will
fetch the appropriate Mini-OS source tree from it's git repository. This
recipe removes the mysticism of relating to the version of Mini-OS being
used and it's origins and provides the flexibility to easily changes
versions or patch as necessary.

Signed-off-by: Kurt Bodiker <kurt.bodiker@braintrust-us.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
This commit is contained in:
Kurt Bodiker 2018-05-01 10:05:29 -04:00 committed by Bruce Ashfield
parent 9f3e354bc3
commit e5cfb60540
3 changed files with 89 additions and 0 deletions

View File

@ -0,0 +1,43 @@
From d991bdbc062248221511ecb795617c36b37e1d2e Mon Sep 17 00:00:00 2001
From: Wei Liu <wei.liu2@citrix.com>
Date: Wed, 9 Aug 2017 13:15:48 +0100
Subject: [PATCH] lib/math.c: implement __udivmoddi4
Some code compiled by gcc 7 requires this.
Signed-off-by: Wei Liu <wei.liu2@citrix.com>
Reviewed-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
---
lib/math.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/lib/math.c b/lib/math.c
index 561393e..b98cc1d 100644
--- a/lib/math.c
+++ b/lib/math.c
@@ -6,6 +6,7 @@
* File: math.c
* Author: Rolf Neugebauer (neugebar@dcs.gla.ac.uk)
* Changes:
+ * Implement __udivmoddi4 (Wei Liu <wei.liu2@citrix.com>)
*
* Date: Aug 2003
*
@@ -397,6 +398,15 @@ __umoddi3(u_quad_t a, u_quad_t b)
}
/*
+ * Returns the quotient and places remainder in r
+ */
+u_quad_t
+__udivmoddi4(u_quad_t a, u_quad_t b, u_quad_t *r)
+{
+ return __qdivrem(a, b, r);
+}
+
+/*
* From
* moddi3.c
*/
--
2.11.0

View File

@ -0,0 +1,28 @@
# Copyright (C) 2018 kebodiker <kurt.bodiker@braintrust-us.com>
# Released under the MIT license (see COPYING.MIT for the terms)
require stubdom.inc
# clear this out to break dependency circle
DEPENDS = ""
do_configure() {
${MAKE} -C ${WORKDIR}/mini-os links
}
# Nothing to configure or compile
do_compile[noexec] = "1"
# needed because this directory isn't typically part of a sysroot
SYSROOT_DIRS += "${prefix}/mini-os"
RDEPENDS_${PN}-dev = "perl"
FILES_${PN}-dev = "\
${prefix} \
"
do_install() {
install -d ${D}${prefix}/mini-os
cp -r -t ${D}${prefix}/mini-os ${S}/*
rm -rf ${D}${prefix}/mini-os/scripts
}

View File

@ -0,0 +1,18 @@
# Copyright (C) 2017 Kurt Bodiker <kurt.bodiker@braintrust-us.com>
# Released under the MIT license (see COPYING.MIT for the terms)
DESCRIPTION = "Mini-OS is a tiny OS kernel distributed with the Xen Project"
HOMEPAGE = "https://wiki.xenproject.org/wiki/Mini-OS"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=8a437231894440a8f7629caa372243d0"
# git commit hash for tags: xen-RELEASE-4.9.0, xen-RELEASE-4.9.1, xen-RELEASE-4.9.2
SRCREV_minios = "ca013fa9baf92f47469ba1f2e1aaa31c41d8a0bb"
SRC_URI = "\
git://xenbits.xen.org/mini-os.git;protocol=git;nobranch=1;destsuffix=mini-os;name=minios \
file://mini-os_udivmoddi4-gcc7.patch \
"
S="${WORKDIR}/mini-os"
B="${S}"
require mini-os.inc