под офтотиком был интерактивный командный отладчик debug.exe
у него была команда ассемблирования А переводившая простенкие асм команды в маш код
это дело можно было сохранять и тем самым создавать исполняемые .сom файлы.
посредством редиректа(недо HEREDOC) можно было использовать debug вкачестве недо ассемблера.
пример : from kipirvine.com/asm/debug/Debug_Tutorial.pdf
All of the commands and instructions may first be placed a text file, which we will call a script file. When Debug is run from DOS, you can use a redirection symbol (<) to tell it toB.5
USING SCRIPT FILES WITH DEBUG
read input from the script file instead of the console. For example, assume that a script
file called input.txt contains the following lines:
a 100
mov ax,5
mov bx,10
add ax,bx
int 20
(blank line)
Q
(Always remember to put a Q on a line by itself at the end of your script file. The Q command returns to the DOS prompt.)
Debug can be executed, using the script file as input:
debug < input.txt
If you are running in a task-switching environment such as Windows, you can edit and save the script file with the Notepad editor or DOS Edit (in a separate window). Then switch back to a window in which you are running Debug. In this way, a program may be modified, saved, assembled, and traced within a few seconds. If you would like the output to be sent to a disk file or the printer, use redirection operators on the DOS command line: debug < input.txt > prn debug < input.txt > output.txt (printer) (disk file)
можно ли для gdb писануть эдакий HEREDOC результатом выполнения которого будь создание исполнимого(в маш кодах) файла ?