Compiler icon indicating copy to clipboard operation
Compiler copied to clipboard

how to run the code on 64bits ubuntu

Open peijunbao opened this issue 7 years ago • 3 comments

After I run the cmd $gcc source.S -o source, the error appears like Error: invalid instruction suffix for `push' then I add .code32 on source.S, the executable file was produced successfully. However, when I ran $ ./source, following error happens: Segmentation fault (core dumped) How can I solve it?

peijunbao avatar Apr 16 '17 03:04 peijunbao

I have the same problem with you, And the author has not updated the project for a long time.

niconical avatar Jun 05 '18 04:06 niconical

This reason is it can only be compiled to asm code for 32bit-linux platform and we use 64bit-system usually nowaday. So we can try to run it in vitual machine.

nl8590687 avatar Jul 06 '18 13:07 nl8590687

run the source file with following command in 64 bit system gcc source.S -m32 -o source then you will get a exectutable file. run the exectable file ./source

Raghav714 avatar Oct 02 '18 05:10 Raghav714