ROMs y desarrollo Jiayu G3S /G3S Turbo ROMs y desarrollo Jiayu G3S /G3S Turbo

Respuesta
 
Herramientas
  #1  
Viejo 22/10/13, 20:11:54
Array

[xs_avatar]
Josean94 Josean94 no está en línea
Official support TF | Dev
· Votos compra/venta: (2)
 
Fecha de registro: sep 2012
Localización: Perdido..
Mensajes: 1,204
Modelo de smartphone: Xiaomi Mi8SE
Tu operador: Lowi
Post ¡Animate! Prueba a compiar tu propio kernel para MTK6589/T (ORIENTACIÓN)

ANTES DE PONERTE HACER EL ''CHORRA'' DEBES SABER QUE EL MOVIL PUEDE QUEDAR INSERVIBLE SI NO LO HACES DE MANERA CORRECTA, POR ESO MUCHO CUIDADO

Hola compis.. como sabreis y si no os lo digo por la red casi que no hay tutoriales para poder hacer tu propio kernel.. aqui os dejo unos links y demas para que os animeis! yo en cuando me descargue el linux 12 me pongo aver si con suerte dejo mi movil de pisapapeles

Link del tutorial de como compilarlo: http://forum.xda-developers.com/show....php?t=1748297 ( por si un caso copio y pego no sea que lo borren en XDA, ya que no tienen licencia GLP)
Link de los drivers de nuestro telefono: PERDON X') LOS DRIVERS NO SON ESTOS..
Link del kernel totalmente completo MTK6589/T(sacado del iOcean, hay debate si con cambiarle los drivers nada mas funcionara, lo dejo a vuestro criterio) :https://github.com/twnksinr/android_...ocean_mtk6589t


Step 1. Build Environment
 Cita:
A. Install Ubuntu 12.04(Not holding your hand here, if you can't do this you shouldn't be messing with kernels)
B. Required packages: git-core, gnupg, flex, bison, gperf, libsdl-dev, libesd0-dev, libwxgtk2.6-dev, build-essential, zip, curl, libncurses5-dev, zlib1g-dev, ia32-libs, lib32z1-dev, lib32ncurses5-dev, gcc-multilib, g++-multilib, and Adb.
C. Open a terminal
D. Type "mkdir android"
E. Type "cd android"
G.Type "mkdir kernel"

The above steps explained:
A. Installing a linux distro. You could really install any Linux distro(Arch = epicness :P) however Ubuntu in my eyes is the easy to use and install, and widely supported.
B. Installing needed packages. I believe are these are needed(I'm sure someone will correct if they aren't), these are just the one's I was told I needed the first time I built CyanogenMod. No I can't tell you what every single package does, it is your job to research and figure that out.
C. Ummm...duh?
D-G. Building a directory structure that will help keep us organized. The "mkdir" command creates a directory, and the "cd" command moves you into that directory. You could also combine these steps using the command "mkdir -p android/kernel", however I left it broken apart up there to enforce the typing bit of this. The more you type these commands the more familiar you will become with them.
Step 2. Your Source
 Cita:
A. Open your Terminal Prompt
B. Type "cd android/kernel"
C. Type "git clone git://github.com/DooMLoRD/android_prebuilt_toolchains.git toolchains"
D. Now comes the tricky part, you need to have some-type of source for your kernel. Check the following two sites for your device as appropriate. Once you have it download it is extracted/cloned into a folder in your kernel directory.

http://www.htcdev.com
http://opensource.samsung.com
http://developer.sonymobile.com/wpor...ads/opensource
http://www.lg.com/global/support/ope...opensource.jsp

The above steps explained: Ok all we are doing here is grabbing some tool chains and the kernel source.
A. Ok...you got this one!
B. Moving into our working directory
C. Grabbing DooMLoRD's very handy pre-built toolchains. What is a toolchain? Check this out http://en.wikipedia.org/wiki/GNU_toolchain. These toolchains are unstable, and as such they aren't completely endorsed yet. They are the versions I use though, and if you would like to use the stable version(4.5.3 as of 07/06/12) you can find links with Google.
D. I typically put my kernel in a directory like "~/android/kernel/<devicename>_<androidversion>_kernel" but that's just me.
Step 3. Modifications
 Cita:
This is the part people are curious about, they want to make modifications to the kernel to make it "special". Start all these from the root directory of your kernel source.

 Cita:
