profile image

L o a d i n g . . .

실행 환경

- cpu : intel(32bit)

- 컴파일러 : nasm

- 리눅스 : ubuntu 20.04 LTS

 

설치방법

- sudo apt-get install build-essential gcc-multiplib nasm

 

컴파일

- nasm -f elf32 파일명.asm -o --> 목적 파일을 만든다.

- ld -m elf_i386 -o 파일명 파일명.o --> 실행 파일을 만든다.

 

 

hello_100.c

 

 

hello_100.asm

 

 

hello_100.s

gcc로 컴파일 한 모습이다. 위에서 짠 .asm 코드와 유사한 흐름임을 알 수 있다.

복사했습니다!