0

The code doesn’t work and VS Code says there is no support for the language (Nasm), even though I am using multiple extensions for it as well as the assembler from the official site (nasm.us).

I have tried to use the Netwide Assembler (Nasm) on Visual Studio Code. I have downloaded the following extensions: GNU Assembler Language Support, Nasm Language Support, nasm x86 syntax highlighting, The Netwide Assembler (NASM) and x86 and x86_64 assembly

and the compiler from the official site for the assembler (``nasm.us). I have VS Code on my external drive, so I downloaded the compiler on both C:\Program Files (NASM), C: (nasm-2.15.05), as well as on D: (nasm-2.15.05-win32). The error message I got for trying to compile the program from Visual Studio by typing nasm -f win32 (program) in the terminal was:

nasm : The term 'nasm' is not recognized as a cmdlet, function, script file, or operable program name. Check the spelling of the name or, if a path has been included, see if the path
is correct and try again.
On line:1 character:1
+ nasm -f win32 hello.asm
+ ~~~~
    + CategoryInfo : ObjectNotFound: (nasm:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException
  • If you want that shell command to work, you have to `nasm.exe` in a directory in your PATH, or add a new directory to your PATH, like any other executable you want to run. – Peter Cordes Oct 25 '22 at 19:18

0 Answers0