Mail Archives: djgpp/1994/08/16/17:47:39
> Since there are quite a few unix utilities changing their behavior
> based on their name (e.g. gzip) I wonder if it were a good idea to
> extend go32 with an additional switch that allows changing the argv[0]
> of the invoked binary image. Comments...?
Gee, I did that in 1.11 and you didn't notice? Use stubedit to change
the name of the binary-actually-executed, so that to emulate symbolic
links, you would:
(1) have an existing realprog.exe
(2) copy stub.exe to symprog.exe
(3) use stubedit to tell symprog.exe to really run realprog.exe
(4) run symprog.exe
Go32 will pass argv[0] as the name of the symlink, but will load the
code from the actual binary, which is what a symbolic link does in
Unix.
- Raw text -