SUMMARY = "A simple Hello application"
|
|
LICENSE = "MIT"
|
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
|
|
python do_display_banner() {
|
bb.plain("***********************************************");
|
bb.plain("* *");
|
bb.plain("* Example recipe for hello application *");
|
bb.plain("* *");
|
bb.plain("***********************************************");
|
}
|
|
# An example to add a new task
|
addtask display_banner before do_build
|
|
# Source file list, will auto search in the subdir
|
|
FILESEXTRAPATHS:prepend := "${THISDIR}/src:"
|
SRC_URI = "file://hello.c \
|
file://Makefile \
|
"
|
|
# Application version and reversion
|
PV = "1"
|
PR = "r0"
|
|
# Must add this line, or throw error: No GNU_HASH
|
TARGET_CC_ARCH += "${LDFLAGS}"
|
|
S = "${WORKDIR}"
|
|
do_compile() {
|
make
|
}
|
|
# There is /usr/bin/hello in lmbench: dpkg-query -S hello
|
do_install() {
|
install -d ${D}${sbindir}
|
install -m 0755 ${S}/hello ${D}${sbindir}
|
}
|
|
# Install application to image file
|
FILES:${PN} = "${sbindir}/hello"
|