| 1 | diff -uNr radare2-2.0.0/libr/core/cconfig.c radare2-2.0.0.mod/libr/core/cconfig.c |
| 2 | --- radare2-2.0.0/libr/core/cconfig.c 2017-10-09 18:05:53.000000000 +0300 |
| 3 | +++ radare2-2.0.0.mod/libr/core/cconfig.c 2017-10-11 16:22:54.521006895 +0300 |
| 4 | @@ -2383,10 +2383,8 @@ |
| 5 | SETPREF ("dir.plugins", R2_LIBDIR"/radare2/"R2_VERSION"/", "Path to plugin files to be loaded at startup"); |
| 6 | #endif |
| 7 | SETCB ("dir.source", "", &cb_dirsrc, "Path to find source files"); |
| 8 | - SETPREF ("dir.types", "/usr/include", "Default path to look for cparse type files"); |
| 9 | -#if __ANDROID__ |
| 10 | - SETPREF ("dir.projects", "/data/data/org.radare.radare2installer/radare2/projects", "Default path for projects"); |
| 11 | -#elif __WINDOWS__ |
| 12 | + SETPREF ("dir.types", "@TERMUX_PREFIX@/include", "Default path to look for cparse type files"); |
| 13 | +#if __WINDOWS__ |
| 14 | SETPREF ("dir.projects", "~\\"R2_HOMEDIR"\\projects", "Default path for projects"); |
| 15 | #else |
| 16 | SETPREF ("dir.projects", "~/"R2_HOMEDIR"/projects", "Default path for projects"); |
| 17 | @@ -2528,6 +2526,9 @@ |
| 18 | #if __WINDOWS__ |
| 19 | r_config_set (cfg, "http.browser", "start"); |
| 20 | #else |
| 21 | +#ifdef __ANDROID__ |
| 22 | + r_config_set (cfg, "http.browser", "xdg-open"); |
| 23 | +#else |
| 24 | if (r_file_exists ("/usr/bin/openURL")) { // iOS ericautils |
| 25 | r_config_set (cfg, "http.browser", "/usr/bin/openURL"); |
| 26 | } else if (r_file_exists ("/system/bin/toolbox")) { |
| 27 | @@ -2540,14 +2541,13 @@ |
| 28 | } else { |
| 29 | r_config_set (cfg, "http.browser", "firefox"); |
| 30 | } |
| 31 | +#endif |
| 32 | r_config_desc (cfg, "http.browser", "Command to open HTTP URLs"); |
| 33 | #endif |
| 34 | SETI ("http.maxsize", 0, "Maximum file size for upload"); |
| 35 | SETPREF ("http.bind", "localhost", "Server address"); |
| 36 | SETPREF ("http.homeroot", "~/.config/radare2/www", "http home root directory"); |
| 37 | -#if __ANDROID__ |
| 38 | - SETPREF ("http.root", "/data/data/org.radare.radare2installer/www", "http root directory"); |
| 39 | -#elif __WINDOWS__ |
| 40 | +#if __WINDOWS__ |
| 41 | SETPREF ("http.root", "www", "http root directory"); |
| 42 | #else |
| 43 | SETPREF ("http.root", R2_WWWROOT, "http root directory"); |
| 44 | diff -uNr radare2-2.0.0/libr/debug/p/debug_rap.c radare2-2.0.0.mod/libr/debug/p/debug_rap.c |
| 45 | --- radare2-2.0.0/libr/debug/p/debug_rap.c 2017-10-09 18:05:53.000000000 +0300 |
| 46 | +++ radare2-2.0.0.mod/libr/debug/p/debug_rap.c 2017-10-11 16:24:45.152199241 +0300 |
| 47 | @@ -49,7 +49,7 @@ |
| 48 | } |
| 49 | |
| 50 | static char *r_debug_rap_reg_profile(RDebug *dbg) { |
| 51 | - char *out, *tf = r_file_temp ("/tmp/rap.XXXXXX"); |
| 52 | + char *out, *tf = r_file_temp ("@TERMUX_PREFIX@/tmp/rap.XXXXXX"); |
| 53 | int fd = r_cons_pipe_open (tf, 1, 0); |
| 54 | r_io_system (dbg->iob.io, "drp"); |
| 55 | r_cons_pipe_close (fd); |
| 56 | diff -uNr radare2-2.0.0/libr/include/r_magic.h radare2-2.0.0.mod/libr/include/r_magic.h |
| 57 | --- radare2-2.0.0/libr/include/r_magic.h 2017-10-09 18:05:53.000000000 +0300 |
| 58 | +++ radare2-2.0.0.mod/libr/include/r_magic.h 2017-10-11 16:23:00.721073712 +0300 |
| 59 | @@ -12,7 +12,7 @@ |
| 60 | R_LIB_VERSION_HEADER(r_magic); |
| 61 | |
| 62 | #ifndef MAGICFILE |
| 63 | -#define MAGICFILE "/etc/magic" |
| 64 | +#define MAGICFILE "@TERMUX_PREFIX@/etc/magic" |
| 65 | #endif |
| 66 | |
| 67 | #define R_MAGIC_PATH R2_PREFIX "/share/radare2/" R2_VERSION "/magic" |