开发板上运行可执行程序报出错误:

line1: 1: Syntax error: word unexpected (expecting ")")

解决思路:

1.编译器的问题

用arm-linux-gcc编译,可能原来是用gcc编译的。

假如是脚本,#!/bin/sh 改 #!/bin/bash试试。

2.文件完整性

重新烧写或上传一遍。

3.编译命令问题

比如我的一个测试程序test.c :

arm-linux-gcc -o test.o -c test.c    //编译为目标文件

arm-linux-gcc -o test.o test.c        //编译为可执行文件

line: 1: Syntax error: word unexpected (expecting ")")的更多相关文章

  1. 可执行程序无法在Linux上运行,显示line 1: syntax error: word unexpected (expecting ") .

    [问题]用arm-linux-gcc编译出来的可执行文件clkCtl,下载到板子上,在Linux下不能运行:./clkCtl: line 1: syntax error: word unexpecte ...

  2. line1: 1: Syntax error: word unexpected (expecting ")")

    行时错误:line1: 1: Syntax error: word unexpected (expecting ")") 查看Makefile编译规则,可能由于依赖关系造成编译器使 ...

  3. 执行目标文件引发的问题:syntax error: word unexpected (expe...

    今天不小心把一个目标文件当成了可执行文件放到开发板上进行执行,结果出现了这样一个问题:./hello_qt: line 1: syntax error: word unexpected (expect ...

  4. Linix登录报"/etc/profile: line 11: syntax error near unexpected token `$'{\r''"

    同事反馈他在一测试服务器(CentOS Linux release 7.2.1511)上修改了/etc/profile文件后,使用source命令不能生效,让我帮忙看看,结果使用SecureCRT一登 ...

  5. -bash: /etc/profile: line 11: syntax error near unexpected token `$'{\r''报错问题解决

    在Linux系统配置Java环境变量之后执行 source /etc/profile指令报:-bash: /etc/profile: line 11: syntax error near unexpe ...

  6. 解决Linux下编译.sh文件报错 unexpected operator Syntax error: word unexpected

    执行一个脚本  发现报语法错误,但是在其他机器上运行都没有问题 唯一的区别就是 一个是centos机器  报错的是ubuntu 网上搜索了一下 因为Ubuntu默认的sh是连接到dash的,又因为da ...

  7. 写shell,运行出错:syntax error near unexpected token `$’do\r”

    cygwin下面写shell,运行出错:syntax error near unexpected token `$’do\r” 写shell,运行出错:syntax error near unexpe ...

  8. 执行shell脚本提示“syntax error near unexpected token for((i=0;i<$length;i++))”

    sh脚本例如以下: #!/usr/bin/env bash county="3 4 5 6 7 8 9 10 11 12 16 29 39 44 53 62 72 84 97 115 128 ...

  9. syntax error near unexpected token `do(写的shell脚本出现格式问题)--->1.问题2.展示信息3.解决方案

    1问题:Linux和windows下的回车换行符不兼容的问题 [root@node-01 script]# sh start_zk.sh art_zk.sh: line 3: syntax error ...

随机推荐

  1. java怎么删除List中的指定元素

    ArrayList al = new ArrayList(); al.add("a"); al.add("b"); //al.add("b" ...

  2. zend studio 13.0.0 安装破解汉化

    zend studio 13安装破解汉化步骤 官网原版下载 http://downloads.zend.com/studio-eclipse/13.0.0/ZendStudio-13.0.0-win3 ...

  3. [RSpec] LEVEL 1: INTRODUCTION

    Install RSpec: Describe Lets start writing a specification for the Tweet class. Write a describe blo ...

  4. C# 实现对微博短网址的重定向还原

    新浪微博中,为了节省输入字数,通过短网址对发布微博中链接进行重定向.我们可以通过代码实现对短网址进行还原,代码如下: private string GetOrignalLink(string link ...

  5. minigui杂项

    官方下载地址 MiniGUI简介 http://www.minigui.com/zhcn/download/ MiniGUI3.0.12 移植到mini2440 在海思hi3520上移植minigui ...

  6. vb.net Bitmap Drawing

    Public Class Form1 Dim BMP As New Drawing.Bitmap(640, 480) Dim GFX As Graphics = Graphics.FromImage( ...

  7. PHP FTP函数

    PHP FTP 函数 PHP FTP 简介 FTP 函数通过文件传输协议 (FTP) 提供对文件服务器的客户端访问. FTP 函数用于打开.登录以及关闭连接,同时用于上传.下载.重命名.删除及获取文件 ...

  8. CSV 读写

    using System; using System.IO; using System.Runtime.InteropServices; using UnityEngine; public class ...

  9. FileUpload类中FileUpload1.FileName和FileUpload1.PostedFile.FileName的区别

    FileUpload1.FileName 用来获取客户端上使用 FileUpload 控件上载的文件的名称.此属性返回的文件名不包含此文件在客户端上的路径.FileUpload1.PostedFile ...

  10. SQL Server Management Studio 简单使用说明

    1.对数据库中的数据生成脚本 a.选中要生成脚本的数据库右键->任务->生成脚本(如下图)->下一步->下一步->选中你想要生成的内容->下一步->完成