diff options
Diffstat (limited to 'meta-skeleton')
16 files changed, 86 insertions, 58 deletions
diff --git a/meta-skeleton/COPYING.MIT b/meta-skeleton/COPYING.MIT deleted file mode 100644 index fb950dc69f..0000000000 --- a/meta-skeleton/COPYING.MIT +++ /dev/null @@ -1,17 +0,0 @@ -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. diff --git a/meta-skeleton/README.skeleton b/meta-skeleton/README.skeleton new file mode 100644 index 0000000000..35503c1f7d --- /dev/null +++ b/meta-skeleton/README.skeleton @@ -0,0 +1,4 @@ +meta-skeleton +============= + +The meta-skeleton layer contains example recipes and configuration files. diff --git a/meta-skeleton/conf/layer.conf b/meta-skeleton/conf/layer.conf index 13bda7b570..963d2d5ce9 100644 --- a/meta-skeleton/conf/layer.conf +++ b/meta-skeleton/conf/layer.conf @@ -14,4 +14,4 @@ LAYERVERSION_skeleton = "1" LAYERDEPENDS_skeleton = "core" -LAYERSERIES_COMPAT_skeleton = "thud" +LAYERSERIES_COMPAT_skeleton = "styhead" diff --git a/meta-skeleton/conf/multilib-example.conf b/meta-skeleton/conf/multilib-example.conf index da6da7f1f6..07fd7b6ce4 100644 --- a/meta-skeleton/conf/multilib-example.conf +++ b/meta-skeleton/conf/multilib-example.conf @@ -10,4 +10,4 @@ MACHINE = "qemux86-64" require conf/multilib.conf MULTILIBS = "multilib:lib32" -DEFAULTTUNE_virtclass-multilib-lib32 = "x86" +DEFAULTTUNE:virtclass-multilib-lib32 = "x86" diff --git a/meta-skeleton/conf/multilib-example2.conf b/meta-skeleton/conf/multilib-example2.conf index 2596f61d9f..39f385fcca 100644 --- a/meta-skeleton/conf/multilib-example2.conf +++ b/meta-skeleton/conf/multilib-example2.conf @@ -10,4 +10,4 @@ MACHINE = "qemux86-64" require conf/multilib.conf MULTILIBS = "multilib:libx32" -DEFAULTTUNE_virtclass-multilib-libx32 = "x86-64-x32" +DEFAULTTUNE:virtclass-multilib-libx32 = "x86-64-x32" diff --git a/meta-skeleton/recipes-core/busybox/busybox_%.bbappend b/meta-skeleton/recipes-core/busybox/busybox_%.bbappend index 64cdefc76d..3c936eb713 100644 --- a/meta-skeleton/recipes-core/busybox/busybox_%.bbappend +++ b/meta-skeleton/recipes-core/busybox/busybox_%.bbappend @@ -2,11 +2,12 @@ # mechanism as the linux-yocto kernel recipe. # # The entries here will override any entries in the base busybox recipe +# when DISTRO = "mydistro" is defined in your conf/local.conf file. # # More details can be found in the Kernel Dev Manual # http://www.yoctoproject.org/docs/current/kernel-dev/kernel-dev.html#changing-the-configuration -FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" +FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:" -SRC_URI += " \ +SRC_URI:append:mydistro = " \ file://no_rfkill.cfg \ " diff --git a/meta-skeleton/recipes-kernel/hello-mod/files/hello.c b/meta-skeleton/recipes-kernel/hello-mod/files/hello.c index f3c0d372eb..4f73455d20 100644 --- a/meta-skeleton/recipes-kernel/hello-mod/files/hello.c +++ b/meta-skeleton/recipes-kernel/hello-mod/files/hello.c @@ -2,32 +2,23 @@ * * Copyright (C) 2011 Intel Corporation. All rights reserved. * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; version 2 of the License. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See - * the GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * SPDX-License-Identifier: GPL-2.0-only * *****************************************************************************/ #include <linux/module.h> -int init_module(void) +static int __init hello_init(void) { - printk("Hello World!\n"); + pr_info("Hello World!\n"); return 0; } -void cleanup_module(void) +static void __exit hello_exit(void) { - printk("Goodbye Cruel World!\n"); + pr_info("Goodbye Cruel World!\n"); } +module_init(hello_init); +module_exit(hello_exit); MODULE_LICENSE("GPL"); diff --git a/meta-skeleton/recipes-kernel/hello-mod/hello-mod_0.1.bb b/meta-skeleton/recipes-kernel/hello-mod/hello-mod_0.1.bb index 3d33446500..a2fb212a68 100644 --- a/meta-skeleton/recipes-kernel/hello-mod/hello-mod_0.1.bb +++ b/meta-skeleton/recipes-kernel/hello-mod/hello-mod_0.1.bb @@ -1,5 +1,6 @@ SUMMARY = "Example of how to build an external Linux kernel module" -LICENSE = "GPLv2" +DESCRIPTION = "${SUMMARY}" +LICENSE = "GPL-2.0-only" LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e" inherit module @@ -14,4 +15,4 @@ S = "${WORKDIR}" # The inherit of module.bbclass will automatically name module packages with # "kernel-module-" prefix as required by the oe-core build environment. -RPROVIDES_${PN} += "kernel-module-hello" +RPROVIDES:${PN} += "kernel-module-hello" diff --git a/meta-skeleton/recipes-kernel/linux/linux-yocto-custom.bb b/meta-skeleton/recipes-kernel/linux/linux-yocto-custom.bb index 6194d4f8da..9437240fcf 100644 --- a/meta-skeleton/recipes-kernel/linux/linux-yocto-custom.bb +++ b/meta-skeleton/recipes-kernel/linux/linux-yocto-custom.bb @@ -1,6 +1,6 @@ +SUMMARY = "An example kernel recipe that uses the linux-yocto and oe-core" # linux-yocto-custom.bb: # -# An example kernel recipe that uses the linux-yocto and oe-core # kernel classes to apply a subset of yocto kernel management to git # managed kernel repositories. # @@ -57,14 +57,14 @@ require recipes-kernel/linux/linux-yocto.inc SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git;protocol=git;nocheckout=1;name=machine" LINUX_VERSION ?= "4.2" -LINUX_VERSION_EXTENSION_append = "-custom" +LINUX_VERSION_EXTENSION:append = "-custom" # Modify SRCREV to a different commit hash in a copy of this recipe to # build a different release of the Linux kernel. # tag: v4.2 64291f7db5bd8150a74ad2036f1037e6a0428df2 SRCREV_machine="64291f7db5bd8150a74ad2036f1037e6a0428df2" -PV = "${LINUX_VERSION}+git${SRCPV}" +PV = "${LINUX_VERSION}+git" # Override COMPATIBLE_MACHINE to include your machine in a copy of this recipe # file. Leaving it empty here ensures an early explicit build failure. diff --git a/meta-skeleton/recipes-multilib/images/core-image-multilib-example.bb b/meta-skeleton/recipes-multilib/images/core-image-multilib-example.bb index f13186f933..1290968b9d 100644 --- a/meta-skeleton/recipes-multilib/images/core-image-multilib-example.bb +++ b/meta-skeleton/recipes-multilib/images/core-image-multilib-example.bb @@ -1,5 +1,4 @@ -# -# An example of a multilib image +SUMMARY = "An example of a multilib image" # # This example includes a lib32 version of bash into an otherwise standard # sato image. It assumes a "lib32" multilib has been enabled in the user's @@ -7,7 +6,7 @@ # # First include a base image to base things off -require recipes-sato/images/core-image-sato.bb +require recipes-graphics/images/core-image-weston.bb # Now add the multilib packages we want to install IMAGE_INSTALL += "lib32-bash" diff --git a/meta-skeleton/recipes-skeleton/hello-autotools/hello_2.10.bb b/meta-skeleton/recipes-skeleton/hello-autotools/hello_2.10.bb new file mode 100644 index 0000000000..a64088fbaa --- /dev/null +++ b/meta-skeleton/recipes-skeleton/hello-autotools/hello_2.10.bb @@ -0,0 +1,9 @@ +DESCRIPTION = "GNU Helloworld application" +SECTION = "examples" +LICENSE = "GPL-3.0-only" +LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504" + +SRC_URI = "${GNU_MIRROR}/hello/hello-${PV}.tar.gz" +SRC_URI[sha256sum] = "31e066137a962676e89f69d1b65382de95a7ef7d914b8cb956f41ea72e0f516b" + +inherit autotools-brokensep gettext diff --git a/meta-skeleton/recipes-skeleton/hello-single/files/helloworld.c b/meta-skeleton/recipes-skeleton/hello-single/files/helloworld.c new file mode 100644 index 0000000000..fc7169b7b8 --- /dev/null +++ b/meta-skeleton/recipes-skeleton/hello-single/files/helloworld.c @@ -0,0 +1,8 @@ +#include <stdio.h> + +int main(void) +{ + printf("Hello world!\n"); + + return 0; +} 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} +} diff --git a/meta-skeleton/recipes-skeleton/libxpm/libxpm_3.5.6.bb b/meta-skeleton/recipes-skeleton/libxpm/libxpm_3.5.6.bb new file mode 100644 index 0000000000..1fcbbdd65e --- /dev/null +++ b/meta-skeleton/recipes-skeleton/libxpm/libxpm_3.5.6.bb @@ -0,0 +1,13 @@ +require recipes-graphics/xorg-lib/xorg-lib-common.inc + +DESCRIPTION = "X11 Pixmap library" +LICENSE = "X-BSD" +LIC_FILES_CHKSUM = "file://COPYING;md5=3e07763d16963c3af12db271a31abaa5" +DEPENDS += "libxext" +PE = "1" + +XORG_PN = "libXpm" + +PACKAGES =+ "sxpm cxpm" +FILES:cxpm = "${bindir}/cxpm" +FILES:sxpm = "${bindir}/sxpm" diff --git a/meta-skeleton/recipes-skeleton/service/service_0.1.bb b/meta-skeleton/recipes-skeleton/service/service_0.1.bb index 6416618dcb..912f6b0f61 100644 --- a/meta-skeleton/recipes-skeleton/service/service_0.1.bb +++ b/meta-skeleton/recipes-skeleton/service/service_0.1.bb @@ -1,6 +1,7 @@ SUMMARY = "The canonical example of init scripts" SECTION = "base" -LICENSE = "GPLv2" +DESCRIPTION = "This recipe is a canonical example of init scripts" +LICENSE = "GPL-2.0-only" LIC_FILES_CHKSUM = "file://${WORKDIR}/COPYRIGHT;md5=349c872e0066155e1818b786938876a4" SRC_URI = "file://skeleton \ @@ -8,6 +9,8 @@ SRC_URI = "file://skeleton \ file://COPYRIGHT \ " +S = "${WORKDIR}" + do_compile () { ${CC} ${CFLAGS} ${LDFLAGS} ${WORKDIR}/skeleton_test.c -o ${WORKDIR}/skeleton-test } @@ -26,6 +29,6 @@ do_install () { install -m 0755 ${WORKDIR}/skeleton-test ${D}${sbindir}/ } -RDEPENDS_${PN} = "initscripts" +RDEPENDS:${PN} = "initscripts" -CONFFILES_${PN} += "${sysconfdir}/init.d/skeleton" +CONFFILES:${PN} += "${sysconfdir}/init.d/skeleton" diff --git a/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb b/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb index 7c5b9d0503..8437a5a774 100644 --- a/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb +++ b/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb @@ -1,7 +1,6 @@ SUMMARY = "Example recipe for using inherit useradd" DESCRIPTION = "This recipe serves as an example for using features from useradd.bbclass" SECTION = "examples" -PR = "r1" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" @@ -30,19 +29,19 @@ USERADD_PACKAGES = "${PN} ${PN}-user3" # useradd command. Multiple users can be created by separating # the commands with a semicolon. Here we'll create two users, # user1 and user2: -USERADD_PARAM_${PN} = "-u 1200 -d /home/user1 -r -s /bin/bash user1; -u 1201 -d /home/user2 -r -s /bin/bash user2" +USERADD_PARAM:${PN} = "-u 1200 -d /home/user1 -r -s /bin/bash user1; -u 1201 -d /home/user2 -r -s /bin/bash user2" -# user3 will be managed in the useradd-example-user3 pacakge: -# As an example, we use the -P option to set clear text password for user3 -USERADD_PARAM_${PN}-user3 = "-u 1202 -d /home/user3 -r -s /bin/bash -P 'user3' user3" +# user3 will be managed in the useradd-example-user3 package: +# As an example, we use the -p option to set password ('user3') for user3 +USERADD_PARAM:${PN}-user3 = "-u 1202 -d /home/user3 -r -s /bin/bash -p '\$6\$XAWr.8nc\$bUE4pYYaVb8n6BbnBitU0zeJMtfhTpFpiOBLL9zRl4e4YQo88UU4r/1kjRzmTimCy.BvDh4xoFwVqcO.pihLa1' user3" # GROUPADD_PARAM works the same way, which you set to the options # you'd normally pass to the groupadd command. This will create # groups group1 and group2: -GROUPADD_PARAM_${PN} = "-g 880 group1; -g 890 group2" +GROUPADD_PARAM:${PN} = "-g 880 group1; -g 890 group2" # Likewise, we'll manage group3 in the useradd-example-user3 package: -GROUPADD_PARAM_${PN}-user3 = "-g 900 group3" +GROUPADD_PARAM:${PN}-user3 = "-g 900 group3" do_install () { install -d -m 755 ${D}${datadir}/user1 @@ -69,8 +68,8 @@ do_install () { chgrp -R group3 ${D}${datadir}/user3 } -FILES_${PN} = "${datadir}/user1/* ${datadir}/user2/*" -FILES_${PN}-user3 = "${datadir}/user3/*" +FILES:${PN} = "${datadir}/user1/* ${datadir}/user2/*" +FILES:${PN}-user3 = "${datadir}/user3/*" # Prevents do_package failures with: # debugsources.list: No such file or directory: |