20160707_jeffrey - silenceuncrio/diary GitHub Wiki
Index
- 0940 - 發 mail 問 AVNET 的 FAE 有關 U-Boot 設定成 NAND Boot 的 issue
- 0945 - web server 需要 dropbear 加密 先記錄
- 0950 - alarm sensor 警報器 零用金申請單
- 1050 - 整理 GitHub diary index
- 1055 - proposal - m300_proposal_kernel_mtd_driver_jeffrey
- 1130 - alarm sensor
- 1315 - proposal - m300_proposal_uboot_burn_image_nand_flash_jeffrey
- 1350 - AVNET 的 FAE 回信
- 1410 - 幫忙 寄
M300 Kick Off Meeting
- 1440 - 發現
bitbake u-boot-imx
出錯 - source code 權限有些被改成 root - 1505 -
Freescale Yocto Project User's Guide
-5.5 U-Boot configuration
- 1600 - machine configuration -
M300\fsl-release-bsp\sources\meta-fsl-arm\conf\machine\imx6ul14x14ddr3arm2.conf
- 1605 - machine configuration -
conf\machine\imx6ulevk.conf
- 1630 -
u-boot-fw-utils_2015.01.bb
- 1630 -
u-boot-ls1_2015.01.bb
- 1635 -
u-boot.inc
- 1640 -
bitbake u-boot-imx -c compile -vf
會呼叫u-boot.inc
的 do_compile () - 1835 - 警報器 隔壁庫房 測試
0940
ariel 希望我發個 mail 問 AVNET 的 FAE 有關 U-Boot 設定成 NAND Boot 的 issue
雖然我不覺得 Mike 能回答出什麼
不過這個案子是 ariel 主導
我還是 follow ariel 的節奏會比較順
Dear Mike,
有件事想請你幫我們
我參考 [Freescale Yocto Project User's Guide] 的 5.5 U-Boot configuration
將 U-Boot type 設定成 U-Boot NAND
然後利用
MACHINE=imx6ulevk bitbake -c deploy u-boot-imx
來產生 NAND Flash 用的 U-Boot
不過卻沒有產生 U-Boot image
請協助我們
謝謝
BR
Jeffrey
0945
ariel 提到了 web server 需要啥 dropbear 作啥加密什麼的
她又把 dropbear build 進去了
不過啥 rc init 會出錯
所以又先關掉啥的
請我幫忙注意一下
就先記錄下來吧
0950
昨晚為了 alarm sensor 先墊錢買了顆 警報器
順手寫了零用金申請單
為了省事讓硬體的 morris 去申請比較好
morris 不在位置上
警報器 連同 零用金申請單 先放他桌上
1050
花了一些時間整理 GitHub diary 的 index
前三天的事情超雜的...
1055
先寫 proposal - m300_proposal_kernel_mtd_driver_jeffrey
| Features | Schedule | Proposal | |---|---|---|---| | u-boot : Reduce image size | 6月10日 | m300_proposal_uboot_reduceImageSize_jeffrey| | u-boot : image layout - SD card | 6月17日 | - | | u-boot : image layout - NAND flash | 6月24日 | m300_proposal_uboot_imageLayout_NANDFlash_jeffrey | | kernel: EMMC/NAND MTD Driver | 7月8日 | m300_proposal_kernel_mtd_driver_jeffrey | | u-boot : burn image - NAND flash | 7月8日 | |
1130
吃飯前作一下 alarm sensor
info_cnt = 0 -- 有多少筆聲音資訊了
INFO_MAX = 10000 -- 收集這麼多筆資訊就來總結一次
adc_val = 0 -- 目前讀到的音量
-- adc.read(0) 只辨別得出 0V ~ 1V, 對應的數值範圍 0 ~ 1024
ADC_TRIGGER_LEVEL_HIGH = 1000 -- 音量要超過 high 這個 level 才算觸發
ADC_TRIGGER_LEVEL_MEDIUM = 750 -- 音量要超過 medium 這個 level 才算觸發
ADC_TRIGGER_LEVEL_LOW = 500 -- 音量要超過 low 這個 level 才算觸發
adc_trigger_level = ADC_TRIGGER_LEVEL_HIGH -- 用來設定目前音量要超過什麼程度才算能觸發什麼事件
adc_triggered_cnt = 0 -- 目前音量超過觸發 level 的累計次數
ADC_TRIGGERED_MAX = 2000 -- 累計次數達到此標準就當作是警報聲了
tmr.alarm(1, 1, tmr.ALARM_AUTO, function()
if info_cnt < INFO_MAX then
adc_val = adc.read(0)
if adc_val > adc_trigger_level then
adc_triggered_cnt = adc_triggered_cnt + 1
end
info_cnt = info_cnt + 1
else
-- 集滿 INFO_MAX 這麼多筆 info, 要來做些決策了
print("adc_triggered_cnt: "..adc_triggered_cnt) -- 決策前先把 adc_triggered_cnt 印出來看看
if adc_triggered_cnt > ADC_TRIGGERED_MAX then
-- 偵測到警報聲, 作些處置吧
print("adc_triggered_cnt more than "..ADC_TRIGGERED_MAX"! Alarm Detect!")
end
-- 下一次統計區間的開始, 相關統計值要歸零
info_cnt = 0
adc_triggered_cnt = 0
end
end)
...
1315
寫 proposal - m300_proposal_uboot_burn_image_nand_flash_jeffrey
| Features | Schedule | Proposal | |---|---|---|---| | u-boot : Reduce image size | 6月10日 | m300_proposal_uboot_reduceImageSize_jeffrey| | u-boot : image layout - SD card | 6月17日 | - | | u-boot : image layout - NAND flash | 6月24日 | m300_proposal_uboot_imageLayout_NANDFlash_jeffrey | | kernel: EMMC/NAND MTD Driver | 7月8日 | m300_proposal_kernel_mtd_driver_jeffrey | | u-boot : burn image - NAND flash | 7月8日 | m300_proposal_uboot_burn_image_nand_flash_jeffrey |
1350
AVNET 的 FAE 針對有關 U-Boot 設定成 NAND Boot 的 issue 回信了
Hello Jeffrey,
您的指令有錯哦,u-boot for NAND只有支援MACHINE imx6solosabreauto,不支援MACHINE=imx6ulevk,謝謝。
這個 mike 喔... 不過這有八成是為了讓 ariel 知道
就等 ariel 有進一步意見再說吧
1410
ariel 致電要我幫忙寄個 M300 Kick Off Meeting
的檔案給她
上傳 google doc 再下載 PDF 格式
隨信再附上 read only 的 google 文件超連結 - m300_kickoff.odp
結果馬上派上用場
mail attached PDF 被擋掉了
1440
發現直接使用 bitbake u-boot-imx
會出錯
jeffrey@jeffrey-VirtualBox:~/M300/fsl-release-bsp/build_small$ bitbake u-boot-imx
ERROR: Error parsing configuration files
Traceback (most recent call last):
File "/home/jeffrey/M300/fsl-release-bsp/sources/poky/bitbake/lib/bb/cookerdata.py", line 240, in CookerDataBuilder.parseBaseConfiguration():
try:
> self.parseConfigurationFiles(self.prefiles, self.postfiles)
except SyntaxError:
File "/home/jeffrey/M300/fsl-release-bsp/sources/poky/bitbake/lib/bb/cookerdata.py", line 305, in CookerDataBuilder.parseConfigurationFiles(prefiles=[], postfiles=[]):
if data.getVar("BB_WORKERCONTEXT", False) is None:
> bb.fetch.fetcher_init(data)
bb.codeparser.parser_cache_init(data)
File "/home/jeffrey/M300/fsl-release-bsp/sources/poky/bitbake/lib/bb/fetch2/__init__.py", line 497, in fetcher_init(d=<bb.data_smart.DataSmart object at 0xb486b7ec>):
pass
> revs.clear()
else:
File "/home/jeffrey/M300/fsl-release-bsp/sources/poky/bitbake/lib/bb/persist_data.py", line 147, in SQLTable.clear():
def clear(self):
> self._execute("DELETE FROM %s;" % self.table)
File "/home/jeffrey/M300/fsl-release-bsp/sources/poky/bitbake/lib/bb/persist_data.py", line 66, in SQLTable._execute(*query=('DELETE FROM BB_URI_HEADREVS;',)):
try:
> return self.cursor.execute(*query)
except sqlite3.OperationalError as exc:
OperationalError: attempt to write a readonly database
jeffrey@jeffrey-VirtualBox:~/M300/fsl-release-bsp/build_small$
OperationalError: attempt to write a readonly database
???
問一下 jammy 他的 bitbake linux-imx
會不會出錯
結果他昨晚才做過... 是好的
我想是我前幾天在 window 下作 svn commit 的緣故讓我的 source code 權限有些被改成 root 了
切換成 root bitbake u-boot-imx
出現了不同的錯誤訊息
Summary: There was 1 ERROR message shown, returning a non-zero exit code.
root@jeffrey-VirtualBox:/home/jeffrey/M300/fsl-release-bsp/build_small# bitbake u-boot-imx
ERROR: OE-core's config sanity checker detected a potential misconfiguration.
Either fix the cause of this error or at your own risk disable the checker (see sanity.conf).
Following is the list of potential problems / advisories:
Do not use Bitbake as root.
Summary: There was 1 ERROR message shown, returning a non-zero exit code.
root@jeffrey-VirtualBox:/home/jeffrey/M300/fsl-release-bsp/build_small#
想一下怎麼把相關的 source code 的權限還原為 jeffrey
在 jeffrey@jeffrey-VirtualBox:~/M300/fsl-release-bsp
目錄下
$ sudo chown -R jeffrey:jeffrey sources/
$ sudo chown -R jeffrey:jeffrey proscend/
jeffrey@jeffrey-VirtualBox:~/M300/fsl-release-bsp/build_small$ bitbake -c deploy u-boot-imx
WARNING: Host distribution "Ubuntu-15.10" has not been validated with this version of the build system; you may possibly experience unexpected failures. It is recommended that you use a tested distribution.
Parsing recipes: 39% |################ | ETA: 00:02:45
看來是在跑了
某些權限不是 jeffrey:jeffrey
的 file 造成了 OperationalError: attempt to write a readonly database
1505
follow Freescale Yocto Project User's Guide
- 5.5 U-Boot configuration
修改 M300/fsl-release-bsp/build_small/conf/local.conf
檔案尾部新增一行 - UBOOT_CONFIG = "nand"
build U-Boot image
jeffrey@jeffrey-VirtualBox:~/M300/fsl-release-bsp/build_small$ bitbake u-boot-imx -c compile -vf
...
+ [ xnand != x ]
+ unset i
+ ret=0
+ trap 0
+ exit 0
NOTE: Tasks Summary: Attempted 226 tasks of which 225 didn't need to be rerun and all succeeded.
Summary: There were 2 WARNING messages shown.
jeffrey@jeffrey-VirtualBox:~/M300/fsl-release-bsp/build_small$
修改 M300/fsl-release-bsp/build_small/conf/local.conf
刪掉檔案尾部新增的一行 - UBOOT_CONFIG = "nand"
jeffrey@jeffrey-VirtualBox:~/M300/fsl-release-bsp/build_small$ bitbake u-boot-imx -c compile -vf
...
+ [ xsd != x ]
+
expr
+
1
+ i=1
+
expr
+
1
+ j=1
+ [ 1 -eq 1 ]
+ oe_runmake O=mx6ul_14x14_evk_config mx6ul_14x14_evk_config
+ oe_runmake_call O=mx6ul_14x14_evk_config mx6ul_14x14_evk_config
+ bbnote make -j 4 CROSS_COMPILE=arm-poky-linux-gnueabi- CC=arm-poky-linux-gnueabi-gcc --sysroot=/home/jeffrey/M300/fsl-release-bsp/build_small/tmp/sysroots/imx6ulevk V=1 O=mx6ul_14x14_evk_config mx6ul_14x14_evk_config
+ echo NOTE: make -j 4 CROSS_COMPILE=arm-poky-linux-gnueabi- CC=arm-poky-linux-gnueabi-gcc --sysroot=/home/jeffrey/M300/fsl-release-bsp/build_small/tmp/sysroots/imx6ulevk V=1 O=mx6ul_14x14_evk_config mx6ul_14x14_evk_config
NOTE: make -j 4 CROSS_COMPILE=arm-poky-linux-gnueabi- CC=arm-poky-linux-gnueabi-gcc --sysroot=/home/jeffrey/M300/fsl-release-bsp/build_small/tmp/sysroots/imx6ulevk V=1 O=mx6ul_14x14_evk_config mx6ul_14x14_evk_config
+ make -j 4 CROSS_COMPILE=arm-poky-linux-gnueabi- CC=arm-poky-linux-gnueabi-gcc --sysroot=/home/jeffrey/M300/fsl-release-bsp/build_small/tmp/sysroots/imx6ulevk V=1 O=mx6ul_14x14_evk_config mx6ul_14x14_evk_config
...
充實一下知識
M300\fsl-release-bsp\sources\meta-fsl-arm\conf\machine\imx6ulevk.conf
裏頭有
#@TYPE: Machine
#@NAME: Freescale i.MX6UL Evaluation Kit
#@SOC: i.MX6UL
#@DESCRIPTION: Machine configuration for Freescale i.MX6UL EVK
#@MAINTAINER: Lauren Post <[email protected]>
include conf/machine/include/imx-base.inc
include conf/machine/include/tune-cortexa7.inc
include conf/machine/include/imx6ul-common.inc
KERNEL_DEVICETREE = "imx6ul-14x14-evk.dtb imx6ul-14x14-evk-csi.dtb imx6ul-14x14-evk-btwifi.dtb"
UBOOT_CONFIG ??= "sd"
UBOOT_CONFIG[sd] = "mx6ul_14x14_evk_config,sdcard"
UBOOT_CONFIG[qspi1] = "mx6ul_14x14_evk_qspi1_config"
UBOOT_CONFIG[mfgtool] = "mx6ul_14x14_evk_config"
試著參考 UBOOT_CONFIG 來解釋UBOOT_CONFIG[sd] = "mx6ul_14x14_evk_config,sdcard"
- The "sd" configuration defines "mx6ul_14x14_evk_config" as the value for UBOOT_MACHINE
- while the "sdcard" specifies the IMAGE_FSTYPES to use for the U-boot image
繼續看 UBOOT_MACHINE
Specifies the value passed on the make command line when building a U-Boot image.
The value indicates the target platform configuration. You typically set this variable from the machine configuration file (i.e. conf/machine/machine_name.conf).
所以 mx6ul_14x14_evk_config
這個 value 在 building U-Boot 的時候會傳給它?
看一下 IMAGE_FSTYPES
Specifies the formats the OpenEmbedded build system uses during the build when creating the root filesystem.
For example, setting IMAGE_FSTYPES as follows causes the build system to create root filesystems using two formats: .ext3 and .tar.bz2:
.
IMAGE_FSTYPES = "ext3 tar.bz2"
.
For the complete list of supported image formats from which you can choose, see IMAGE_TYPES.
我們應該看一下有沒有現成的 machine configuration file 有支援 nand
1600
找到這個 machine configuration - M300\fsl-release-bsp\sources\meta-fsl-arm\conf\machine\imx6ul14x14ddr3arm2.conf
#@TYPE: Machine
#@NAME: Freescale i.MX6UL 14x14 DDR3 ARM2 Evaluation Kit
#@SOC: i.MX6UL
#@DESCRIPTION: Machine configuration for Freescale i.MX6UL 14x14 DDR3 ARM2 EVK
#@MAINTAINER: Lauren Post <[email protected]>
include conf/machine/include/imx-base.inc
include conf/machine/include/tune-cortexa7.inc
include conf/machine/include/imx6ul-common.inc
KERNEL_DEVICETREE = "imx6ul-14x14-ddr3-arm2.dtb imx6ul-14x14-ddr3-arm2-adc.dtb imx6ul-14x14-ddr3-arm2-flexcan2.dtb \
imx6ul-14x14-ddr3-arm2-lcdif.dtb imx6ul-14x14-ddr3-arm2-mqs.dtb imx6ul-14x14-ddr3-arm2-spdif.dtb \
imx6ul-14x14-ddr3-arm2-wm8958.dtb imx6ul-14x14-ddr3-arm2-gpmi-weim.dtb imx6ul-14x14-ddr3-arm2-emmc.dtb "
UBOOT_CONFIG ??= "sd"
UBOOT_CONFIG[sd] = "mx6ul_14x14_ddr3_arm2_config,sdcard"
UBOOT_CONFIG[eimnor] = "mx6ul_14x14_ddr3_arm2_eimnor_config"
UBOOT_CONFIG[emmc] = "mx6ul_14x14_ddr3_arm2_emmc_config,sdcard"
UBOOT_CONFIG[nand] = "mx6ul_14x14_ddr3_arm2_nand_config,ubifs"
UBOOT_CONFIG[spinor] = "mx6ul_14x14_ddr3_arm2_spinor_config"
UBOOT_CONFIG[qspi1] = "mx6ul_14x14_ddr3_arm2_qspi1_config"
UBOOT_CONFIG[mfgtool] = "mx6ul_14x14_ddr3_arm2_config"
由 UBOOT_CONFIG[nand] = "mx6ul_14x14_ddr3_arm2_nand_config,ubifs"
得知
- The "nand" configuration defines "mx6ul_14x14_ddr3_arm2_nand_config" as the value for UBOOT_MACHINE
- while the "ubifs" specifies the IMAGE_FSTYPES to use for the U-boot image
1605
回到 machine configuration - conf\machine\imx6ulevk.conf
- The "sd" configuration defines "mx6ul_14x14_evk_config" as the value for UBOOT_MACHINE
查一下 mx6ul_14x14_evk_config
這個值怎麼被利用
自己是用 source insight 在 trace code
找 UBOOT_MACHINE
這個關鍵字的話會看到
M300\fsl-release-bsp\sources\poky\meta\recipes-bsp\u-boot\u-boot-fw-utils_2015.01.bb
...
do_compile () {
oe_runmake ${UBOOT_MACHINE}
oe_runmake env
}
...
M300\fsl-release-bsp\sources\meta-fsl-arm\recipes-bsp\u-boot\u-boot-ls1_2015.01.bb
...
do_compile_append () {
if [ "x${UBOOT_CONFIG}" != "x" ]
then
for config in ${UBOOT_MACHINE}; do
...
done
fi
}
...
M300\fsl-release-bsp\sources\poky\meta\recipes-bsp\u-boot\u-boot.inc
...
do_compile () {
...
if [ "x${UBOOT_CONFIG}" != "x" ]
then
for config in ${UBOOT_MACHINE}; do
...
done
...
else
oe_runmake ${UBOOT_MACHINE}
oe_runmake ${UBOOT_MAKE_TARGET}
fi
}
...
do_install () {
if [ "x${UBOOT_CONFIG}" != "x" ]
then
for config in ${UBOOT_MACHINE}; do
...
done
else
...
fi
...
}
...
do_deploy () {
if [ "x${UBOOT_CONFIG}" != "x" ]
then
for config in ${UBOOT_MACHINE}; do
...
done
...
fi
...
}
...
這 M300\fsl-release-bsp\sources\poky\meta\recipes-bsp\u-boot
目錄下的
u-boot-fw-utils_2015.01.bb
u-boot-ls1_2015.01.bb
u-boot.inc
都跟 UBOOT_MACHINE
扯上關係
1630
先看 u-boot-fw-utils_2015.01.bb
SUMMARY = "U-Boot bootloader fw_printenv/setenv utilities"
LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://Licenses/README;md5=c7383a594871c03da76b3707929d2919"
SECTION = "bootloader"
DEPENDS = "mtd-utils"
# This revision corresponds to the tag "v2015.01"
# We use the revision in order to avoid having to fetch it from the
# repo during parse
SRCREV = "92fa7f53f1f3f03296f8ffb14bdf1baefab83368"
PV = "v2015.01+git${SRCPV}"
SRC_URI = "git://git.denx.de/u-boot.git;branch=master \
file://0001-tools-env-fix-build-error.patch"
S = "${WORKDIR}/git"
INSANE_SKIP_${PN} = "already-stripped"
EXTRA_OEMAKE_class-target = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${CC} ${CFLAGS} ${LDFLAGS}" V=1'
EXTRA_OEMAKE_class-cross = 'ARCH=${TARGET_ARCH} CC="${CC} ${CFLAGS} ${LDFLAGS}" V=1'
inherit uboot-config
do_compile () {
...
}
do_install () {
...
}
do_install_class-cross () {
...
}
SYSROOT_PREPROCESS_FUNCS_class-cross = "uboot_fw_utils_cross"
uboot_fw_utils_cross() {
...
}
PACKAGE_ARCH = "${MACHINE_ARCH}"
BBCLASSEXTEND = "cross"
1630
u-boot-ls1_2015.01.bb
require recipes-bsp/u-boot/u-boot.inc
DESCRIPTION = "U-Boot provided by Freescale with focus on QorIQ Layerscape1 boards"
LICENSE = "GPLv2 & BSD-3-Clause & BSD-2-Clause & LGPL-2.0 & LGPL-2.1"
LIC_FILES_CHKSUM = " \
file://Licenses/gpl-2.0.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
file://Licenses/bsd-2-clause.txt;md5=6a31f076f5773aabd8ff86191ad6fdd5 \
file://Licenses/bsd-3-clause.txt;md5=4a1190eac56a9db675d58ebe86eaf50c \
file://Licenses/lgpl-2.0.txt;md5=5f30f0716dfdd0d91eb439ebec522ec2 \
file://Licenses/lgpl-2.1.txt;md5=4fbd65380cdd255951079008b364516c \
"
SRCBRANCH = "master"
SRC_URI = "git://git.freescale.com/ppc/sdk/u-boot.git;branch=${SRCBRANCH}"
SRCREV = "6ba8eedbcdc4b063f59a63e6288b938af739e8ad"
LOCALVERSION ?= "+ls1"
S = "${WORKDIR}/git"
inherit fsl-u-boot-localversion
DEPENDS += "change-file-endianess-native dtc-native"
PROVIDES += "u-boot"
do_compile_append () {
...
}
PACKAGES += "${PN}-images"
FILES_${PN}-images += "/boot"
ALLOW_EMPTY_${PN} = "1"
PACKAGE_ARCH = "${MACHINE_ARCH}"
COMPATIBLE_MACHINE = "(ls102xa)"
1635
u-boot.inc
SUMMARY = "Universal Boot Loader for embedded devices"
HOMEPAGE = "http://www.denx.de/wiki/U-Boot/WebHome"
SECTION = "bootloaders"
PROVIDES = "virtual/bootloader"
LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://Licenses/README;md5=c7383a594871c03da76b3707929d2919"
SRC_URI = "git://git.denx.de/u-boot.git;branch=master"
S = "${WORKDIR}/git"
PACKAGE_ARCH = "${MACHINE_ARCH}"
inherit uboot-config deploy
EXTRA_OEMAKE = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${TARGET_PREFIX}gcc ${TOOLCHAIN_OPTIONS}" V=1'
# Allow setting an additional version string that will be picked up by the
# u-boot build system and appended to the u-boot version. If the .scmversion
# file already exists it will not be overwritten.
UBOOT_LOCALVERSION ?= ""
# Some versions of u-boot use .bin and others use .img. By default use .bin
# but enable individual recipes to change this value.
UBOOT_SUFFIX ??= "bin"
UBOOT_IMAGE ?= "u-boot-${MACHINE}-${PV}-${PR}.${UBOOT_SUFFIX}"
UBOOT_BINARY ?= "u-boot.${UBOOT_SUFFIX}"
UBOOT_SYMLINK ?= "u-boot-${MACHINE}.${UBOOT_SUFFIX}"
UBOOT_MAKE_TARGET ?= "all"
# Some versions of u-boot build an SPL (Second Program Loader) image that
# should be packaged along with the u-boot binary as well as placed in the
# deploy directory. For those versions they can set the following variables
# to allow packaging the SPL.
SPL_BINARY ?= ""
SPL_IMAGE ?= "${SPL_BINARY}-${MACHINE}-${PV}-${PR}"
SPL_SYMLINK ?= "${SPL_BINARY}-${MACHINE}"
# Additional environment variables or a script can be installed alongside
# u-boot to be used automatically on boot. This file, typically 'uEnv.txt'
# or 'boot.scr', should be packaged along with u-boot as well as placed in the
# deploy directory. Machine configurations needing one of these files should
# include it in the SRC_URI and set the UBOOT_ENV parameter.
UBOOT_ENV_SUFFIX ?= "txt"
UBOOT_ENV ?= ""
UBOOT_ENV_BINARY ?= "${UBOOT_ENV}.${UBOOT_ENV_SUFFIX}"
UBOOT_ENV_IMAGE ?= "${UBOOT_ENV}-${MACHINE}-${PV}-${PR}.${UBOOT_ENV_SUFFIX}"
UBOOT_ENV_SYMLINK ?= "${UBOOT_ENV}-${MACHINE}.${UBOOT_ENV_SUFFIX}"
do_compile () {
...
}
do_install () {
...
}
FILES_${PN} = "/boot ${sysconfdir}"
do_deploy () {
...
}
addtask deploy before do_build after do_compile
1640
感覺 bitbake u-boot-imx -c compile -vf
就會呼叫到 u-boot.inc
裡頭的 do_compile ()
怎麼來做實驗了
讓 u-boot.inc
的 do_compile () echo 個啥就跳出來
先備份一個 u-boot.inc.original
/fsl-release-bsp/sources/poky/meta/recipes-bsp/u-boot$ cp u-boot.inc u-boot.inc.original
來個 hello world
吧
do_compile () {
echo "Hello World"
}
jeffrey@jeffrey-VirtualBox:~/M300/fsl-release-bsp/build_small$ bitbake u-boot-imx -c compile -vf
...
+
do_compile
+
[
y
=
y
]
+
git
rev-parse
--verify
--short
HEAD
+ head=6cf684a
+ printf %s%s%s -imx_v2015.04_3.14.52_1.1.0_ga +g 6cf684a
+ printf %s%s%s -imx_v2015.04_3.14.52_1.1.0_ga +g 6cf684a
+ echo Hello World
Hello World
+ ret=0
+ trap 0
+ exit 0
NOTE: Tasks Summary: Attempted 226 tasks of which 225 didn't need to be rerun and all succeeded.
Summary: There were 2 WARNING messages shown.
jeffrey@jeffrey-VirtualBox:~/M300/fsl-release-bsp/build_small$
哈哈... 看到 Hello World 了
1835
拿了昨天在 振宇五金 買的警報器和中午寫的 code 去隔壁庫房作測試
morris 和 charlie 都看得超開心的
感覺 charlie 越來越有信心了