Mod 1. Applying a patch
A. Download the patch you wish to apply, in this case this one should work.
B. Save that file as "kernelPatch" in your kernel directory.
C. Open a Terminal
D. Move into the root directory of the kernel you wish to patch.
E. Type "patch -p1 < ../kernelPatch"

The above steps explained:
A. Pretty simple, I mean we need a patch. The patch itself is quite simply a diff between the original kernel source tree and the source tree containing the changes. I'll post a quick tutorial on how to create a patch in the third post. The patch above contains multiple governors to be added to your kernel.
B. Self-explanatory
C. Self-explanatory
D. Self-explanatory
E. Basically we run the patch command on our source using the patch we downloaded previously. The "patch" portion is the binary itself, the "-p1" option allows you to control the number of forward slashes to remove from file paths(You'll need to look at this option more if you are using weird directory structures or applying the patches from a odd location). The "<" operator directs the content of our "../kernelPatch" file into the command.
 Cita:
Mod 2. Adding a Governor Alone
A. Open "drivers/cpufreq/Kconfig"
B. Add the following lines in appropriate spot amongst the other govenor's

Code:
config CPU_FREQ_DEFAULT_GOV_SMARTASS bool "smartass" select CPU_FREQ_GOV_SMARTASS select CPU_FREQ_GOV_PERFORMANCE help Use the CPUFreq governor 'smartass' as default.
Code:
config CPU_FREQ_GOV_SMARTASS tristate "'smartass' cpufreq governor" depends on CPU_FREQ help smartass' - a "smart" optimized governor! If in doubt, say N.
C. Open "drivers/cpufreq/Makefile"
D. Add the following line in the appropriate spot.
Code:
obj-$(CONFIG_CPU_FREQ_GOV_SMARTASS) += cpufreq_smartass.o
E. Create a file called "drivers/cpufreq/cpufreq_smartass.c"
F. Put the following code in that file.
http://pastebin.com/f0Bk9kVZ
G. open "include/linux/cpufreq.h"
H. Under the "Cpufreq Default" section add
Code:
#elif defined(CONFIG_CPU_FREQ_DEFAULT_GOV_SMARTASS) extern struct cpufreq_governor cpufreq_gov_smartass; #define CPUFREQ_DEFAULT_GOVERNOR (&cpufreq_gov_smartass)
Ok there is a governor added, do the exact same steps for any other one's you would like to add.

The above steps explained:
A. Just opening a file, you guys have this. The Kconfig ties into our "make menuconfig" command later, making our mod a selectable option.
B. Adding the appropriate code for our governor to get it in our .config file. The first chunk would allow us to set our governor as the default one for our kernel, the other allows us to totally remove or add it to the build as we wish.
C-D. This step tells the linker to tie our module in with the rest of the code.
E-F. Creating the actually governor itself, don't skip this step. I would suggest reading through this and trying to understand how it works, it's some pretty awesome stuff.
G-H. Open a file and add the code needed to tie our module into the rest of the source. Without this we would not be able to compile due to the rest of the source not knowing our module exists.
Step 4. Getting a Config file

 Cita:
Option A. Pulling a config file from a kernel.
A. Hook up a device that is using a kernel similar to one you are using as your base.
B. Open a terminal
C. Change to your root kernel directory
D. Type "adb pull /proc/config.gz"
E. Type "gunzip config.gz"
F. Type "mv config arch/arm/configs/<your_config_name>_defconfig"

The above steps explained:
A. This will allow us to pull a base configuration file from a known working kernel. It makes it a lot easier to start out and let's us take baby steps through the whole process. As a note though not all kernel's support this, so you may have to try a few different one's to get it working. If that doesn't work, see option B.
B. Hehe, you are getting good at this step
C. Navigate to the uppermost directory of your kernel source.
D. Use adb to pull a copy of a working config file to use as your source.
E. Unzipping the config file.
F. Moving the configuration file you pulled to the config directory so we can reference it later.
 Cita:
Option B. Using the manufacturers config.
Unfortunately as stated above, not all kernels support the "/proc/config.gz" method. You can typically find a manufacturer's configuration file in "arch/arm/configs". I believe the one for my HTC Flyer was called "flyer_hc_defconfig", so look for a layout similar to that one. Also read the README to get a better idea of how to modify it. I would personally make a copy of it called "<your_config_name>_defconfig" and use that as my base.
Step 5. Building

 Cita:
Time to start the real "build" section of this tutorial.
Part A. Pre-build Steps
A. Open terminal and change to the root of your kernel directory
B. Type "export ARCH=arm"
C. Type "export CROSS_COMPILE=~/android/kernel/toolchains/arm-eabi-linaro-4.6.2/bin/arm-eabi-"

Part B. The First Build
A. Type "make <your_config_name>_defconfig"
B. Type "make menuconfig" and make the required changes to use any modules you added or similar changes.
C. Type "make -j<maximum number of jobs>"

Part C. Re-Builds
A. Type "make clean"
B. Type "make oldconfig"
C. Type "make -j<maximum number of jobs>"

Part D. Building Modules
You have two options:
A. Type "make modules"
B. Type "make path/to/your/module.ko"
The above steps explained:
 Cita:
Part A.(These steps are required every time you close your terminal and re-open it to build again.)
A. Ok shouldn’t need to explain this.
B. This command sets your target architecture.
C. Defines the path to the toolchain we are going to use to compile our kernel. You can change this to point towards whatever toolchain you have downloaded or feel like using, the way it is currently configured it will use the Linaro toolchain that we downloaded above.
 Cita:
Part B.(These only need to be run the first time you build a kernel.)
A. Load's your configuration file from earlier.
B. Open up a menu to configure your kernel. It will use the config file you loaded in the previous step as a base.
C. Viola start the build. I typically allow 1 job per core, so on my quad core machine I put "make -j4". Just raising that number will not make your build faster, your processor needs to be able to support the number of jobs you are
assigning it.
 Cita:
Part C. (Use the command's when you are building any-time outside of the first)
A. This command gets rid of any old/outdated binaries or modules you compiled before, and let's start fresh. I like to run it every I build unless my changes are really small and localized.
B. A very awesome command, it parses through what has changed and only prompts you about new options.
C. See the explanation for the above "Part C.".
 Cita:
Part D.(Use these for just building kernel modules.)
A. This will re-build all modules.
B. Will rebuild just the module you need. Very useful when you need to rebuild a WiFi module.
Step 6. Now what
 Cita:
Ok we have now started our build and we are waiting for it to finish, so there are two possible outcomes:

Outcome A. Build Succeds

W00t!! You have a kernel built by your self from source. There are a couple things you need in-order to use this kernel on your device any ".ko" modules and the zImage binary. If you pay attention to the output of your compiler then you will see the location of those objects. However the following commands will make your life a bit easier(Thanks Recognized Developer Hacre):
A. Open a terminal
B. Change to your root kernel directory
C. Type "mkdir ../<your_kernel>_output"
D. Type "cp arch/arm/boot/zImage ../<your_kernel>_output/zImage"
E. Type "find . -name "*.ko" -exec cp {} ../<your_kernel>_output \;"

The above steps explained:
A-C. Self-Explanatory
D. Move our kernel binary into our output folder
E. This handy bit of magic finds all ".ko" modules and also copies them into your output file.

You will also need to assemble a kernel image containing a initramfs for your device, along with the kernel binary and such. That however is beyond the scope of this tutorial. To get started though try searching the following phrases.

Code:
building android kernel image xda build kernel image xda unpack boot.img
Outcome B. Build Fails

Oh dear. It failed. Well guess what...this is going to happen..a LOT. Get used to it, and get used to googling and experimenting with different solutions. The following are some tips that will help you with debugging your issues.
Running a "Clean" build
A. Backup your config file(Type "cp .config ../backupConfig")
B. Re-run the build process using just your defconfig from earlier.

Limiting Output(Thanks Hacre.)
A. Another good tip is to run "make -j1" to get the error, as it will limit the amount of text you need to scroll through.
CREDITOS:
Todos los creditos del tutorial al señor thewadegeek de XDA

Saludos
__________________


Si quieres formar parte de la gran familia que somo Lowi, $$$$$$$$$$ y gana 5€ POR LA CARA!


Última edición por Josean94 Día 22/10/13 a las 20:32:54.
Responder Con Cita
Los siguientes 3 usuarios han agradecido a Josean94 su comentario:
[ Mostrar/Ocultar listado de agradecimientos ]


  #2  
Viejo 22/10/13, 20:16:46
Array

[xs_avatar]
jdmoreno jdmoreno no está en línea
Usuario muy activo
 
Fecha de registro: sep 2012
Mensajes: 542
Modelo de smartphone: POCO F3
Tu operador: -

Última edición por jdmoreno Día 22/10/13 a las 20:22:41.
Responder Con Cita
Gracias de parte de:
  #3  
Viejo 23/10/13, 10:54:13
Array

[xs_avatar]
arxenero arxenero no está en línea
Miembro del foro
 
Fecha de registro: mar 2013
Localización: Archena - Murcia
Mensajes: 265
Modelo de smartphone: jiayu g3st
Tu operador: Vodafone
+1 JD,y buena iniciativa josean,pero mucho ingles y si tiro del translate de google,a las primeras de cambio tendre un pisapapeles de 140€ mu bonico,a ver si alguien se anima.
Responder Con Cita
  #4  
Viejo 23/10/13, 11:52:02
Array

[xs_avatar]
trol_sg trol_sg no está en línea
Usuario muy activo
· Votos compra/venta: (2)
 
Fecha de registro: ene 2013
Localización: Segovia
Mensajes: 1,972
Modelo de smartphone: Honor 6 Plus / Infocus m310 / Nokia 5800 XM
Tu operador: Simyo
Que bueno, a ver si alguien se pone manos a la obra y podemos conseguir que los g3s tengan overclock y se asimilen a los g3st. A mi me faltan conocimientos aún para ponerme

Saludos!!
Responder Con Cita
  #5  
Viejo 23/10/13, 12:14:37
Array

[xs_avatar]
monkey technology
Usuario invitado
 
Mensajes: n/a

venga!! donde estáis cerebritos???

Responder Con Cita
  #6  
Viejo 23/10/13, 15:58:21
Array

[xs_avatar]
ubuntusero ubuntusero no está en línea
Usuario muy activo
 
Fecha de registro: ene 2012
Mensajes: 1,326
Tu operador: Movistar

Buen tutorial pero sin los drivers ni el archivo de configuración de nuestro terminal no se puede hacer nada, se necesita todo el código fuente de nuestro kernel para compilar....


Saludos!
__________________
Si te ayude en algo alguna vez ahora puedes ayudarme tu

Responder Con Cita
  #7  
Viejo 23/10/13, 16:10:49
Array

[xs_avatar]
erfae erfae no está en línea
Fundador TF Android™
 
Fecha de registro: abr 2013
Localización: Cádiz
Mensajes: 1,196
Modelo de smartphone: Jiayu G3S/G4S/S3, Blusens SP, iOcean X8, Gionee E7
Tu operador: ONO
 Cita: Originalmente Escrito por ubuntusero Ver Mensaje
Buen tutorial pero sin los drivers ni el archivo de configuración de nuestro terminal no se puede hacer nada, se necesita todo el código fuente de nuestro kernel para compilar....


Saludos!
Exacto!!... no recomiendo compilar el kernel del iocean y probarlo en nuestro terminal... aunque lleven el mismo procesador...
Responder Con Cita
  #8  
Viejo 22/11/14, 09:41:51
Array

[xs_avatar]
Facesnights Facesnights no está en línea
Usuario poco activo
 
Fecha de registro: mar 2014
Mensajes: 19
Modelo de smartphone: Thl W8 Beyond
Tu operador: Movistar
alguien tiene idea de como sacar el archivo de configuración ya que no se encuentra el config.bz??
Yo tengo un thl w8 beyond y he estado investigando y por lo que me dijo el usuario de otro foro que ha compilado android 4.4.2 para el zopo c2 el archivo de configuración de mtk se llama projectconfig.mk pero comparandolo con los otros achivos de defconfig es un poco diferente y he instentado compilar y me dice que tengo que ajustar primero el product/project porque no esta definido..... alguien puede ayudar???

cuando ejecuto el make Midispositivo_defconfig que por ejemplo yo en "midispositivo" pongo el nombre de mi modelo W8Beyond y no se si eso esta bien.....
Responder Con Cita
Respuesta

Estás aquí
Regresar   Portal | Indice > Marcas de importación > Otras marcas de importación > Jiayu > Jiayu G3 / G3S /G3S Turbo > ROMs y desarrollo Jiayu G3S /G3S Turbo



Hora actual: 10:33:34 (GMT +1)



User Alert System provided by Advanced User Tagging (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.

Contactar por correo / Contact by mail / 邮件联系 /