Nexus 7 Cyanogenmod OS Compile and errors

Nexus 7 Hardware information

The Nexus 7 comes with several types, genaration I and II,  sales in 2012 and 2013. The Gen1 and Gen2 have different Processor, one is the NVIDIA Tegra, another with QCT APQ8064.  These two type of devices, have different name: flo and grouper. And these 2
type tablet have different lunch target in Android/Cyanogenmod OS.

And I got a flo device[Nexus 7 (2013 Wifi)  flo Asus], which have 2GB RAM and 16GB storage flash.

Build Procedure

Follow the instructions in the Cyanogenmod wiki page: Flo build

Requirement Before Build

If you have walk through the Flo_build guide, you‘ll notice that one step is run the shell script named "extract-files.sh" in section "Extract proprietary blobs", this step would got the proprietary files from the device running Cyanogenmod OS CM-12.1(same
version/branch with the code we want to build/checkout, this can got from the repo init inistruction) , using the adb pull.

So you‘d better download the prebuilt Cyanogenmod OS 12.1, then flash it into the Nexus 7 device.

The prebuilt iamges can be found at page: https://download.cyanogenmod.org/?device=flo

For the branch cm-12.1, that we would repo sync, using the below one :

flo snapshot Downloadcm-12.1-20151117-SNAPSHOT-YOG7DAO1K9-flo.zip (246.15 MB)

sha1: 6e016816289b350f5250aa6d317cf4a74a57e4b8

Downloadcm-12.1-20151117-SNAPSHOT-YOG7DAO1K9-flo-recovery.img

sha1: e75f9142caccea5e23f05c3a2af53294c77c4afe

2015-11-17 09:43:12

Errors or Problems I meet

Follow the build guide, I got several errors/questions:

  1. repo failed
  2. repo --force-sync option is not found
  3. isSelfManaged method is not implement in class SunlightEnhancement

1. repo failed

This comes with the Nation Firewall, so just get the ‘repo‘  from other sites

2. repo --force-sync

We can change the python file to avoid it, the file location is:

build/tools/roomservice.py

Just delete the options, the program would work OK without it.

And the --force-sync option got from the file:

vendor/cm/bash_completion/repo.bash

3. method is not implement

The compile error is like below:

vendor/cmsdk/cm/lib/main/java/org/cyanogenmod/platform/internal/CMHardwareService.java:310: error: cannot find symbol
            return SunlightEnhancement.isSelfManaged();
                                      ^
  symbol:   method isSelfManaged()
  location: class SunlightEnhancement
Note: vendor/cmsdk/src/java/cyanogenmod/profiles/ConnectionSettings.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
1 error

We can manual add the function implement at file system/frameworks/opt/hardware/src/org/cyanogenmod/hardware/SunlightEnhancement.java (or search the filename to find it), then add the implement of method at Line58:

    public static boolean isAdaptiveBacklightRequired() { return true; }
    public static boolean isSelfManaged() { return false; }

Some tips

root problem

There‘s an option in cyanogenmod OS, controlling the root permisions, you can change the setting in Development option(Root access):

Other OS can be root with NRK(Nexus RootKit)

The NRK have the windows installer and linux/Mac shell script. Just flow the intructions to root or backup.

Transfer the zip file through adb sideload

If you wipe all the data and system, you can use this method to burn the OS(for you don‘t have an OS anymore). After select the item(Upate--> From adb), you would check the adb status in PC terminal:

adb devices
adb server is out of date.  killing...
* daemon started successfully *
List of devices attached
08fee72f	sideload

Then use the adb sideload commands to transfer the zip file:

$adb sideload out/target/product/flo/cm-12.1-20160321-UNOFFICIAL-flo.zip
serving: ‘out/target/product/flo/cm-12.1-20160321-UNOFFICIAL-flo.zip‘  244mb 1.00x total xfer:  244mb 1.00x

After transfered, reboot the device.

Wipe data, Format the partition using the Cyanomontion Recovery

You may wonder where is the wipe item option in Recovery menu, instead, select the Factory reset item in screen menu. Or using fastboot commands is a quick method

Reference

Install CM for Nexus

Flo device Wiki

Flo device CM OS/Recovery image download page

Build CM12.1 from Source! [NOW-CAT&GRANDMA-FRIENDLY]

