diff options
Diffstat (limited to 'meta-skeleton/recipes-skeleton')
6 files changed, 69 insertions, 17 deletions
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..8be7980919 --- /dev/null +++ b/meta-skeleton/recipes-skeleton/hello-single/hello_1.0.bb @@ -0,0 +1,18 @@ +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}/sources" +UNPACKDIR = "${S}" + +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..54b834d45f 100644 --- a/meta-skeleton/recipes-skeleton/service/service_0.1.bb +++ b/meta-skeleton/recipes-skeleton/service/service_0.1.bb @@ -1,20 +1,24 @@ SUMMARY = "The canonical example of init scripts" SECTION = "base" -LICENSE = "GPLv2" -LIC_FILES_CHKSUM = "file://${WORKDIR}/COPYRIGHT;md5=349c872e0066155e1818b786938876a4" +DESCRIPTION = "This recipe is a canonical example of init scripts" +LICENSE = "GPL-2.0-only" +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=349c872e0066155e1818b786938876a4" SRC_URI = "file://skeleton \ file://skeleton_test.c \ file://COPYRIGHT \ " +S = "${WORKDIR}/sources" +UNPACKDIR = "${S}" + do_compile () { - ${CC} ${CFLAGS} ${LDFLAGS} ${WORKDIR}/skeleton_test.c -o ${WORKDIR}/skeleton-test + ${CC} ${CFLAGS} ${LDFLAGS} ${S}/skeleton_test.c -o ${B}/skeleton-test } do_install () { install -d ${D}${sysconfdir}/init.d - cat ${WORKDIR}/skeleton | \ + cat ${S}/skeleton | \ sed -e 's,/etc,${sysconfdir},g' \ -e 's,/usr/sbin,${sbindir},g' \ -e 's,/var,${localstatedir},g' \ @@ -23,9 +27,9 @@ do_install () { chmod a+x ${D}${sysconfdir}/init.d/skeleton install -d ${D}${sbindir} - install -m 0755 ${WORKDIR}/skeleton-test ${D}${sbindir}/ + install -m 0755 ${S}/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..b0d96e7f71 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" @@ -10,7 +9,8 @@ SRC_URI = "file://file1 \ file://file3 \ file://file4" -S = "${WORKDIR}" +S = "${WORKDIR}/sources" +UNPACKDIR = "${S}" PACKAGES =+ "${PN}-user3" @@ -30,19 +30,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 +69,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: |