Jump to content


Photo

Building CM7 for the ZTE Tureis

- - - - -

  • Please log in to reply
27 replies to this topic

#1
hecatae

hecatae

    Hardcore

  • Moderator Team
  • PipPipPipPipPipPip
  • 3,195 posts
  • Gender:Male
  • Location:northampton
  • Devices:Samsung i9305
  • Twitter:@meritez
Make sure you have:
Ubuntu 12.04 (Precise Pangolin) 64-bit
Your computer has at least 4GB RAM
Good Internet connection
install dependencies:
$ sudo apt-get install git-core gnupg flex bison gperf build-essential \
  zip curl zlib1g-dev zlib1g-dev:i386 libc6-dev lib32ncurses5-dev \
  ia32-libs x11proto-core-dev libx11-dev:i386 libreadline6-dev:i386 \
  lib32z-dev libgl1-mesa-glx:i386 libgl1-mesa-dev g++-multilib mingw32 \
  tofrodos python-markdown libxml2-utils xsltproc readline-common \
  libreadline6-dev libreadline6 lib32readline-gplv2-dev libncurses5-dev \
  lib32readline5 lib32readline6 libreadline-dev libreadline6-dev:i386 \
  libreadline6:i386 bzip2 libbz2-dev libbz2-1.0 libghc-bzlib-dev lib32bz2-dev \
  libsdl1.2-dev libesd0-dev squashfs-tools pngcrush schedtool libwxgtk2.6-dev
$ sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so

Configure USB:

$ gksudo gedit /etc/udev/rules.d/51-android.rules
add this to the above:

#Garmin-Asus
SUBSYSTEM==usb", ATTR{idVendor}==091E", MODE=0666"

#Google
SUBSYSTEM==usb", ATTR{idVendor}==18d1", MODE=0666"

#HTC
SUBSYSTEM==usb", ATTR{idVendor}==0bb4", MODE=0666"

#Huawei
SUBSYSTEM==usb", ATTR{idVendor}==12d1", MODE=0666"

#K-Touch
SUBSYSTEM==usb", ATTR{idVendor}==24e3", MODE=0666"

#KT Tech
SUBSYSTEM==usb", ATTR{idVendor}==2116", MODE=0666"

#Kyocera
SUBSYSTEM==usb", ATTR{idVendor}==0482", MODE=0666"

#Lenovo
SUBSYSTEM==usb", ATTR{idVendor}==17EF", MODE=0666"

#LG
SUBSYSTEM==usb", ATTR{idVendor}==1004", MODE=0666"

#Motorola
SUBSYSTEM==usb", ATTR{idVendor}==22b8", MODE=0666"

#NEC
SUBSYSTEM==usb", ATTR{idVendor}==0409", MODE=0666"

#Nook
SUBSYSTEM==usb", ATTR{idVendor}==2080", MODE=0666"

#Nvidia
SUBSYSTEM==usb", ATTR{idVendor}==0955", MODE=0666"

#OTGV
SUBSYSTEM==usb", ATTR{idVendor}==2257", MODE=0666"

#Pantech
SUBSYSTEM==usb", ATTR{idVendor}==10A9", MODE=0666"

#Philips
SUBSYSTEM==usb", ATTR{idVendor}==0471", MODE=0666"

#PMC-Sierra
SUBSYSTEM==usb", ATTR{idVendor}==04da", MODE=0666"

#Qualcomm
SUBSYSTEM==usb", ATTR{idVendor}==05c6", MODE=0666"

#SK Telesys
SUBSYSTEM==usb", ATTR{idVendor}==1f53", MODE=0666"

#Samsung
SUBSYSTEM==usb", ATTR{idVendor}==04e8", MODE=0666"

#Sharp
SUBSYSTEM==usb", ATTR{idVendor}==04dd", MODE=0666"

#Sony Ericsson
SUBSYSTEM==usb", ATTR{idVendor}==0fce", MODE=0666"

#Toshiba
SUBSYSTEM==usb", ATTR{idVendor}==0930", MODE=0666"

#ZTE
SUBSYSTEM==usb", ATTR{idVendor}==19D2", MODE=0666"


Set proper permissions:
$ sudo chmod a+r /etc/udev/rules.d/51-android.rules

JAVA JDK Installation:
http://www.oracle.co...ds-1637591.html

$ sudo apt-get purge openjdk-\* icedtea-\* icedtea6-\*

install Java JDK:

$ sudo mkdir -p /opt/java/64/
$ sudo cp jdk-6u34-linux-x64.bin /opt/java/64
$ sudo su -
$ cd /opt/java/64
$ chmod +x jdk-6u34-linux-x64.bin
$ ./jdk-6u34-linux-x64.bin
$ exit

