0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Yocto LinuxをUbuntu 19.10で作る

Posted at

Yocto Linuxのメモ書き

dockerビルド用のDockerファイル

Dockerfileを作る

FROM ubuntu:16.04
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get update && apt-get dist-upgrade -y && apt-get autoremove --purge -y \
 && apt-get install -y \
     gawk wget git-core diffstat unzip texinfo gcc-multilib \
     build-essential chrpath socat cpio python python3 python3-pip python3-pexpect \
     xz-utils debianutils iputils-ping python3-git python3-jinja2 libegl1-mesa libsdl1.2-dev \
     xterm \ 
     locales \
 && rm -rf /var/lib/apt/lists/*

# Locales
RUN dpkg-reconfigure locales \
 && locale-gen en_US.UTF-8 \
 && update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8
ENV LC_ALL   en_US.UTF-8
ENV LANG     en_US.UTF-8
ENV LANGUAGE en_US.UTF-8

dockerイメージ作成

下記コマンドでイメージ作成

sudo docker build -t yocto:latest .

docker作業

イメージを動かす

sudo docker run --rm -u $(id -u):$(id -g) -v $(pwd):$(pwd) -w $(pwd) -i yocto:latest /bin/bash

現在のフォルダをdocker上にマウントして、ファイル作成

git clone -b pyro git://git.yoctoproject.org/poky
git clone -b pyro git://git.openembedded.org/meta-openembedded
git clone -b pyro git://git.yoctoproject.org/meta-raspberrypi
cd poky

souce poky/oe-init-build-env

bitbake-layers add-layer ../../meta-raspberrypi
bitbake-layers add-layer ../../meta-openembedded/meta-oe
bitbake-layers add-layer ../../meta-openembedded/meta-python
bitbake-layers add-layer ../../meta-openembedded/meta-browser
bitbake-layers add-layer ../../meta-openembedded/meta-networking

local.confのMACHINE名をファイルを置き換える

MACHINE ?= "raspberrypi3"

ビルドコマンドで実行

bitbake rpi-basic-image
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?