|
From: Frank N. <bea...@we...> - 2013-05-31 11:50:25
|
Hi Nick,
> what am i doing wrong?
>
> cc -c nki.c
>
> chmod +x nki.o
>
> ./nki.o
>
> gives:
> bash: ./nki.o: cannot execute binary file
You are telling the compiler to just build an object file from a source
file ("-c"), but that does not build (link) the final executable.
Instead, try
gcc nki.c -o nki -lz
"Works for me."
Hope that helps,
Frank
|