android: remove some jni functions, use APP_LIB_PATH instead of APP_DATA_PATH

This commit is contained in:
nillerusr
2022-06-19 17:42:55 +03:00
parent f8c6d23362
commit ff99055be1
4 changed files with 15 additions and 22 deletions
+4 -4
View File
@@ -306,7 +306,7 @@ CSysModule *Sys_LoadModule( const char *pModuleName, Sys_Flags flags /* = SYS_NO
#ifdef ANDROID
struct stat statBuf;
char *dataPath = getenv("APP_DATA_PATH");
char *libPath = getenv("APP_LIB_PATH");
char *modLibPath = getenv("APP_MOD_LIB");
if( modLibPath && *modLibPath ) // first load library from mod launcher
@@ -314,13 +314,13 @@ CSysModule *Sys_LoadModule( const char *pModuleName, Sys_Flags flags /* = SYS_NO
Q_snprintf(szAbsoluteModuleName, sizeof(szAbsoluteModuleName), "%s/lib%s", modLibPath, pModuleName);
if( stat(szAbsoluteModuleName, &statBuf) != 0 )
Q_snprintf(szAbsoluteModuleName, sizeof(szAbsoluteModuleName), "%s/%s", modLibPath, pModuleName);
hDLL = Sys_LoadLibrary(szAbsoluteModuleName, flags);
}
Q_snprintf(szAbsoluteModuleName, sizeof(szAbsoluteModuleName), "%s/lib/lib%s", dataPath ,pModuleName);
Q_snprintf(szAbsoluteModuleName, sizeof(szAbsoluteModuleName), "%s/lib%s", libPath ,pModuleName);
if( stat(szAbsoluteModuleName, &statBuf) != 0 )
Q_snprintf(szAbsoluteModuleName, sizeof(szAbsoluteModuleName), "%s/lib/%s", dataPath ,pModuleName);
Q_snprintf(szAbsoluteModuleName, sizeof(szAbsoluteModuleName), "%s/%s", libPath ,pModuleName);
#else
#ifdef POSIX
struct stat statBuf;