为Ok6410板编译android内核
Ok6410板附带android 2.3源代码(包括内核),我想自定义内核然后使用它,但是在编译过程中我遇到了奇怪的错误,我得到了 Ok6410 board 来自我朋友现在的问题是(官方支持是中文的),我按照文档中写的编译过程进行操作(我通过谷歌翻译翻译了文档),但仍然遇到一些错误,我使用的是 Ubuntu 11.04。 这是我遵循的步骤(它们与手册中写的完全相同,我正在重写它,这样就没有人需要查看文档)。
在桌面创建一个文件夹android。
- cd Desktop/android
- sudo su
- tar jxvf arm-none-linux-gnueabi-arm-2008q3-72-for-linux.tar.bz2 -C /
- tar zxvf arm-linux-gcc-4.3.2.tgz -C /
- ls / usr/local/arm/ -l
[ 上述命令的输出与手册中编写的相同:
root@ubuntu:/home/usama/Desktop/android# ls /usr/local/arm/ -l
Total 8
drwxr-xr-x 7 root root 4096 2009-03-25 12:08 4.3.2
drwxr-xr-x 8 usama usama 4096 2009-02-25 15:30 arm-none-linux-gnueabi
]
6 tar zxvf android_boot-android2.3-128M .tar.gz
7 cd android_boot-android2.3-128M
MakeFile有问题,CROSS_COMPILE的路径错误,以前是
CROSS_COMPILE = / usr/local/arm/4.2.2-eabi/usr/bin/arm-linux-
这样的错误,我将其更改为
CROSS_COMPILE = / usr/local/arm/4.3.2/bin/arm-linux-
[当路径未更改时,我收到错误,
make: /usr/local/arm/4.2.2-eabi/usr/bin/arm-linux-gcc: Command not found
更改路径会消除此错误,
root@ubuntu:/home/usama/Desktop/android/android_boot-android2.3-128M# gedit Makefile
(gedit:6888): Gtk-WARNING **: Attempting to store changes into `/root/.local/share/recently-used.xbel', but failed: Failed to create file '/root/.local/share/recently-used.xbel.X6LD9V': No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to set the permissions of `/root/.local/share/recently-used.xbel', but failed: No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to store changes into `/root/.local/share/recently-used.xbel', but failed: Failed to create file '/root/.local/share/recently-used.xbel.MT0E9V': No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to set the permissions of `/root/.local/share/recently-used.xbel', but failed: No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to store changes into `/root/.local/share/recently-used.xbel', but failed: Failed to create file '/root/.local/share/recently-used.xbel.MFVT9V': No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to set the permissions of `/root/.local/share/recently-used.xbel', but failed: No such file or directory
]
[在更改MakeFile中的路径后建议make clean,但会导致如下所示的错误]
8 make clean
root@ubuntu:/home/usama/Desktop/android/android_boot-android2.3-128M# make clean
make: execvp: /: Permission denied
find /home/usama/Desktop/android/android_boot-android2.3-128M -type f \
\( -name 'core' -o -name '*.bak' -o -name '*~' \
-o -name '*~' -o -name '.depend*' \
-o -name '*.o' -o -name '*.a' \) -print \
| xargs rm -f
rm -f u-boot*
rm -f examples/hello_world examples/timer \
examples/eepro100_eeprom examples/sched \
examples/mem_to_mem_idma2intr examples/82559_eeprom \
examples/smc91111_eeprom examples/interrupt \
examples/test_burst
rm -f tools/img2srec tools/mkimage tools/envcrc \
tools/gen_eth_addr
rm -f tools/mpc86x_clk tools/ncb
rm -f tools/easylogo/easylogo tools/bmp_logo
rm -f tools/gdb/astest tools/gdb/gdbcont tools/gdb/gdbsend
rm -f tools/env/fw_printenv tools/env/fw_setenv
rm -f board/cray/L1/bootscript.c board/cray/L1/bootscript.image
rm -f board/netstar/eeprom board/netstar/crcek board/netstar/crcit
rm -f board/netstar/*.srec board/netstar/*.bin
rm -f board/trab/trab_fkt board/voiceblue/eeprom
rm -f board/integratorap/u-boot.lds board/integratorcp/u-boot.lds
rm -f include/bmp_logo.h
rm -f nand_spl/u-boot-spl nand_spl/u-boot-spl.map
注意: execvp 似乎是一些错误来源,但我不知道它是什么。
9 export PATH=/usr/local/arm/4.3.2/bin/:$PATH
10 make
root@ubuntu:/home/usama/Desktop/android/android_boot-android2.3-128M# make
make: execvp: /: Permission denied
for dir in tools examples post post/cpu ; do make -C $dir _depend ; done
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/tools'
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M/tools'
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/tools'
make[1]: Nothing to be done for `_depend'.
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M/tools'
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/examples'
/bin/sh: /: Permission denied
dirname: missing operand
Try `dirname --help' for more information.
/bin/sh: /: Permission denied
dirname: missing operand
Try `dirname --help' for more information.
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
make[1]: *** No rule to make target `.depend', needed by `_depend'. Stop.
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M/examples'
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/post'
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
make[1]: *** No rule to make target `.depend', needed by `_depend'. Stop.
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M/post'
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/post/cpu'
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
make[1]: *** No rule to make target `.depend', needed by `_depend'. Stop.
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M /post/cpu'
make: *** [depend] Error 2
现在如果有人能说出问题是什么以及如何解决它:
我试图在 < 的论坛中提出这个问题a href="http://bbs.witech.com.cn/" rel="nofollow">witech(销售该板的公司),但我什至无法在这些论坛上注册帐户那些(注册等)说明是中文的,谷歌翻译也好不了多少。
我知道很多人可能没有在 Ok6410 上尝试过 android,但是任何有 Linux 和 android 编译专业知识的人都可以找出问题所在。
注意:
这是在内核编译的最初阶段发生的,所有这些错误都是在编译uboot时出现的,实际的内核源代码编译还没有开始。
感谢您的帮助。
问候
乌萨马
The Ok6410 board comes with android 2.3 source code (including the kernel), I want to customize the kernel and then use it but during the compilation I am getting strange errors, I got the Ok6410 board from my friend now the problem is that (the official support is in Chinese), I followed the compilation process as written in the documentation (I translated the documentation by the google translate) but still I get some errors, I am using Ubuntu 11.04.
Here are the steps I followed (and they are exactly the same as written in manual, I am re-writing it so that no one needs to see the documentation).
Make a folder android in the desktop.
- cd Desktop/android
- sudo su
- tar jxvf arm-none-linux-gnueabi-arm-2008q3-72-for-linux.tar.bz2 -C /
- tar zxvf arm-linux-gcc-4.3.2.tgz -C /
- ls /usr/local/arm/ -l
[
The output of the above command is the same as written in manual:
root@ubuntu:/home/usama/Desktop/android# ls /usr/local/arm/ -l
total 8
drwxr-xr-x 7 root root 4096 2009-03-25 12:08 4.3.2
drwxr-xr-x 8 usama usama 4096 2009-02-25 15:30 arm-none-linux-gnueabi
]
6 tar zxvf android_boot-android2.3-128M.tar.gz
7 cd android_boot-android2.3-128M
There was a problem in the MakeFile, the path of CROSS_COMPILE was wrong, it was previously
CROSS_COMPILE = / usr/local/arm/4.2.2-eabi/usr/bin/arm-linux-
This was wrong, I changed it to
CROSS_COMPILE = / usr/local/arm/4.3.2/bin/arm-linux-
[when the path was not changed, I received the errors,
make: /usr/local/arm/4.2.2-eabi/usr/bin/arm-linux-gcc: Command not found
changing the path removes this error,
root@ubuntu:/home/usama/Desktop/android/android_boot-android2.3-128M# gedit Makefile
(gedit:6888): Gtk-WARNING **: Attempting to store changes into `/root/.local/share/recently-used.xbel', but failed: Failed to create file '/root/.local/share/recently-used.xbel.X6LD9V': No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to set the permissions of `/root/.local/share/recently-used.xbel', but failed: No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to store changes into `/root/.local/share/recently-used.xbel', but failed: Failed to create file '/root/.local/share/recently-used.xbel.MT0E9V': No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to set the permissions of `/root/.local/share/recently-used.xbel', but failed: No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to store changes into `/root/.local/share/recently-used.xbel', but failed: Failed to create file '/root/.local/share/recently-used.xbel.MFVT9V': No such file or directory
(gedit:6888): Gtk-WARNING **: Attempting to set the permissions of `/root/.local/share/recently-used.xbel', but failed: No such file or directory
]
[make clean is recommended after changing path in the MakeFile, but it results in the errors shown below]
8 make clean
root@ubuntu:/home/usama/Desktop/android/android_boot-android2.3-128M# make clean
make: execvp: /: Permission denied
find /home/usama/Desktop/android/android_boot-android2.3-128M -type f \
\( -name 'core' -o -name '*.bak' -o -name '*~' \
-o -name '*~' -o -name '.depend*' \
-o -name '*.o' -o -name '*.a' \) -print \
| xargs rm -f
rm -f u-boot*
rm -f examples/hello_world examples/timer \
examples/eepro100_eeprom examples/sched \
examples/mem_to_mem_idma2intr examples/82559_eeprom \
examples/smc91111_eeprom examples/interrupt \
examples/test_burst
rm -f tools/img2srec tools/mkimage tools/envcrc \
tools/gen_eth_addr
rm -f tools/mpc86x_clk tools/ncb
rm -f tools/easylogo/easylogo tools/bmp_logo
rm -f tools/gdb/astest tools/gdb/gdbcont tools/gdb/gdbsend
rm -f tools/env/fw_printenv tools/env/fw_setenv
rm -f board/cray/L1/bootscript.c board/cray/L1/bootscript.image
rm -f board/netstar/eeprom board/netstar/crcek board/netstar/crcit
rm -f board/netstar/*.srec board/netstar/*.bin
rm -f board/trab/trab_fkt board/voiceblue/eeprom
rm -f board/integratorap/u-boot.lds board/integratorcp/u-boot.lds
rm -f include/bmp_logo.h
rm -f nand_spl/u-boot-spl nand_spl/u-boot-spl.map
Note: execvp seems to be some source of error, but I don't know what it is.
9 export PATH=/usr/local/arm/4.3.2/bin/:$PATH
10 make
root@ubuntu:/home/usama/Desktop/android/android_boot-android2.3-128M# make
make: execvp: /: Permission denied
for dir in tools examples post post/cpu ; do make -C $dir _depend ; done
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/tools'
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M/tools'
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/tools'
make[1]: Nothing to be done for `_depend'.
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M/tools'
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/examples'
/bin/sh: /: Permission denied
dirname: missing operand
Try `dirname --help' for more information.
/bin/sh: /: Permission denied
dirname: missing operand
Try `dirname --help' for more information.
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
make[1]: *** No rule to make target `.depend', needed by `_depend'. Stop.
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M/examples'
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/post'
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
make[1]: *** No rule to make target `.depend', needed by `_depend'. Stop.
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M/post'
make[1]: execvp: /: Permission denied
make[1]: Entering directory `/home/usama/Desktop/android/android_boot-android2.3-128M/post/cpu'
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
/bin/sh: /: Permission denied
make[1]: *** No rule to make target `.depend', needed by `_depend'. Stop.
make[1]: Leaving directory `/home/usama/Desktop/android/android_boot-android2.3-128M /post/cpu'
make: *** [depend] Error 2
Now if anyone can tell that what is the problem and how it can be resolved:
I tried to ask this question in the forums of witech (the company which sales this board) but I m not even able to make account in those forums as all those (registration etc)instructions are in Chinese and Google Translate doesn't work much better.
I know many of u may not have tried android on Ok6410, but anyone who has expertise in Linux and android compilation can find out the problem.
Note:
This is happening in the very initial step of kernel compilation, all these errors come while compiling uboot, actual kernel source compilation haven't started yet.
Thanks for the help.
regards
usama
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
使用此命令:
在发出 make 命令之前。我认为这可能有效。
Use this command:
before giving the make command. I think it may work.