I'm running a recent 0.12.0svn build. I'm attempting to get it to run from a U3 (memory stick) environment. If you aren't familiar, U3 copies .EXE and .DLL files to the host machine's hard drive to improve execution but leaves data and configuration files on the flash drive. Anyway, in order for ScummVM to work properly I need to specify 4 command line parameters:
--savepath=%U3_APP_DATA_PATH%\Save --extrapath=%U3_DEVICE_EXEC_PATH% --themepath=%U3_DEVICE_EXEC_PATH% --config=%U3_APP_DATA_PATH%\scummvm.ini
The last 3 work fine however the --savepath parameter seems to be ignored when a config file is specified.
It seems like a bug that command line options override config file options EXCEPT for --savepath. What's strange, though, is that Scumm is CHECKING the --savepath specified parameter because if that folder does not exist ScummVM.exe complains and exits. Before I log a bug I figured I'd sanity check what I'm doing to make sure I haven't overlooked anything.
ScummVM doesn't resolve environment variables properly when used in the config file unfortunately so I can't use the scummvm.ini as a workaround.
Using -c and --savepath on the command line
Moderator: ScummVM Team
Re: Using -c and --savepath on the command line
It's a known bug, documented here: http://sourceforge.net/tracker/index.ph ... tid=418820Islanti wrote:The last 3 work fine however the --savepath parameter seems to be ignored when a config file is specified.
Re: Using -c and --savepath on the command line
For some reason your link didn't work. I did find the bug here. Thanks for the tip!jvprat wrote:It's a known bug, documented here: http://sourceforge.net/tracker/index.ph ... tid=418820Islanti wrote:The last 3 work fine however the --savepath parameter seems to be ignored when a config file is specified.
See the last tracker comment:HackerJoe wrote:This is still a bug in 1.2.1 and latest git.
Using Win x64.
But now it seems to also affect --extrapath=
Quite confusing...
Fingolfin wrote:Well, this happens because launcherDialog() clears the kTransientDomain
domain; and this should actually also affect the extrapath & themepath,
only that it's less noticable there, since the themepath is not needed
anymore once the theme has been loaded.
Thanks for the explanation, I have looked at the bug tracker but this comment I must have missed.
I did not have a look at the code. But maybe it would be the simplest solution to just replace the values (in memory) from the conf/ini file with the command line arguments after it has been loaded.
This would be the behavior I expected.
Leaving the corresponding setting blank in the conf/ini file has no effect on this behavior. And as mentioned it only happens when/if the GUI is displayed.
I did not have a look at the code. But maybe it would be the simplest solution to just replace the values (in memory) from the conf/ini file with the command line arguments after it has been loaded.
This would be the behavior I expected.
Leaving the corresponding setting blank in the conf/ini file has no effect on this behavior. And as mentioned it only happens when/if the GUI is displayed.