0
0
mirror of https://github.com/termux/termux-packages.git synced 2024-12-12 00:10:52 +00:00
termux-packages/packages/gpac/src-utils-os_config_init.c.patch
2024-10-23 20:17:45 +03:00

53 lines
2.5 KiB
Diff

+++ ./src/utils/os_config_init.c
@@ -527,10 +527,8 @@
if (check_file_exists("gui/gui.bt", app_path, file_path)) return 1;
/*failsafe - look in possible install dirs ...*/
- if (check_file_exists("gui/gui.bt", "/usr/share/gpac", file_path)) return 1;
- if (check_file_exists("gui/gui.bt", "/usr/local/share/gpac", file_path)) return 1;
- if (check_file_exists("gui/gui.bt", "/opt/share/gpac", file_path)) return 1;
- if (check_file_exists("gui/gui.bt", "/opt/local/share/gpac", file_path)) return 1;
+ if (check_file_exists("gui/gui.bt", "@TERMUX_PREFIX@/share/gpac", file_path)) return 1;
+ if (check_file_exists("gui/gui.bt", "@TERMUX_PREFIX@/opt/share/gpac", file_path)) return 1;
} else if ((path_type==GF_PATH_MODULES) && root) {
//if arch-specific scheme try it first (to avoid loading 64bit versions for 32bit shared...)
@@ -541,26 +539,12 @@
if (check_file_exists(TEST_MODULE, app_path, file_path)) return 1;
root[0]=0;
}
- strcat(app_path, "/lib64/gpac");
- if (check_file_exists(TEST_MODULE, app_path, file_path)) return 1;
- root[0]=0;
strcat(app_path, "/lib/gpac");
if (check_file_exists(TEST_MODULE, app_path, file_path)) return 1;
- root[0]=0;
- strcat(app_path, "/lib/x86_64-linux-gnu/gpac");
- if (check_file_exists(TEST_MODULE, app_path, file_path)) return 1;
- root[0]=0;
- strcat(app_path, "/lib/i386-linux-gnu/gpac");
- if (check_file_exists(TEST_MODULE, app_path, file_path)) return 1;
/*failsafe - look in possible install dirs ...*/
- if (check_file_exists(TEST_MODULE, "/usr/lib64/gpac", file_path)) return 1;
- if (check_file_exists(TEST_MODULE, "/usr/lib/gpac", file_path)) return 1;
- if (check_file_exists(TEST_MODULE, "/usr/local/lib/gpac", file_path)) return 1;
- if (check_file_exists(TEST_MODULE, "/opt/lib/gpac", file_path)) return 1;
- if (check_file_exists(TEST_MODULE, "/opt/local/lib/gpac", file_path)) return 1;
- if (check_file_exists(TEST_MODULE, "/usr/lib/x86_64-linux-gnu/gpac", file_path)) return 1;
- if (check_file_exists(TEST_MODULE, "/usr/lib/i386-linux-gnu/gpac", file_path)) return 1;
+ if (check_file_exists(TEST_MODULE, "@TERMUX_PREFIX@/lib/gpac", file_path)) return 1;
+ if (check_file_exists(TEST_MODULE, "@TERMUX_PREFIX@/opt/lib/gpac", file_path)) return 1;
}
}
@@ -735,7 +719,7 @@
strcpy(szPath, "/system/fonts/");
#else
//scan all /usr/share/fonts, not just /usr/share/fonts/truetype/ which does not exist in some distrros
- strcpy(szPath, "/usr/share/fonts/");
+ strcpy(szPath, "@TERMUX_PREFIX@/share/fonts/");
#endif
}