i was trying to assemble codes below to shared library via gcc. i used command below in terminal and got errors. Then i googled the question and got a seemingly feasible answer in undefined-reference-to-main-for-shared-library. Then i added option -no-pie, used commands below and got another error. It seems that the order of options matters. But i used codes in 32-bits
Tag: att
Scanf a char pointer in Assembly
So I have a task to do, which requires from me to scanf a char* in assembly. I tried this code: It writes down first printf correctly, then it waits for input (so scanf works), but then when I enter anything -> Segmentation fault. I know, that the char* should be somehow initialized, but how can I do it from
Convert from ascii to integer in AT&T Assembly
How can I convert from ascii to integer? The code is writing an ascii value, and I think that if I can add 48 to value. I can write, but I can’t print, a two-stage number “for example 53 or 156”. How can I print? Answer It’s usually best to think about a high level language version first. If the