← Back to context

Comment by direwolf20

19 days ago

It doesn't link. Something about undefined symbol _main. Can you help?

It doesn't need to link. That is the complete program. Are you suggesting I need to pass a flag to the C++ compiler to disable the linker? How do I do that?

  • Oh, I see what you meant now. I don't think it works:

    ./test: line 1: hlt: command not found

    ./test: line 2: jmp: command not found

    Do you get a dopamine hit out of this?

    • No, that is right, assembly doesn't work in what looks like the output of a Unix shell. Assembly is intended to be input to an assembler. Easy mistake to make, I suppose.

      2 replies →