zero-one-zero.com/makeexe/part1-tools

index - part1-tools - part2-dos - part3-windows

MakeEXE Project - Tools

by Jonathan Payne

To make an EXE file, I need a way of creating a binary file. While this might have been possible in Notepad, it definitely wouldn't have been any fun. Instead, I wrote a quick C program, MakeBin, to convert a simple listing of bytes into a binary program.

For example, MakeBin would take the following input:

1-TestingMakeBin.txt:
# Testing MakeBin
00 01 02 03     # comment
a0 a1 a2 a3
fc fd fe ff     # another comment

and this command:

C:\>makebin 1-TestingMakeBin.txt 1-TestingMakeBin.bin

Would create a new file, 1-TestingMakeBin.bin, containing the binary equivalent of the hex digits 00 01 02 03 a0 a1 a2 a3 fc fd fe ff. White space (tabs, spaces, new lines, etc) are ignored, as are all the characters on a line after a '#' symbol.

Download MakeBin:

Source code MakeBin.cpp (zip)
EXE file MakeBin.exe (zip)
Test file 1-TestingMakeBin.txt (zip)
Test output 1-TestingMakeBin.bin (zip)
Continue to part2-dos - Return to the index