Mail Archives: djgpp/2013/10/16/22:15:15
On Wed, 16 Oct 2013 16:35:09 -0400, Segadude <starsegadude AT gmail DOT com>
wrote:
...
> I want a single EXE that will run in a pure DOS environment
> without the need for anything else to be installed.
You should only need to follow the two steps Rugxulo posted.
At a DOS command prompt, in the LUA directory, with the DJGPP
environment and path variables setup in order to locate
exe2coff.exe in the DJGPP bin directories:
E.g., after initializing your DJGPP setup, do something like:
C:\lua522\exe2coff lua522.exe
C:\lua522\copy/b cwsdstub.exe + lua522 lua522.exe
What is the name of the lua executable?
What directory is the lua executable within?
Change the above example to fit, if different.
If the LUA build didn't produce a .exe, e.g., lua522 without
a .exe extension, you only need the second step.
> Could you elaborate a bit on how to use the cwsdstub?
To produce a stand-alone executable, cwsdstub must *replace*
the default DJGPP executable stub. That's done by
removing the default stub and pre-pending cwsdstub to the
main executable. 'exe2coff' removes the default stub
from .exe's, leaving the main executable. The DOS command
"copy" (not "xcopy") in binary mode - "copy/b" - combines
the binary objects (stub and main executable) into a single
file.
Rod Pemberton
- Raw text -