diff options
author | Mathieu Othacehe <othacehe@gnu.org> | 2021-10-18 14:33:09 +0000 |
---|---|---|
committer | Mathieu Othacehe <othacehe@gnu.org> | 2021-10-18 14:37:26 +0000 |
commit | e486b2b674badc80627b11077b7df2ac1cab92d8 (patch) | |
tree | 5909547a69c4b185b878c8f0fe8152f1c01fef04 /gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch | |
parent | 0df1eb029efe5ebe3f02e36fa650cae4aaba89ec (diff) | |
parent | 88badc074a5dbebf80115918cf6c0009075154d2 (diff) | |
download | guix-patches-e486b2b674badc80627b11077b7df2ac1cab92d8.tar guix-patches-e486b2b674badc80627b11077b7df2ac1cab92d8.tar.gz |
Merge remote-tracking branch 'signed/master' into core-updates
Diffstat (limited to 'gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch')
-rw-r--r-- | gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch | 32 |
1 files changed, 18 insertions, 14 deletions
diff --git a/gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch b/gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch index 30515cbe48..ffa75918b8 100644 --- a/gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch +++ b/gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch @@ -1,32 +1,36 @@ -From f308dc91660954ab88bb41868c0b9809592923e6 Mon Sep 17 00:00:00 2001 +From 4c02c080475c9d08dbed98dd64ecca337aa359ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=8B=E6=96=87=E6=AD=A6?= <iyzsong@member.fsf.org> Date: Sat, 20 Feb 2021 20:37:39 +0800 Subject: [PATCH] Allow set libretro_directory via environment variable --- - retroarch.c | 9 +++++++++ - 1 file changed, 9 insertions(+) + retroarch.c | 13 ++++++++++++- + 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/retroarch.c b/retroarch.c -index 6a88c3108e..6807c12b5b 100644 +index 8a0461c816..cbf11d8b6a 100644 --- a/retroarch.c +++ b/retroarch.c -@@ -36038,6 +36038,15 @@ static void retroarch_parse_input_and_config( - #endif - config_load(&p_rarch->g_extern); - +@@ -17603,7 +17603,18 @@ static bool retroarch_parse_input_and_config( + p_rarch->configuration_settings->bools.log_to_file, + p_rarch->configuration_settings->bools.log_to_file_timestamp, + p_rarch->configuration_settings->paths.log_dir); +- ++ + /* Override settings via environment variables */ -+ if (getenv("LIBRETRO_DIRECTORY")) { ++ { + settings_t *settings = p_rarch->configuration_settings; -+ retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO_DIRECTORY, NULL); -+ configuration_set_string(settings, -+ settings->paths.directory_libretro, -+ getenv("LIBRETRO_DIRECTORY")); ++ char *value = getenv("LIBRETRO_DIRECTORY"); ++ if (value != NULL) ++ { ++ retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO_DIRECTORY, NULL); ++ configuration_set_string(settings, settings->paths.directory_libretro, value); ++ } + } + /* Second pass: All other arguments override the config file */ optind = 1; -- -2.30.0 +2.33.0 |