## page was renamed from IntelGalileo/Intel Galileo - Create your own layer ## For instruction on writing tutorials ## http://www.ros.org/wiki/WritingTutorials #################################### ##FILL ME IN #################################### ## for a custom note with links: ## note = ## for the canned note of "This tutorial assumes that you have completed the previous tutorials:" just add the links ## note.0= ## descriptive title for the tutorial ## title = Creating your own layer ## multi-line description to be displayed in search ## description = Create a new layer and add files to the Yocto image. ## the next tutorial description (optional) ## next = ## links to next tutorial (optional) ## next.0.link= ## next.1.link= ## what level user is this tutorial for ## level= IntermediateCategory ## keywords = #################################### <> <> == create your own layer == This example will add a custom .bashrc file to the image. * cd .. {{{ yocto-layer create mine cd meta-mine mkdir recipes-mine cd recipes-mine mkdir envfiles cd envfiles mkdir envfiles-0.1 }}} Edit a new file called "envfiles_0.1.bb": {{{ DESCRIPTION = "Environment customizations" SECTION = "examples" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" FILES_${PN} += "/home/root/.bashrc" PR = "r0" SRC_URI = "file://bashrc_root" S = "${WORKDIR}" do_install() { mkdir -p ${D}/home/root cp ${S}/bashrc_root ${D}/home/root/.bashrc }}} Also create envfiles-0.1/bashrc_root: {{{ # this is the bashrcfile from my yocto recipe PS1="[\[\033[01;33m\]\u@\h \W\[\033[00m\]]$ " if [ -n "$SSH_CLIENT" ]; then PS1="[\[\033[01;34m\]\u@\h \W\[\033[00m\]] \[\033[01;31m\]#\[\033[00m\] " fi }}} ## AUTOGENERATED DO NOT DELETE ## TutorialCategory ## FILL IN THE STACK TUTORIAL CATEGORY HERE