David,
Are you sure it's compiled? I get that error when I chmod +x button.c,
and then try to execute it.
You can "cat" it, or check the file length per below (where a.out is the
compiled version of the sample program):
$ ls -l
-rwxr-xr-x 1 root root 12846 Dec 25 02:47 a.out
-rw------- 1 root root 1556 Dec 22 23:20 button.c
$
If it's a text file, but marked as executable, ash will try to execute
it as a shell script, hence the syntax error with unbalanced
parenthesis.
Tom
davidalgeo wrote:
> It may be a newbe question but how do you get a Syntax error
running
> a compiled program. This is the sample button program off the CD
> without any changes. i get this error on everthing even the simple
> 'hello world'.
>
> -rwxrwxrwx 1 david david 5297 Dec 24 19:48 button
> $ ./button
> ./button: 1: Syntax error: "(" unexpected
>
>