How to install a ROM through adb sideload

Nexus 7 serial UART

时间: 2024-10-11 03:24:26

Nexus 7 Cyanogenmod OS Compile and errors的相关文章

os包方法

os包中实现了平台无关的接口,设计向Unix风格,但是错误处理是go风格,当os包使用时,如果失败之后返回错误类型而不是错误数量. os包中函数设计方式和Unix类似,下面来看一下. func Chdir(dir string) error   //chdir将当前工作目录更改为dir目录. func Getwd() (dir string, err error)    //获取当前目录,类似linux中的pwd func Chmod(name string, mode FileMode) er

[Oracle系列整理04] oracle pl/sql 基础

PL/SQL块中只能直接嵌入SELECT,DML(INSERT,UPDATE,DELETE)以及事务控制语句 (COMMIT,ROLLBACK,SAVEPOINT),而不能直接嵌入DDL语句(CREATE,ALTER,DROP)和DCL语句 (GRANT,REVOKE) 1.检索单行数据    1.1使用标量变量接受数据  v_ename emp.ename%type;  v_sal   emp.sal%type;  select ename,sal into v_ename,v_sal fro

PL/SQL详细介绍,设置oracle相关

1. 实现参照完整性      指若两个表之间具有主从关系(即主外键关系),当删除主表数据时,必须确保相关的从表数据已经被删除.  当修改主表的主键列数据时,必须确保相关从表数据已经被修改.为了实现级联删除,可在定义外部键约束时指定ON DELETE CASCADE关键字  alter table emp add constraint fk_deptno foreign key (deptno) references dept(deptno) on delete cascade; 实现级联更新,

[转]50 Shades of Go: Traps, Gotchas, and Common Mistakes for New Golang Devs

http://devs.cloudimmunity.com/gotchas-and-common-mistakes-in-go-golang/ 50 Shades of Go: Traps, Gotchas, and Common Mistakes for New Golang Devs Go is a simple and fun language, but, like any other language, it has a few gotchas... Many of those gotc

Safe TinyOS

Efficient Memory Safety for TinyOS: http://www.cs.utah.edu/~coop/me/pubs/sensys07.htm Safe TinyOS 原文:http://tinyos.stanford.edu/tinyos-wiki/index.php/Safe_TinyOS Contents [hide] 1 What is Safe TinyOS? 2 Supported Platforms 3 Building a Safe Applicati

OpenGL学习--开发环境

1. VS2017 Professional安装 1.1. 下载 mu_visual_studio_professional_2017_x86_x64_10049787.exe 1.2. 双击开始安装 双击mu_visual_studio_professional_2017_x86_x64_10049787.exe开始安装 安装完成后重启计算机 1.3. 启动 点击菜单中的[Visual Studio 2017]启动 1.4. 注册 输入以下序列号 Visual Studio 2017 Key企

模块整理笔记

1.模块定义 用来从逻辑上组织python代码(变量,函数,类,逻辑:实现一个功能),本质上就是.py结尾python文件 分类:内置模块.开源模块.自定义模块 2.导入模块 本质:导入模块的本质就是把python文件解释一遍:导入包的本质就是把包文件下面的init.py文件运行一遍 ① 同目录下模块的导入 #同级目录间import import module_name #直接导入模块 import module_name,module2_name #导入多个模块 使用:模块名.加函数名 fro

IMP-00041: Warning: object created with compilation warnings

IMP-00041: Warning: object created with compilation warnings 昨天导入数据的时候,最后报错 IMP-00041: Warning: object created with compilation warnings  "CREATE TRIGGER "KFPT2".SYN_khgl_qyjbxx_D after delete on khgl_qyjbxx  for e"  "ach row decl

【转】 cve-2013-2094 perf_event_open 漏洞分析

cve-2013-2094是于2013年4月前后发现的linux kernel本地漏洞,该漏洞影响3.8.9之前开启了PERF_EVENT的linux系统.利用该漏洞,通过perf_event_open系统调用,本地用户可以获得系统的最高权限. 发生漏洞的是linux kernel中的perf event子系统,perf event是linux系统中提供性能分析接口的子系统,于2.6.31之后引入linux,之前被称为 Performance Counters for Linux (PCL).通