Я пытаюсь скомпилировать эту ОС с помощью nasm на 64-битном компьютере с OS X. Тем не менее, ассемблер выдает мне ошибки, которые, кажется, происходят из-за того, что он не понимает, что этот код 64-битный, а не 32-битный. Как я могу это исправить без изменения кода?
Ошибки:
$ nasm kernel64.asm -o kernel64.sys
init_64.asm:153: error: symbol `lodsq' redefined
init_net.asm:38: error: symbol `stosq' redefined
init_net.asm:40: error: symbol `stosq' redefined
init_net.asm:42: error: symbol `stosq' redefined
init_net.asm:49: error: symbol `stosq' redefined
init_net.asm:51: error: symbol `stosq' redefined
init_net.asm:53: error: symbol `stosq' redefined
syscalls/string.asm:363: error: parser: instruction expected
syscalls/screen.asm:264: error: symbol `jrcxz' redefined
syscalls/screen.asm:264: error: parser: instruction expected
syscalls/debug.asm:23: error: symbol `pushfq' redefined
syscalls/misc.asm:119: error: symbol `jrcxz' redefined
syscalls/misc.asm:119: error: parser: instruction expected
syscalls/misc.asm:126: error: symbol `jrcxz' redefined
syscalls/misc.asm:126: error: parser: instruction expected
syscalls/misc.asm:132: error: symbol `jrcxz' redefined
syscalls/misc.asm:132: error: parser: instruction expected
syscalls/misc.asm:326: warning: numeric constant 0x23D8AD1401DE7383 does not fit in 32 bits
syscalls/smp.asm:121: error: symbol `stosq' redefined
syscalls/smp.asm:123: error: symbol `stosq' redefined
syscalls/smp.asm:179: error: symbol `lodsq' redefined
syscalls/smp.asm:181: error: symbol `lodsq' redefined
drivers/net/rtl8169.asm:219: error: symbol `stosq' redefined
drivers/net/i8254x.asm:195: error: symbol `stosq' redefined
drivers/net/i8254x.asm:200: error: symbol `stosq' redefined
interrupt.asm:102: error: symbol `iretq' redefined
interrupt.asm:116: error: symbol `iretq' redefined
interrupt.asm:166: error: symbol `iretq' redefined
interrupt.asm:239: error: symbol `iretq' redefined
interrupt.asm:307: error: symbol `iretq' redefined
interrupt.asm:322: error: symbol `iretq' redefined
interrupt.asm:537: error: symbol `lodsq' redefined
cli.asm:22: error: symbol `jrcxz' redefined
cli.asm:22: error: parser: instruction expected
cli.asm:26: error: symbol `jrcxz' redefined
cli.asm:26: error: parser: instruction expected