- tar 1.28以上版本
- Python 3.5.0以上版本
- gcc 5.0以上版本
二、安装依赖
$ sudo apt-get install gawk wget git-core diffstat unzip texinfo gcc-multilib \
build-essential chrpath socat cpio python3 python3-pip python3-pexpect \
xz-utils debianutils iputils-ping python3-git python3-jinja2 libegl1-mesa libsdl1.2-dev \
pylint3 xterm
三、下载Poky并切换版本分支
$ git clone git://git.yoctoproject.org/poky
$ cd poky
$ git fetch --tags
$ git tag
$ git checkout tags/yocto-3.1 -b my-yocto-3.1
四、构建镜像
(1)进入Poky目录
$ cd poky
(2)初始化编译环境
$ ./oe-init-build-env
You had no conf/local.conf file. This configuration file has therefore been
created for you with some default values. You may wish to edit it to, for
example, select a different MACHINE (target hardware). See conf/local.conf
for more information as common configuration options are commented.
You had no conf/bblayers.conf file. This configuration file has therefore been
created for you with some default values. To add additional metadata layers
into your configuration please add entries to conf/bblayers.conf.
The Yocto Project has extensive documentation about OE including a reference
manual which can be found at:
http://yoctoproject.org/documentation
For more information about OpenEmbedded see their website:
http://www.openembedded.org/
### Shell environment set up for builds. ###
You can now run 'bitbake <target>'
Common targets are:
core-image-minimal
core-image-sato
meta-toolchain
meta-ide-support
You can also run generated qemu images with a command like 'runqemu qemux86'
Other commonly useful commands are:
- 'devtool' and 'recipetool' handle common recipe tasks
- 'bitbake-layers' handles common layer tasks
- 'oe-pkgdata-util' handles common target package tasks
(3)添加bitbake环境变量
当前位于poky目录下:
$ cd bitbake/bin
$ pwd
/home/neutionwei/poky/bitbake/bin
$ export PATH=$PATH:/home/neutionwei/poky/bitbake/bin
$ cd -
(4)编译minimal镜像
当前位于poky目录下:
$ cd build
$ bitbake core-image-minimal
Parsing recipes: 100% |######################################################################################################################################################################| Time: 0:00:21
Parsing of 768 .bb files complete (0 cached, 768 parsed). 1300 targets, 40 skipped, 0 masked, 0 errors.
NOTE: Resolving any missing task queue dependencies
Build Configuration:
BB_VERSION = "1.46.0"
BUILD_SYS = "x86_64-linux"
NATIVELSBSTRING = "ubuntu-18.04"
TARGET_SYS = "x86_64-poky-linux"
MACHINE = "qemux86-64"
DISTRO = "poky"
DISTRO_VERSION = "3.1"
TUNE_FEATURES = "m64 core2"
TARGET_FPU = ""
meta
meta-poky
meta-yocto-bsp = "my-yocto-3.1:5d47cdf448b6cff5bb7cc5b0ba0426b8235ec478"
NOTE: Fetching uninative binary shim from http://downloads.yoctoproject.org/releases/uninative/2.8/x86_64-nativesdk-libc.tar.xz;sha256sum=a09922172c3a439105e0ae6b943daad2d83505b17da0aba97961ff433b8c21ab
Initialising tasks: 100% |###################################################################################################################################################################| Time: 0:00:01
Sstate summary: Wanted 1159 Found 0 Missed 1159 Current 0 (0% match, 0% complete)
NOTE: Executing Tasks
(5)镜像输出目录
当前位于build目录下:
$ cd tmp/deploy/images/qemux86-64/
$ ls -al
total 28144
drwxr-xr-x 2 neutionwei neutionwei 4096 11月 1 04:20 .
## 最后
**自我介绍一下,小编13年上海交大毕业,曾经在小公司待过,也去过华为、OPPO等大厂,18年进入阿里一直到现在。**
**深知大多数Java工程师,想要提升技能,往往是自己摸索成长,自己不成体系的自学效果低效漫长且无助。**
**因此收集整理了一份《2024年嵌入式&物联网开发全套学习资料》,初衷也很简单,就是希望能够帮助到想自学提升又不知道该从何学起的朋友,同时减轻大家的负担。**
![img](https://img-blog.csdnimg.cn/img_convert/c1c9570a93e938ff3bedfa15196e0920.png)
![img](https://img-blog.csdnimg.cn/img_convert/da1d10fe87b84b6733dbfcc275bdf0c3.jpeg)
![img](https://img-blog.csdnimg.cn/img_convert/ba8d56bb925c3bae85279d62c90f00d4.png)
![img](https://img-blog.csdnimg.cn/img_convert/83a71cda2e447d43623d83a67e3dfdcc.png)
![img](https://img-blog.csdnimg.cn/img_convert/25f1e31f4d21616069327d2bdcfd96a8.png)
![img](https://img-blog.csdnimg.cn/img_convert/dfc9f5648de5bb82ad946478c609a8f8.png)
![](https://img-blog.csdnimg.cn/img_convert/81e771f90771056ba5dfd6010bf08e5c.png)
**既有适合小白学习的零基础资料,也有适合3年以上经验的小伙伴深入学习提升的进阶课程,基本涵盖了95%以上嵌入式&物联网开发知识点,真正体系化!**
[**如果你觉得这些内容对你有帮助,需要这份全套学习资料的朋友可以戳我获取!!**](https://bbs.csdn.net/topics/618654289)
**由于文件比较大,这里只是将部分目录大纲截图出来,每个节点里面都包含大厂面经、学习笔记、源码讲义、实战项目、讲解视频,并且后续会持续更新**!!
以上嵌入式&物联网开发知识点,真正体系化!**
[**如果你觉得这些内容对你有帮助,需要这份全套学习资料的朋友可以戳我获取!!**](https://bbs.csdn.net/topics/618654289)
**由于文件比较大,这里只是将部分目录大纲截图出来,每个节点里面都包含大厂面经、学习笔记、源码讲义、实战项目、讲解视频,并且后续会持续更新**!!