AmatCoder / mednaffe

A front-end (GUI) for mednafen emulator
GNU General Public License v3.0
429 stars 35 forks source link

It uses MEDNAFEN_HOME as mednafen root directory when It is set. #77

Closed denisfa closed 6 years ago

denisfa commented 6 years ago

Hey, I am back!

As we previously discussed, I opted for the solution where we check in toggles.c file if MEDNAFEN_HOME is set. If it is, we use; otherwise, uses "$HOME/.mednafen/".

Another change I did was in file mednafen.c, where we set the home for non-windows; according to [1], g-get-home-dir already checks for HOME variable and, if unset, goes for the passwd database.

If you need anything, let me know! I did some testing so I believe everything should be fine!

Thanks again!

[1] https://developer.gnome.org/glib/stable/glib-Miscellaneous-Utility-Functions.html#g-get-home-dir

AmatCoder commented 6 years ago

Great, I merged it. Thanks!