From a186c746e431831ccbd459be2175cdaa7ed42a54 Mon Sep 17 00:00:00 2001 From: Michael Opdenacker Date: Thu, 29 Jul 2021 15:34:51 +0200 Subject: meta-skeleton: add recipe examples from documentation sources This adds three examples previously located in the yocto-docs repository (under documentation/ref-manual/examples). The examples were not used for building the documentation so it's better to keep them here where they can automatically be tested. Fixed the "hello-single" to add a version number to the .bb file. After this, all examples build fine with the "master" branch of Poky. Note that the "mtd-utils" example, and example of a recipe for an Autotools page, was not copied over. It doesn't build any more, and anyway, we already have an official recipe for a recent version of "mtd-utils" in OE-core. Signed-off-by: Michael Opdenacker Signed-off-by: Richard Purdie --- .../recipes-skeleton/hello-single/hello_1.0.bb | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 meta-skeleton/recipes-skeleton/hello-single/hello_1.0.bb (limited to 'meta-skeleton/recipes-skeleton/hello-single/hello_1.0.bb') diff --git a/meta-skeleton/recipes-skeleton/hello-single/hello_1.0.bb b/meta-skeleton/recipes-skeleton/hello-single/hello_1.0.bb new file mode 100644 index 0000000000..90d3aefd86 --- /dev/null +++ b/meta-skeleton/recipes-skeleton/hello-single/hello_1.0.bb @@ -0,0 +1,17 @@ +DESCRIPTION = "Simple helloworld application" +SECTION = "examples" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" + +SRC_URI = "file://helloworld.c" + +S = "${WORKDIR}" + +do_compile() { + ${CC} ${LDFLAGS} helloworld.c -o helloworld +} + +do_install() { + install -d ${D}${bindir} + install -m 0755 helloworld ${D}${bindir} +} -- cgit 1.2.3-korg