Add JDK PATH to .bashrc:

$ gksudo gedit ~/.bashrc

Add these lines:

# Java PATHs
export JAVA_HOME=/opt/java/64/jdk1.6.0_34
export PATH=$PATH:$JAVA_HOME/bin

Android SDK:

Download the SDK here:

http://developer.and.../sdk/index.html

Extract the SDK and place it in your home directory.

Add AndroidSDK PATH to .bashrc:

$ gksudo gedit .bashrc

Add the following lines:

# Android tools
export PATH=${PATH}:~/android-sdk/tools
export PATH=${PATH}:~/android-sdk/platform-tools
export PATH=${PATH}:~/bin

Add PATH to .profile:
$ gksudo gedit .profile

Add these lines:
PATH=$HOME/android-sdk/tools:$HOME/android-sdk/platform-tools:$PATH"

To use the ADB Update software (or to verify a working adb path), use the following command:

$ android

Install the Repo:

$ mkdir ~/bin
$ PATH=~/bin:$PATH
$ curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo ] ~/bin/repo
$ chmod a+x ~/bin/repo

Initialize the CyanogenMOD 7 Repo:

$ mkdir android
$ cd android
$ mkdir system
$ cd system
$ repo init -u git://github.com/CyanogenMod/android.git -b gingerbread

Finally:

$ repo sync -j16

borrowed and adapted from Compile ParanoidAndroid

  • 0

#2
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts
Whats missing is a working device config for the ZTE Tureis.

I was able to build CM7 with my own device config I adapted from the Blade, but its stuck in a bootloop when I flash the boot.img and system.img with CWM.

My config is here:

https://github.com/s...e_device_tureis

Edited by schmatzler, 23 February 2013 - 01:09 AM.

  • 0

#3
hecatae

hecatae

    Hardcore

  • Moderator Team
  • PipPipPipPipPipPip
  • 3,195 posts
  • Gender:Male
  • Location:northampton
  • Devices:Samsung i9305
  • Twitter:@meritez
Have you changed the kernel to 3g vm split?

  • 0

#4
Sakif X9

Sakif X9

    Newbie

  • Members
  • Pip
  • 37 posts
  • Gender:Male
  • Devices:ZTE-Tureis, PendoPad4.0
  • Twitter:@SakifX9
I am waiting for a flashable zip

  • 0

#5
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts

Have you changed the kernel to 3g vm split?


No I haven't. I just used the original kernel source, patched some governors in and added the zImage to my device config.

The zImage is working, when I create a boot.img with repack_bootimg.pl, the stock Android is working with that.

However, the boot.img created by CM7 does not boot the stock Gingerbread nor CM7 - I think something is still wrong with creating the files.

I don't even know why I should need the 3G slit - the Tureis just has 512MB of storage as far as I know.

  • 0

#6
hecatae

hecatae

    Hardcore

  • Moderator Team
  • PipPipPipPipPipPip
  • 3,195 posts
  • Gender:Male
  • Location:northampton
  • Devices:Samsung i9305
  • Twitter:@meritez

No I haven't. I just used the original kernel source, patched some governors in and added the zImage to my device config.

The zImage is working, when I create a boot.img with repack_bootimg.pl, the stock Android is working with that.

However, the boot.img created by CM7 does not boot the stock Gingerbread nor CM7 - I think something is still wrong with creating the files.

I don't even know why I should need the 3G slit - the Tureis just has 512MB of storage as far as I know.


cyanogenmod uses 3g vmsplit as default, if you are using zte stock 2g vmsplit then you will bootloop

  • 0

#7
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts
Thanks! You are the pro! :D

Will recompile tomorrow evening and test if it works :)

  • 0

#8
Sakif X9

Sakif X9

    Newbie

  • Members
  • Pip
  • 37 posts
  • Gender:Male
  • Devices:ZTE-Tureis, PendoPad4.0
  • Twitter:@SakifX9
Can't wait till CM10, I made a rom that'll keep everyone busy till CM9 and 10 come out

  • 0

#9
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts
When I recompile the kernel CM7 boots! :)

At least I see the Android bootscreen.

I will investigate further this evening - still a long way to go to get everything running.

  • 0

#10
hecatae

hecatae

    Hardcore

  • Moderator Team
  • PipPipPipPipPipPip
  • 3,195 posts
  • Gender:Male
  • Location:northampton
  • Devices:Samsung i9305
  • Twitter:@meritez

When I recompile the kernel CM7 boots! :)

At least I see the Android bootscreen.

I will investigate further this evening - still a long way to go to get everything running.


post it up if you want to adb logcat for you, or private message me test releases if you want

  • 0

#11
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts
Got to the homescreen now after a complete recompile.

