| @@ -38,6 +38,13 @@ static void initSystemDir() { | |||||
| return; | return; | ||||
| } | } | ||||
| // Environment variable overrides | |||||
| const char* env = getenv("RACK_SYSTEM_DIR"); | |||||
| if (env) { | |||||
| systemDir = env; | |||||
| return; | |||||
| } | |||||
| #if defined ARCH_MAC | #if defined ARCH_MAC | ||||
| CFBundleRef bundle = CFBundleGetMainBundle(); | CFBundleRef bundle = CFBundleGetMainBundle(); | ||||
| assert(bundle); | assert(bundle); | ||||
| @@ -85,6 +92,13 @@ static void initUserDir() { | |||||
| return; | return; | ||||
| } | } | ||||
| // Environment variable overrides | |||||
| const char* env = getenv("RACK_USER_DIR"); | |||||
| if (env) { | |||||
| userDir = env; | |||||
| return; | |||||
| } | |||||
| #if defined ARCH_WIN | #if defined ARCH_WIN | ||||
| // Get "My Documents" path | // Get "My Documents" path | ||||
| wchar_t documentsBufW[MAX_PATH] = L"."; | wchar_t documentsBufW[MAX_PATH] = L"."; | ||||