Making plain binaryfiles using a C compiler(i386+)
高级教师
Cornelis Frank
April10,2000
I wrote this article becau there isn’t much information on the Internet concerning this topic and I needed this for the EduOS project.
No liability is assumed for incidental or conquential damages in connection with or arising out of u of the information or programs contained herein.
So if you blow up your computer becau of my bad“English”that’s your problem not mine. 1Which tools do you need?属羊和属猪
导向性原则
An i386PC or higher.
A Linux distribution like Red Hat or Slackware.
怀孕几个月生孩子
GNU GCC compiler.This C compiler usually comes with Linux.To check if you’re having GCC type the following at the prompt:
touring
gcc--version
This should give an output like:
2.7.2.3
The number probably will not match the above one,but that doesn’t really matter.
封斋是什么意思The binutils for Linux.
NASM Version0.97or higher.The Netwide Asmbler,NASM,is an80x86asmbler designed for portability and modularity.It supports a range of objectfile formats,including Linux‘a.out’and ELF,NetBSD/FreeBSD,COFF,Microsoft16-bit OBJ and Win32.It will also output plain binaryfiles.Its syntax is designed to be simple and easy to understand, similar to Intel’s but less complex.It supports Pentium,P6and MMX opcodes,and has macro capability.
数学小论文四年级
Normally you don’t have NASM on your system.Download it from:
sunsite.unc.edu/pub/Linux/devel/lang/asmblers/
A text editor like pico or emacs.
s开头英文名1See also:Intel Architecture Software Developer’s Manual,V olume1:Basic Architecture,1.4.1.Bit and Byte Order