$ nasm -v NASM version 2.12.01 $ cat test.asm %ifdef ONE %warning warning db 1 %endif %ifdef TWO %error error db 2 %endif %ifdef THREE %fatal fatal db 3 %endif $ nasm test.asm -o test.bin -l test.lst $ nasm test.asm -o test.bin -l test.lst -DONE $ nasm test.asm -o test.bin -l test.lst -DTWO $ nasm test.asm -o test.bin -l test.lst -DTHREE test.asm:10: fatal: fatal $ nasm test.asm -o test.bin -l test.lst -DONE -DTWO $ nasm test.asm -o test.bin -l test.lst -DONE -DTHREE test.asm:10: fatal: fatal $ nasm test.asm -o test.bin -l test.lst -DTWO -DTHREE test.asm:10: fatal: fatal $ nasm test.asm -o test.bin -l test.lst -DONE -DTWO -DTHREE test.asm:10: fatal: fatal $ nasm test.asm -o test.bin -l test.lst -DONE -DTWO $ cat test.lst 1 %ifdef ONE 2 %warning warning 3 00000000 01 db 1 4 %endif 5 %ifdef TWO 6 %error error 7 00000001 02 db 2 8 %endif 9 %ifdef THREE 10 %fatal fatal 11 db 3 12 %endif $