1) Script used to build x-loader
#!/bin/bash
mkdir -p ./logs
make distclean
make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- CFLAGS="-Wa,-march=armv7-a+sec" omap4430panda_config
make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- ift 2>&1 | tee ./logs/x-loader_make.out
2) Error
arm-none-linux-gnueabi-gcc -Wa,-gstabs -D__ASSEMBLY__ -g -Os -fno-strict-aliasing -fno-common -ffixed-r8 -msoft-float -D__KERNEL__ -DTEXT_BASE=0x40304350 -I/opt/L27.12.1-P2/x-loader/include -fno-builtin -ffreestanding -nostdinc -isystem /opt/build/arm-none-linux-gnueabi-4.6.0/lib/gcc/arm-none-linux-gnueabi/4.6.0/include -pipe -DCONFIG_ARM -D__ARM__ -march=armv7-a -mabi=apcs-gnu -c -o smc.o /opt/L27.12.1-P2/x-loader/cpu/omap4/smc.S
/opt/L27.12.1-P2/x-loader/cpu/omap4/smc.S: Assembler messages:
/opt/L27.12.1-P2/x-loader/cpu/omap4/smc.S:40: Error: selected processor does not support ARM mode `smc #0'
make[1]: *** [smc.o] Error 1
make[1]: Leaving directory `/opt/L27.12.1-P2/x-loader/cpu/omap4'
make: *** [cpu/omap4/libomap4.a] Error 2
mingfeng@mingfeng-desktop:/opt/L27.12.1-P2/x-loader$
3) Patches
--- x-loader/cpu/omap4/smc.S.orig 2011-05-25 20:06:00.188059813 +0800
+++ x-loader/cpu/omap4/smc.S 2011-05-25 20:04:02.757887581 +0800
@@ -29,6 +29,7 @@
* @arg: Argument passed to ROM api (input in r1 will move to r0)
*/
.globl omap_smc_rom
+.arch_extension sec
omap_smc_rom:
push {r4-r11,lr}
mov r12, r0
4) Build successfully
mingfeng@mingfeng-desktop:/opt/L27.12.1-P2/x-loader$ ls -la
總計 288
drwxr-xr-x 13 mingfeng mingfeng 4096 2011-05-25 20:09 .
drwxr-xr-x 6 mingfeng mingfeng 4096 2011-05-25 20:12 ..
-rw-r--r-- 1 mingfeng mingfeng 908 2011-05-17 23:43 arm_config.mk
drwxr-xr-x 10 mingfeng mingfeng 4096 2011-05-17 23:43 board
-rwxr-xr-x 1 mingfeng mingfeng 242 2011-05-25 20:09 build.sh
drwxr-xr-x 2 mingfeng mingfeng 4096 2011-05-25 20:08 common
-rw-r--r-- 1 mingfeng mingfeng 5260 2011-05-17 23:43 config.mk
drwxr-xr-x 6 mingfeng mingfeng 4096 2011-05-17 23:43 cpu
drwxr-xr-x 2 mingfeng mingfeng 4096 2011-05-25 20:08 disk
drwxr-xr-x 2 mingfeng mingfeng 4096 2011-05-25 20:08 drivers
drwxr-xr-x 3 mingfeng mingfeng 4096 2011-05-17 23:43 fs
drwxr-xr-x 8 mingfeng mingfeng 4096 2011-05-17 23:43 .git
-rw-r--r-- 1 mingfeng mingfeng 520 2011-05-17 23:43 .gitignore
drwxr-xr-x 5 mingfeng mingfeng 4096 2011-05-25 20:08 include
drwxr-xr-x 2 mingfeng mingfeng 4096 2011-05-25 20:08 lib
drwxr-xr-x 2 mingfeng mingfeng 4096 2011-05-18 22:17 logs
-rw-r--r-- 1 mingfeng mingfeng 7529 2011-05-17 23:43 Makefile
-rwxr-xr-x 1 mingfeng mingfeng 1122 2011-05-17 23:43 mkconfig
-rw-r--r-- 1 mingfeng mingfeng 21920 2011-05-25 20:08 MLO
-rw-r--r-- 1 mingfeng mingfeng 3935 2011-05-17 23:43 README
drwxr-xr-x 2 mingfeng mingfeng 4096 2011-05-17 23:43 scripts
-rwxr-xr-x 1 mingfeng mingfeng 9642 2011-05-25 20:08 signGP
-rw-r--r-- 1 mingfeng mingfeng 3279 2011-05-25 20:08 System.map
-rwxr-xr-x 1 mingfeng mingfeng 93779 2011-05-25 20:08 x-load
-rwxr-xr-x 1 mingfeng mingfeng 21400 2011-05-25 20:08 x-load.bin
-rw-r--r-- 1 mingfeng mingfeng 21920 2011-05-25 20:08 x-load.bin.ift
-rw-r--r-- 1 mingfeng mingfeng 29031 2011-05-25 20:08 x-load.map
mingfeng@mingfeng-desktop:/opt/L27.12.1-P2/x-loader$
2011年5月25日 星期三
訂閱:
張貼留言 (Atom)
沒有留言:
張貼留言