【iMX6q-Android6.0】---移植 iMX6q android6.0 源码 史上最详细

在这里插入图片描述

  • 在编程的艺术世界里,代码和灵感需要寻找到最佳的交融点,才能打造出令人为之惊叹的作品。
  • 而在这座秋知叶i博客的殿堂里,我们将共同追寻这种完美结合,为未来的世界留下属于我们的独特印记。

一、开发环境

  • 开发环境:Ubuntu16
  • 开发平台:iMX6q Android6.0
  • 安卓版本:android-6.0.1_r22
  • 补丁版本:android_M6.0.1_2.1.0_source.tar.gz

二、准备工作

1、下载 android6.0源码

官方验证移植的是 android-6.0.1_r22 所以我们下载 android-6.0.1_r22

下载AOSP源码

三、移植kernel

1、进入 android6.0 源码根目录

cd ~/imx6q-android6.0

2、下载 kernel 源码

git clone https://source.codeaurora.org/external/imx/linux-imx kernel_imx

3、进入 kernel_imx

cd kernel_imx

4、切换 kernel 分支

git checkout m6.0.1_2.1.0-ga

切换分支会提示,不用理会即可!!!
切换分支会提示,不用理会即可!!!
切换分支会提示,不用理会即可!!!

Checking out files: 100% (50469/50469), done.
Note: checking out 'm6.0.1_2.1.0-ga'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

HEAD is now at 9f38c97... MLK-12946 media: pxp-v4l2: correct the 32 bpp pixel format passed to pxp

5、确认 kernel

最后一个节点应该是

commit 9f38c97e49235662dc45caa3213b0debea45d87b
Author: Fancy Fang <chen.fang@nxp.com>
Date:   Tue Jun 28 17:18:17 2016 +0800

    MLK-12946 media: pxp-v4l2: correct the 32 bpp pixel format passed to pxp

    The 32 bpp pixel format which is passed to pxp should be
    'PXP_PIX_FMT_RGB32' instead of 'PXP_PIX_FMT_RGB24', since
    only 'PXP_PIX_FMT_RGB32' can be recognized by lcdif.

    Signed-off-by: Fancy Fang <chen.fang@nxp.com>
    (cherry picked from commit c98efc59e1bc6d1814b2179f1b7e9f22cb177f47)

四、移植 u-boot

1、进入 bootable 目录

cd bootable

2、创建 bootloader

mkdir bootloader

3、进入 bootloader

cd bootloader

4、下载 u-boot 源码

git clone https://source.codeaurora.org/external/imx/uboot-imx uboot-imx

5、进入 uboot-imx

cd uboot-imx

6、切换 u-boot分支

git checkout m6.0.1_2.1.0-ga

切换分支会提示,不用理会即可!!!
切换分支会提示,不用理会即可!!!
切换分支会提示,不用理会即可!!!

Note: checking out 'm6.0.1_2.1.0-ga'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

HEAD is now at 6581aea... MLK-12884 mx7dsabresd: Fix LCD_PWR_EN output setting

7、确认 u-boot

最后一个节点应该是

commit 6581aea78198bf78c9ceb3308b96d87c9d8f61bb
Author: Ye Li <ye.li@nxp.com>
Date:   Mon Jun 6 11:41:30 2016 +0800

    MLK-12884 mx7dsabresd: Fix LCD_PWR_EN output setting

    LCD_PWR_EN controls the G pin of Q13 PMOS which needs low voltage to connect
    D to S for outputting LCD 3.3V. If LCD_PWR_EN is high, we measured the LCD 3v3
    is actually 1.2V.

    Signed-off-by: Ye Li <ye.li@nxp.com>
    (cherry picked from commit 28eb616b6c49de492cc0cdb3ad5b618bed77960f)

五、移植 iMX官方 补丁

1、下载 iMX官方 补丁

android_M6.0.1_2.1.0_source.tar.gz

NXP软件文档官网

2、准备补丁

将下载的 android_M6.0.1_2.1.0_source.tar.gz 拷贝到 和 android6.0源码同一个目录 然后解压

再进入 android6.0 源码根目录

3、打上补丁

source ../android_M6.0.1_2.1.0_source/code/M6.0.1_2.1.0/and_patch.sh
c_patch ../android_M6.0.1_2.1.0_source/code/M6.0.1_2.1.0/ imx_M6.0.1_2.1.0

六、成功打上补丁

Applying patch to frameworks/opt/telephony
*************************************************************
Success: Now you can build android code for FSL i.MX platform
*************************************************************
  • 3
    点赞
  • 8
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 3
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 3
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

秋知叶i

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值