diff --git a/Makefile.griffin b/Makefile.griffin index e2e77b2ac0..aa6355ef6f 100644 --- a/Makefile.griffin +++ b/Makefile.griffin @@ -197,6 +197,7 @@ else ifeq ($(libogc_platform), 1) HAVE_VIDEO_LAYOUT := 0 HAVE_ZLIB := 1 HAVE_7ZIP := 1 + HAVE_CONFIGFILE := 1 RARCH_CONSOLE = 1 ifeq ($(platform), wii) @@ -260,6 +261,7 @@ else ifeq ($(platform), psp1) HAVE_KERNEL_PRX := 1 #HAVE_LANGEXTRA := 1 RARCH_CONSOLE = 1 + HAVE_CONFIGFILE := 1 ifeq ($(BUILD_PRX), 1) LDFLAGS += $(addprefix -L,$(PSPSDK)/lib) -specs=$(PSPSDK)/lib/prxspecs -Wl,-q,-T$(PSPSDK)/lib/linkfile.prx $(LDFLAGS) @@ -317,6 +319,7 @@ else ifeq ($(platform), vita) HAVE_THREADS := 1 HAVE_LIBRETRODB := 1 RARCH_CONSOLE = 1 + HAVE_CONFIGFILE := 1 else ifeq ($(platform), windows_msvc6_x86) HAVE_RPNG := 1 HAVE_RJPEG := 1 @@ -340,6 +343,7 @@ else ifeq ($(platform), windows_msvc6_x86) HAVE_DYLIB := 1 HAVE_DYNAMIC := 1 HAVE_GRIFFIN_CPP := 1 + HAVE_CONFIGFILE := 1 EXT_TARGET := $(TARGET_NAME).exe EXT_INTER_TARGET := $(TARGET_NAME).exe @@ -383,6 +387,7 @@ else ifeq ($(platform), windows_msvc2003_x86) HAVE_DYLIB := 1 HAVE_DYNAMIC := 1 HAVE_GRIFFIN_CPP := 1 + HAVE_CONFIGFILE := 1 EXT_TARGET := $(TARGET_NAME).exe EXT_INTER_TARGET := $(TARGET_NAME).exe @@ -432,6 +437,7 @@ else ifeq ($(platform), windows_msvc2005_x86) HAVE_DYNAMIC := 1 HAVE_GRIFFIN_CPP := 1 HAVE_DIRECTX ?= 1 + HAVE_CONFIGFILE := 1 EXT_TARGET := $(TARGET_NAME).exe EXT_INTER_TARGET := $(TARGET_NAME).exe @@ -483,6 +489,7 @@ else ifneq (,$(findstring windows_msvc2010,$(platform))) HAVE_GRIFFIN_CPP := 1 HAVE_RUNAHEAD := 1 HAVE_DIRECTX ?= 1 + HAVE_CONFIGFILE := 1 EXT_TARGET := $(TARGET_NAME).exe EXT_INTER_TARGET := $(TARGET_NAME).exe @@ -557,6 +564,7 @@ else ifneq (,$(findstring windows_msvc2012,$(platform))) HAVE_GRIFFIN_CPP := 1 HAVE_RUNAHEAD := 1 HAVE_DIRECTX ?= 1 + HAVE_CONFIGFILE := 1 EXT_TARGET := $(TARGET_NAME).exe EXT_INTER_TARGET := $(TARGET_NAME).exe @@ -635,6 +643,7 @@ else ifneq (,$(findstring windows_msvc2013,$(platform))) HAVE_GRIFFIN_CPP := 1 HAVE_RUNAHEAD := 1 HAVE_DIRECTX ?= 1 + HAVE_CONFIGFILE := 1 EXT_TARGET := $(TARGET_NAME).exe EXT_INTER_TARGET := $(TARGET_NAME).exe @@ -713,6 +722,7 @@ else ifneq (,$(findstring windows_msvc2015,$(platform))) HAVE_GRIFFIN_CPP := 1 HAVE_RUNAHEAD := 1 HAVE_DIRECTX ?= 1 + HAVE_CONFIGFILE := 1 EXT_TARGET := $(TARGET_NAME).exe EXT_INTER_TARGET := $(TARGET_NAME).exe @@ -973,6 +983,10 @@ ifeq ($(HAVE_THREADS), 1) endif endif +ifeq ($(HAVE_CONFIGFILE), 1) + CFLAGS += -DHAVE_CONFIGFILE +endif + ifeq ($(HAVE_RSOUND), 1) CFLAGS += -DHAVE_RSOUND endif diff --git a/configuration.c b/configuration.c index b4ac390740..02f78031bc 100644 --- a/configuration.c +++ b/configuration.c @@ -56,12 +56,6 @@ #include "uwp/uwp_func.h" #endif -static const char* invalid_filename_chars[] = { - /* https://support.microsoft.com/en-us/help/905231/information-about-the-characters-that-you-cannot-use-in-site-names--fo */ - "~", "#", "%", "&", "*", "{", "}", "\\", ":", "[", "]", "?", "/", "|", "\'", "\"", - NULL -}; - /* All config related settings go here. */ struct config_bool_setting @@ -3633,6 +3627,11 @@ void config_load(void *data) **/ bool config_save_autoconf_profile(const char *path, unsigned user) { + static const char* invalid_filename_chars[] = { + /* https://support.microsoft.com/en-us/help/905231/information-about-the-characters-that-you-cannot-use-in-site-names--fo */ + "~", "#", "%", "&", "*", "{", "}", "\\", ":", "[", "]", "?", "/", "|", "\'", "\"", + NULL + }; unsigned i; config_file_t *conf = NULL; size_t path_size = PATH_MAX_LENGTH * sizeof(char); diff --git a/griffin/griffin.c b/griffin/griffin.c index 380e9e4646..f4cc840c64 100644 --- a/griffin/griffin.c +++ b/griffin/griffin.c @@ -614,7 +614,9 @@ INPUT #include "../tasks/task_audio_mixer.c" #endif #include "../input/input_keymaps.c" +#ifdef HAVE_CONFIGFILE #include "../input/input_remapping.c" +#endif #ifdef HAVE_OVERLAY #include "../led/drivers/led_overlay.c" diff --git a/menu/menu_displaylist.c b/menu/menu_displaylist.c index b4ea6da052..e44d988d52 100644 --- a/menu/menu_displaylist.c +++ b/menu/menu_displaylist.c @@ -4676,6 +4676,7 @@ unsigned menu_displaylist_build_list(file_list_t *list, enum menu_displaylist_ct MENU_ENUM_LABEL_REMAP_FILE_REMOVE_CONTENT_DIR, MENU_SETTING_ACTION, 0, 0)) count++; +#endif for (p = 0; p < max_users; p++) { @@ -4687,7 +4688,6 @@ unsigned menu_displaylist_build_list(file_list_t *list, enum menu_displaylist_ct MENU_SETTINGS_REMAPPING_PORT_BEGIN + p, p, 0)) count++; } -#endif } break; case DISPLAYLIST_LOAD_CONTENT_LIST: