CM11 Kenel compiling trouble !!

Search This thread

kaotd99

Senior Member
Oct 6, 2013
220
169
24
Ha Tinh
Hi. i have tried to compile cm11 kernel by using kernel source from http://github.com/cm-nokia-x2 and gcc toolchain 4.8 from here http://github.com/huyparody/gcc_linaro

i get config.gz from /proc/
and renamed it to ara_defconfig

and when i:
make ara_defconfig
make

after a few minute, it show me a error:

CC drivers/input/touchscreen/cyttsp4_device_access.o
drivers/input/touchscreen/cyttsp4_device_access.c: In function 'cyttsp4_grpdata_store_touch_params':
drivers/input/touchscreen/cyttsp4_device_access.c:1447:19: warning: 'rc3' may be used uninitialized in this function [-Wuninitialized]
error, forbidden warning: cyttsp4_device_access.c:1447
make[3]: *** [drivers/input/touchscreen/cyttsp4_device_access.o] Error 1
make[2]: *** [drivers/input/touchscreen] Error 2
make[1]: *** [drivers/input] Error 2
make: *** [drivers] Error 2
ubuntu@ubuntu-laptop:~/android/kernel/nokia/msm8610$

how to solve it!! thanks much
 
Last edited:

zombah

Member
Oct 22, 2014
11
10
how to solve it!! thanks much

Hello,
Use toolchain from CyanogenMod prebuilt repo, here is link: github.com/CyanogenMod/android_prebuilt/tree/cm-11.0/linux-x86/toolchain/arm-eabi-4.4.3

You also don't need to copy config from /proc, it is included in source at arch/arm/configs/msm8610-nokia-defconfig.
 
  • Like
Reactions: kaotd99

kaotd99

Senior Member
Oct 6, 2013
220
169
24
Ha Tinh
oh god... i got new error:

i type:
export PATH=/home/kaotd/android/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin:$PATH
export ARCH=arm
export CROSS_COMPILE=arm-eabi-

and:
root@ubuntu-laptop:/home/kaotd/android/kernel/nokia/msm8610# make msm8610-nokia_defconfig
#
# configuration written to .config
#
root@ubuntu-laptop:/home/kaotd/android/kernel/nokia/msm8610# make
scripts/kconfig/conf --silentoldconfig Kconfig
CHK include/linux/version.h
CHK include/generated/utsrelease.h
make[1]: `include/generated/mach-types.h' is up to date.
CC kernel/bounds.s
kernel/bounds.c:1: error: bad value (cortex-a7) for -mtune= switch
make[1]: *** [kernel/bounds.s] Error 1
make: *** [prepare0] Error 2
root@ubuntu-laptop:/home/kaotd/android/kernel/nokia/msm8610#

can you help me ? thanks.... because im a newbie and sorry about that :)
 

kaotd99

Senior Member
Oct 6, 2013
220
169
24
Ha Tinh
@zombah hi again. i was compiled a kernel( zImage )
now i have "Kernel: arch/arm/boot/zImage is ready"
so how can i compare it with boot.img ?
 

zombah

Member
Oct 22, 2014
11
10
Hello,
If you wont use inline kernel building inside CyanogenMod, you probably need to unpack boot.img content replace kernel and then pack boot.img again with replaced kernel. Remember that it is dangerous if your kernel is not bootable, you'll stuck to recovery only boot and if your recovery also lost only unbricking will help.
Use CyanogenMod mkbootimg.c/unpackbootimg.c for that, here is repo github.com/CyanogenMod/android_system_core/tree/cm-11.0/mkbootimg
Here is how to compile them separatly of whole system:
Code:
gcc -o mkbootimg mkbootimg.c ../libmincrypt/sha.c -I../include
gcc -o unpackbootimg unpackbootimg.c ../libmincrypt/sha.c -I../include
you'll need to download dependencies also.
 
  • Like
Reactions: kaotd99

kaotd99

Senior Member
Oct 6, 2013
220
169
24
Ha Tinh
Hello,
If you wont use inline kernel building inside CyanogenMod, you probably need to unpack boot.img content replace kernel and then pack boot.img again with replaced kernel. Remember that it is dangerous if your kernel is not bootable, you'll stuck to recovery only boot and if your recovery also lost only unbricking will help.
Use CyanogenMod mkbootimg.c/unpackbootimg.c for that, here is repo github.com/CyanogenMod/android_system_core/tree/cm-11.0/mkbootimg
Here is how to compile them separatly of whole system:
Code:
gcc -o mkbootimg mkbootimg.c ../libmincrypt/sha.c -I../include
gcc -o unpackbootimg unpackbootimg.c ../libmincrypt/sha.c -I../include
you'll need to download dependencies also.

thanks much :D
 

kaotd99

Senior Member
Oct 6, 2013
220
169
24
Ha Tinh
can you tell me which file contain OverClock number of nokia x2 ? and which kernelPatch i can apply with this kernel ?
 

zombah

Member
Oct 22, 2014
11
10
Hello,
I don't know, i'm not interested in overclocking and never investigated this question.
And i don't recommend you to play with overclocking without deep embedded development skills, it is very easy to kill your device with wrong power modifiers.
 

kaotd99

Senior Member
Oct 6, 2013
220
169
24
Ha Tinh
i'm understand, thanks for your suggestion.

not about nokia x2ds but can i ask you a question?
-can i make a kernel source for a mtk device ? because i have a mtk china phone which not have kernel source from manufacturer !
 

zombah

Member
Oct 22, 2014
11
10
i'm understand, thanks for your suggestion.

not about nokia x2ds but can i ask you a question?
-can i make a kernel source for a mtk device ? because i have a mtk china phone which not have kernel source from manufacturer !
Hello,
Sure it is possible, why not. But you need at least serial/uart console on device, otherwise how you will debug kernel boot problems?
 

Top Liked Posts

  • There are no posts matching your filters.
  • 1
    how to solve it!! thanks much

    Hello,
    Use toolchain from CyanogenMod prebuilt repo, here is link: github.com/CyanogenMod/android_prebuilt/tree/cm-11.0/linux-x86/toolchain/arm-eabi-4.4.3

    You also don't need to copy config from /proc, it is included in source at arch/arm/configs/msm8610-nokia-defconfig.
    1
    Hello,
    If you wont use inline kernel building inside CyanogenMod, you probably need to unpack boot.img content replace kernel and then pack boot.img again with replaced kernel. Remember that it is dangerous if your kernel is not bootable, you'll stuck to recovery only boot and if your recovery also lost only unbricking will help.
    Use CyanogenMod mkbootimg.c/unpackbootimg.c for that, here is repo github.com/CyanogenMod/android_system_core/tree/cm-11.0/mkbootimg
    Here is how to compile them separatly of whole system:
    Code:
    gcc -o mkbootimg mkbootimg.c ../libmincrypt/sha.c -I../include
    gcc -o unpackbootimg unpackbootimg.c ../libmincrypt/sha.c -I../include
    you'll need to download dependencies also.
    1
    can you tell me which files is Touchscreen driver of nokia x2 ?? i think it is synaptics_i2c_rmi4.c/.h

    Hello,
    Nokia X2 have Cypress TMA4XX touchscreen, driver location is drivers/input/touchscreen/cyttsp4*