views:

145

answers:

1

This is a homework task, but it's very simple. The task comes with a working assembly file. I just need help to compile it on linux instead of windows. I'm using Ubuntu. I've installed mingw32. The task itself is to add some functionality, not compiling it.

The file itself is here: here. To much code for including it, and besides the code works and isn't that interesting. Now, does anyone have any idea how I can compile this on linux? If this code is linux compatible we don't need mingw32. But if it isn't we can use mingw32. The tools we are suppose to use on windows is NASM, Alink and td.

Hope anyone got some input, I don't want to install windows for this simple task.

+4  A: 

This is a DOS assembly program. The call to INT 21 gives that away. You can assemble it on Linux, but you won't be able to link it into a DOS executable and won't be able to test it.

You need DOS.

Fortunately, you can install DOSBOX on Ubuntu and use that. https://help.ubuntu.com/community/DOSBox

Then, you need to get NASM, which does work in DOS and install it http://www.nasm.us/doc/nasmdoc1.html#section-1.3.1

Then get ALINK, which also supports DOS http://alink.sourceforge.net/

TD is tougher. If you can find a copy of TurboDebugger 1.0 then it will run in DOSBOX, the newer versions will not. This was included with the free Borland C++ compiler but I don't know what version that was.

Michael Dillon