编译Ralink SDK时碰到的奇怪错误(undefined reference to `main')的解决办法
来源:互联网 发布:matlab和c语言的区别 编辑:程序博客网 时间:2024/06/10 08:47
编译到RT288x_SDK/source/user/iptables-1.4.10出错:
libtool: link: /opt/buildroot-gcc342/bin/mipsel-linux-uclibc-gcc libiptc/.libs/libip4tc.so extensions/libext4.a ./.libs/libxtables.so -lm
/opt/buildroot-gcc342/bin/../lib/gcc/mipsel-linux-uclibc/3.4.2/../../../../mipsel-linux-uclibc/lib/crt1.o: In function `__start':crt1.S:(.text+0x1c): undefined reference to `main'
很是郁闷,google、baidu上都是众说纷纭,没有一个实质性的解决办法。
后来经高人指点,让我看看是不是ubuntu的bash、dash的问题。
到网上一查,还真是这个问题!!
Ubuntu的 shell 默认安装的是 dash,而不是 bash。
运行以下命令查看 sh 的详细信息,确认 shell 对应的程序是哪个:
$ls -al /bin/sh
dash 比 bash 更轻,更快。但 bash 却更常用。
如果一些命令、脚本等总不能正常执行,有可能是 dash 的原因。
比如编译 Android 源代码的时候,如果使用 dash,则有可能编译出错,或者编译的系统不能启动。
通过以下方式可以使 shell 切换回 bash:
$sudo dpkg-reconfigure dash
然后选择 no 或者 否 ,并确认。
这样做将重新配置 dash,并使其不作为默认的 shell 工具。
也可以直接修改 /bin/sh 链接文件,将其指定到 /bin/bash:
$sudo ln -fs /bin/bash /bin/sh
- 编译Ralink SDK时碰到的奇怪错误(undefined reference to `main')的解决办法
- 编译Ralink SDK时碰到的奇怪错误(undefined reference to `main')的解决办法
- 编译Ralink SDK时碰到的奇怪错误(undefined reference to `main')的解决办法
- 编译Ralink SDK时碰到的奇怪错误(undefined reference to `main')的解决办法
- GCC编译uboot出现(.ARM.exidx+0x0): undefined reference to `__aeabi_unwind_cpp_pr0'错误的解决办法
- 编译错误:undefined reference to `__umoddi3'的处理
- 编译错误undefined reference to `dlsym' 的解决方法
- 交叉编译中出现的 'Undefined reference to __aeabi_read_tp' 错误
- 编译什么时候出现Undefined reference to 的错误
- linux编译出现undefined reference to `pow‘的错误
- ubuntu编译mksquash_lzma-3.2的错误:undefined reference to `inflateReset
- gcc 编译出现undefined reference to‘pthread_create’的错误
- 编译错误undefined reference to `dlopen' 'dlsym' 'dlclose'的解决方法
- 交叉编译tslib,遇到undefined reference to rpl_malloc错误解决办法
- 奇怪的undefined reference to `QString::free(QString::Data*)'链接错误
- 编译linux 内核时:decompress.c:(.text+0x25c4): undefined reference to `error'的解决办法
- FreeBSD下编译Fontconfig时提示src/.libs/libfontconfig.so: undefined reference to `xmlCreatePushParserCtxt' 的解决办法
- arm编译QT4.8.5时出现lib/libQtGui.so: undefined reference to `ts_read_raw'的解决办法
- Linux中怎么看出文件是硬连接?
- 在VNC远程桌面环境Xfce4中Tab键失效的解决方法
- Thread.Sleep(1000) 、Task.Delay(1000).Wait() 区别
- 调整数组顺序使奇数位于偶数前面 【微软面试100题 第五十四题】
- kinect驱动切换
- 编译Ralink SDK时碰到的奇怪错误(undefined reference to `main')的解决办法
- 女班主任发给家长的短信,拯救了多少孩子!
- andriod中3g模块没有mac地址的原因
- hdu 1058
- HDOJ 1007 Quoit Design(分治)
- java中使用URL的三种方式
- c++ primer(第五版)笔记 第十二章 动态内存(2)
- 第11周项目6回文数、素数(6输出1000以内的所有回文素数)
- Maven之——Nexus仓库与构件