all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
blob 30515cbe485e313e01289150ae621abfdd9c2a44 1035 bytes (raw)
name: gnu/packages/patches/retroarch-LIBRETRO_DIRECTORY.patch 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
 
From f308dc91660954ab88bb41868c0b9809592923e6 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(+)

diff --git a/retroarch.c b/retroarch.c
index 6a88c3108e..6807c12b5b 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);
 
+   /* 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"));
+   }
+
    /* Second pass: All other arguments override the config file */
    optind = 1;
 
-- 
2.30.0


debug log:

solving 30515cbe48 ...
found 30515cbe48 in https://git.savannah.gnu.org/cgit/guix.git

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.