您的位置:首页 > 运维架构 > Shell

配置NDK时出现:-bash: /home/Administrator/.bash_profile: line 47: syntax error: unexpected .

2013-11-07 10:57 429 查看
android NDK开发中,在window环境下需要安装cygwin来模拟linux环境,在网上配置文章较多,不详述,在配置的过程中,需要修改cybwin\home\XXX(you computer name)目录下的.bash_profile中末尾添加:

NDK=/cygdrive/e/android-ndk-r8e-windows-x86
export NDK


在启动cygwin,会显示

-bash: $'\r': command not found

-bash: $'\r': command not found

-bash: $'\r': command not found

-bash: $'\r': command not found

-bash: $'\r': command not found

-bash: $'\r': command not found

-bash: $'\r': command not found

-bash: /home/lenovo/.bash_profile: line 47: syntax error: unexpected end of file

解决方法:在cygwin中输入:dos2unix -n .bash_profile .bash_profile

关闭重新打开cygwin,ok了。所以再一次提醒,不要用window里的记事本或者写字本打开修改,使用UltraEdit不要转化格式,因为在window下和linux中回车符是不相同的。



转自: http://blog.csdn.net/xdhywj/article/details/9665023
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