(11-05-2015, 10:40 PM)JosJuice Wrote: GetExeDirectory only works on Windows, so you'd need to make some sort of alternative if you want to use it. A change to make Dolphin use that by default instead of what it does now is unlikely to be accepted, but what you could try to do is to implement Dolphin's portable mode. On Windows, Dolphin will run in a self-contained folder (instead of storing configuration in Documents) if a file with the name portable.txt is present in the same folder as the executable. This is not implemented on other OSes at the moment, but pull requests are welcome. https://github.com/dolphin-emu/dolphin/blob/696d6eae099feba23c280017c5184785fc1e3076/Source/Core/UICommon/UICommon.cpp#L87
Being a Windows user, I'm not sure how the sys directory should be treated in portable mode on non-Windows OSes. Should people be able to put the config in the same folder as the executable without doing so with the sys folder? I suggest asking some other developers, preferably on IRC since not all of them use the forums. It's also fine to just make the PR and then see what they have to say about it, but you might have to rewrite some of the code then.
I noticed the #ifdef _WIN32 around the GetExeDirectory method but it doesn't seem very complex so I guess I should be able to make a Unix variant. Also, I wasn't expecting to make this the default behavior, there has to be some way to allow both behaviors.
The portable seems nice but when I mentioned self-contained install, I was actually just referring to the actual emulator program, I don't have a problem with user configuration being saved in their default location.
(11-05-2015, 11:02 PM)degasus Wrote: I'm all for looking in the local directory if the global one is missing. +1 if you manage to be able to run dolphin within the Source directory without a global installation. I'm pretty sure this will be accepted to master
I'll see what I can do, at first I'll just implement the Windows-like behavior on Linux, then it should only be a matter of placing a couple tests here and there to get Dolphin to run from the Source directory.
