cscope: Some minor updates

- Change default include directory.
- Avoid accidental linking to libfl.so.
- Avoid defining errno at all on Android.
This commit is contained in:
Fredrik Fornwall 2017-05-22 14:37:47 +02:00
parent 93a4c5889a
commit 782d1c4823
3 changed files with 21 additions and 4 deletions

View File

@ -5,3 +5,7 @@ TERMUX_PKG_SRCURL=https://downloads.sourceforge.net/project/cscope/cscope/${TERM
TERMUX_PKG_SHA256=4889d091f05aa0845384b1e4965aa31d2b20911fb2c001b2cdcffbcb7212d3af
TERMUX_PKG_DEPENDS="ncurses"
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--with-ncurses=$TERMUX_PREFIX"
termux_step_pre_configure() {
export LEXLIB=""
}

View File

@ -1,12 +1,10 @@
--- src/src/snprintf.c 2009-04-10 13:39:23.000000000 +0000
+++ patches/snprintf.c 2017-05-19 07:45:08.926751318 +0000
@@ -522,7 +522,11 @@
@@ -522,7 +522,9 @@
static UINTMAX_T myround(LDOUBLE);
static LDOUBLE mypow10(int);
+#ifdef __ANDROID__
+extern volatile int errno;
+#else
+#ifndef __ANDROID__
extern int errno;
+#endif

View File

@ -0,0 +1,15 @@
diff -u -r ../cscope-15.8b/src/main.c ./src/main.c
--- ../cscope-15.8b/src/main.c 2014-11-20 22:12:54.000000000 +0100
+++ ./src/main.c 2017-05-22 14:30:00.303282400 +0200
@@ -62,9 +62,9 @@
#define HOME "/" /* no $HOME --> use root directory */
#define SHELL "sh"
#define LINEFLAG "+%s" /* default: used by vi and emacs */
-#define TMPDIR "/tmp"
+#define TMPDIR "@TERMUX_PREFIX@/tmp"
#ifndef DFLT_INCDIR
-#define DFLT_INCDIR "/usr/include"
+#define DFLT_INCDIR "@TERMUX_PREFIX@/include"
#endif
static char const rcsid[] = "$Id: main.c,v 1.57 2014/11/20 21:12:54 broeker Exp $";