I just want to port another existing Unix program using the tradtional argc, argv handling in main(), so I stumbled over a trivial problem: translating this traditional command line handling into an headless image, started by esvio.exe.
There is no complete documentation of who is doing what, even concerning the VM.
Example:
esvio.exe -iheadless.icx -ini:headless.ini -lCON
the VM delivers
.ini VM Options {
newSpaceSize set to 2097152
}
.ini Desktop {
}
Commandline args {
Handled by VM:
-iheadless.icx
-ini:headless.ini
}
Handling -lCON is missing here, it is simply disappearing.
however when I run
esvio.exe -iheadless.icx -ini:headless.ini -
lx.com
the VM delivers
.ini VM Options {
newSpaceSize set to 2097152
}
.ini Desktop {
}
Commandline args {
Handled by VM:
-iheadless.icx
-ini:headless.ini
-lx.com
} Surprise: -l is now listed (opposite to -lCON).
The whole thing becomes even nastier if you look at s.th. like esvio.exe -iheadless.icx -ini:headless.ini 2>&1 -v -V
Do you know which parameters you can expect when calling System commandLine?
-v or -V?
- power shell is removing something
- windows cmd is removing something (2>&1)
- VM is removing something (-lCON)
but VM is handling -v and passes it over, not removing it.
Up to now I cannot 100% specify which options do not even reach my Smalltalk code and which options I can plan to use without interogating the VM, remember, there are many other steering options targeting the VM, which are silently removed.
And there is no clear specification of what is actually emitted to the stdout/stderr.
This is a problem if you have to provide a program with a clearly defined output.
It is nice to be informed about
VAST Platform, Version 14.0
VM Timestamp: 4.0, (NC) (64-bit Intel) 02/26/25 (140)
(C) Copyright Instantiations 1994, 2025. All rights reserved.
(C) Copyright International Business Machines Corp. 1994, 2006. All rights reserved.
Virtual Machine PID: 316
but can this be configured or turned off?
Is this also influenced by how the VM is started (abt.exe, esvio.exe, ...)
Up to know, this is left to trial and error, also concerning the traces left upon running a program in diverse potentially left log files, vmtraps or walkbacks.
Kind regards
M