2.2 KiB
2.2 KiB
Raspberry Pi with Yocto
- set-up working directory:
mkdir -p RASPBERRYPI/BSP
cd RASPBERRYPI/BSP
- Clone of Yocto:
git clone -b dora git://git.yoctoproject.org/poky.git
cd poky/
- Clone of meta de Raspberry Pi:
git clone -b dora https://github.com/djwillis/meta-raspberrypi.git
- Clone of meta Open Embedded:
git clone -b dora https://github.com/openembedded/meta-openembedded.git
- Force python 2.7:
mkdir pythonBase2
cd pythonBase2
ln -s /usr/bin/python2.7 python
ln -s /usr/bin/python2.7-config python-config
export PATH=`pwd`:$PATH
cd ..
- Initialize the configuration:
source oe-init-build-env raspberryPiBuild/
- update configuration file:
Open: conf/local.conf
find: MACHINE ??= "qemux86"
Remplace with: MACHINE ?= "raspberrypi"
find: PACKAGE_CLASSES ?= "package_rpm"
Remplace with: PACKAGE_CLASSES ?= "package_deb"
Add at the end:
BBMASK = "meta-raspberrypi/recipes-multimedia/libav|meta-raspberrypi/recipes-core/systemd"
Open: conf/bblayers.conf
find:
BBLAYERS ?= " \
/home/DoctorWho/RASPBERRYPI/BSP/poky/meta \
/home/DoctorWho/RASPBERRYPI/BSP/poky/meta-yocto \
/home/DoctorWho/RASPBERRYPI/BSP/poky/meta-yocto-bsp \
"
Remplace with:
BBLAYERS ?= " \
/home/DoctorWho/RASPBERRYPI/BSP/poky/meta \
/home/DoctorWho/RASPBERRYPI/BSP/poky/meta-yocto \
/home/DoctorWho/RASPBERRYPI/BSP/poky/meta-yocto-bsp \
/home/DoctorWho/RASPBERRYPI/BSP/poky/meta-raspberrypi \
/home/DoctorWho/RASPBERRYPI/BSP/poky/meta-openembedded/meta-oe \
"
- Build basic image:
Simply run:
bitbake core-image-minimal
display result:
ls -l tmp/deploy/images/raspberrypi/
- Burn image on the sd card:
cd tmp/deploy/images/raspberrypi/
sudo dd bs=1M if=core-image-minimal-raspberrypi.rpi-sdimg of=/dev/mmcblk0
- All is ready:
login: root
pasword root