用户名: 密码: 忘记密码? 注册

android编译kernel时toolchain出现的bug问题page..

作者:  时间: 2010-11-30
android编译kernel时toolchain出现的bug问题page-writeback.c

arm-eabi-gcc -Wp,-MD,mm/.page-writeback.o.d  -nostdinc -isystem /vobs/works/froyo/prebuilt/linux-x86/toolchain/arm-eabi-4.4.0/bin/../lib/gcc/arm-eabi/4.4.0/include -Iinclude  -I/vobs/works/froyo/kernel/arch/arm/include -include include/linux/autoconf.h -D__KERNEL__ -mlittle-endian -Iarch/arm/mach-sc8800g/include -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -fno-delete-null-pointer-checks -O2 -marm -mabi=aapcs-linux -mno-thumb-interwork -funwind-tables -D__LINUX_ARM_ARCH__=5 -march=armv5te -mtune=arm9tdmi -msoft-float -Uarm -Wframe-larger-than=1024 -fno-stack-protector -fomit-frame-pointer -g -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fno-dwarf2-cfi-asm -fconserve-stack   -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(page_writeback)"  -D"KBUILD_MODNAME=KBUILD_STR(page_writeback)"  -c -o mm/.tmp_page-writeback.o mm/page-writeback.c

出现如下错误
CC      mm/page-writeback.o
mm/page-writeback.c: In function 'write_cache_pages':
mm/page-writeback.c:820: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
make[1]: *** [mm/page-writeback.o] Error 1
make: *** [mm] Error 2


发现kernel使用android的prebuilt/linux-x86/toolchain/arm-eabi-4.4.0下的arm-eabi-gcc不能编译通过,该现象在去年8月15号就已经存在,今天很多人都出现了该问题!

锁定到Thu Jan 21 14:24:36 2010 -0800日期之后的toolchain开始就不能编译我们的kernel,具体信息如下:

在该4b06260a916be762d0dd1b93e97306f1b90e3889 哈希之前的toolchain-->arm-eabi-gcc可以正常编译,从Mon Jan 25 09:53:00 2010 -0800的406fda666bb7c8dd4de3294c3827a27c8fd4119c版本开始就不能正常使用arm-eabi-gcc编译kernel了,大家可以尝试一下:
尝试步骤如下:

1. 进入kernel执行如下命令
git clean -xdf
2. 导出arm-eabi-工具链所处系统路径
export PATH=/home/luther.gliethttp/froyo/prebuilt/linux-x86/toolchain/arm-eabi-4.4.0/bin:$PATH
3. 编译
make -j4或make -j4 V=1


目录froyo/prebuilt/linux-x86/toolchain/arm-eabi-4.4.0


commit 406fda666bb7c8dd4de3294c3827a27c8fd4119c
Author: Ying Wang <wangying@google.com>
Date:   Mon Jan 25 09:53:00 2010 -0800

    Check in historical sdk versions.
    
    .jar and .aidl files are copied from released sdks.

commit 4b06260a916be762d0dd1b93e97306f1b90e3889
Merge: 9e332ec e48ddfc
Author: Kenny Root <kroot@android.com>
Date:   Thu Jan 21 14:24:36 2010 -0800

    Merge "Updated flex-2.5.4a binary, now works on 10.5 and 10.6."

commit d49c952991fc41108ca48ce44f7c51e873aacd45
Author: Jing Yu <jingyu@google.com>
Date:   Mon Jan 18 12:38:37 2010 -0800

    Check in a new prebuilt toolchain.
   
    GCC synced to @37473-p2. Android-toolchain synced to 153083-p9.