Problem is: The symbols are waaaay to big.

Attached File  SNC00056.jpg   105.01KB   5 downloads

And WiFi is not working. Haven't integrated Bluetooth yet, so that too. And the camera. And 2G/3G

But hey - audio works, touch works. That's a start.

I will release something when I need big help or when it's useable. Stay tuned. :)

Edited by schmatzler, 26 February 2013 - 10:09 PM.

  • 0

#12
Sakif X9

Sakif X9

    Newbie

  • Members
  • Pip
  • 37 posts
  • Gender:Male
  • Devices:ZTE-Tureis, PendoPad4.0
  • Twitter:@SakifX9
GREAT WORK MAN!

  • 0

#13
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts
No I'm not dead. Still working on this but I have a full-time job that consumes a lot of time.

I already got Wi-Fi working now and fixed the issue with the oversized icons. At the moment I'm working on getting the libril related stuff running (2G/3G). But when I compile in the libril something happens with the screen, it's only showing a blank picture. The device still responds to touch and with audio effects, but I can't see anything.

I don't know why this could possibly happen but as soon as I got that running, I will post something.

Edited by schmatzler, 04 March 2013 - 12:29 PM.

  • 0

#14
Sakif X9

Sakif X9

    Newbie

  • Members
  • Pip
  • 37 posts
  • Gender:Male
  • Devices:ZTE-Tureis, PendoPad4.0
  • Twitter:@SakifX9
Send me your build.prop I might be able to fix it

  • 0

#15
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts
Got it! The RIL stuff is working now so I finally get some network into this thing.

I also got adb and USB support fully running so debugging is easier now.

But somehow all of the changes I made broke Wifi and BT again so I still have to work on that. And the proximity sensor.

3D acceleration and audio are working too.

Give me some more time and I will release it.

In the meantime - enjoy the pictures :)

Attached File  SNC00058.jpg   122.77KB   9 downloadsAttached File  SNC00059.jpg   119.47KB   6 downloadsAttached File  SNC00060.jpg   63.73KB   6 downloadsAttached File  SNC00061.jpg   80.47KB   6 downloadsAttached File  SNC00063.jpg   63.49KB   7 downloads

  • 0

#16
Sakif X9

Sakif X9

    Newbie

  • Members
  • Pip
  • 37 posts
  • Gender:Male
  • Devices:ZTE-Tureis, PendoPad4.0
  • Twitter:@SakifX9
I'm going to download it only for the kernel

  • 0

#17
mikeioannina

mikeioannina

    Regular

  • Members
  • PipPip
  • 147 posts
  • Gender:Male
  • Location:Ioannina, Greece
  • Devices:ZTE Carl
Nice work, if you need anything, I'm willing to help. I build cm7 for 3 other zte devices. Which kernel sources are you using?

Edited by mikeioannina, 21 March 2013 - 08:03 AM.

  • 0

If you like my work, don't forget to press the vote up button!
Current phones:
SE Xperia x10 mini - MiniCM10 & nAa-jb kernel
Using custom built roms by me:
SE Xperia mini - CyanogenMod 10 & FXP kernel

ZTE Carl - CyanogenMod 7 & 2.6.35.7 kernel


#18
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts
Thanks. I use the original kernel source with some little changes. The code is here: https://github.com/s...ureis-optimized

At the moment I'm facing some problems with the Wi-Fi. I specified bcm4319 as the driver in BoardConfig.mk and built wpa_supplicant 5.

It works, activates the Wi-Fi but only finds 2 networks. Looks like it gets some networks and as soon as it reaches a network with a hidden SSID it stops scanning.

When I build wpa_supplicant 6, I get the following errors in terminal:

E/WifiHW  (  260): Unable to open connection to supplicant on "/data/system/wpa_supplicant/wlan0": No such file or directory

I will try to make some changes to init.rc to get supplicant 6 working.

  • 0

#19
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts
Strange. Somehow the bcm4319 wifi driver creates an eth0 device instead of a wlan0 device. Have you got an idea why this happens?

I changed any reference from wlan0 to eth0 in the initfiles and I am rebuilding now. Lets see if it runs.

  • 0

#20
schmatzler

schmatzler

    Regular

  • Members
  • PipPip
  • 59 posts
Wifi is running again. Changed the dhcp.wlan0 service to dhcp.eth0 and all other references too. But bluetooth never powers up. It fires up bcm_power and that's it.

I will check that later, because I have no clue how this could happen. Config indicates that it's a BCM2070 chip and its working with the original ROM and my custom kernel so the driver is in the kernel.

Now I will concentrate on the compass, the proximity sensor and the LED which is still not working. Wish me luck :)

  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users