Add a joe (editor) package (#622)
authorrnauber <richard.nauber@gmail.com>
Sat, 31 Dec 2016 11:57:44 +0000 (12:57 +0100)
committerFredrik Fornwall <fredrik@fornwall.net>
Sat, 31 Dec 2016 11:57:44 +0000 (12:57 +0100)
packages/joe/build.sh [new file with mode: 0644]
packages/joe/do_not_build_utils.patch [new file with mode: 0644]
packages/joe/fix_errno.patch [new file with mode: 0644]
packages/joe/no_getpwent.patch [new file with mode: 0644]

diff --git a/packages/joe/build.sh b/packages/joe/build.sh
new file mode 100644 (file)
index 0000000..165e6b6
--- /dev/null
@@ -0,0 +1,12 @@
+TERMUX_PKG_HOMEPAGE=http://www.sourceforge.net/projects/joe-editor
+TERMUX_PKG_DESCRIPTION="JOE is a full featured terminal-based screen editor"
+TERMUX_PKG_DEPENDS="ncurses"
+TERMUX_PKG_VERSION=4.3
+TERMUX_PKG_SRCURL=https://sourceforge.net/projects/joe-editor/files/JOE%20sources/joe-${TERMUX_PKG_VERSION}/joe-${TERMUX_PKG_VERSION}.tar.gz
+TERMUX_PKG_FOLDERNAME=joe-${TERMUX_PKG_VERSION}
+TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--disable-termcap"
+
+termux_step_post_extract_package () {                                                   
+# rm -r $TERMUX_PKG_SRCDIR/joe/util                                      
+return
+}
\ No newline at end of file
diff --git a/packages/joe/do_not_build_utils.patch b/packages/joe/do_not_build_utils.patch
new file mode 100644 (file)
index 0000000..60d4a32
--- /dev/null
@@ -0,0 +1,11 @@
+--- src/joe/Makefile.in~       2016-08-31 16:47:12.000000000 +0200
++++ src/joe/Makefile.in        2016-12-26 18:03:33.523645366 +0100
+@@ -316,7 +316,7 @@
+ top_builddir = @top_builddir@
+ top_srcdir = @top_srcdir@
+ AUTOMAKE_OPTIONS = foreign
+-SUBDIRS = util
++SUBDIR = 
+ EXTRA_DIST = TODO
+ sysconf_joedir = $(sysconfdir)/joe
+ data_joedir = $(datadir)/joe
diff --git a/packages/joe/fix_errno.patch b/packages/joe/fix_errno.patch
new file mode 100644 (file)
index 0000000..23688aa
--- /dev/null
@@ -0,0 +1,20 @@
+--- src/joe/b.c~       2016-08-22 15:52:28.000000000 +0200
++++ src/joe/b.c        2016-12-26 18:17:44.449852459 +0100
+@@ -5,6 +5,8 @@
+  *
+  *    This file is part of JOE (Joe's Own Editor)
+  */
++
++
+ #include "types.h"
+ #ifdef HAVE_PWD_H
+@@ -19,7 +21,7 @@
+ #endif
+ #endif
+-extern int errno;
++
+ #ifdef WITH_SELINUX
+ #include <selinux/selinux.h>
diff --git a/packages/joe/no_getpwent.patch b/packages/joe/no_getpwent.patch
new file mode 100644 (file)
index 0000000..81549d9
--- /dev/null
@@ -0,0 +1,19 @@
+--- src/joe/path.c~    2016-07-18 17:11:09.000000000 +0200
++++ src/joe/path.c     2016-12-26 18:48:04.010421451 +0100
+@@ -401,14 +401,14 @@
+ {
+       char **lst = NULL;
+       struct passwd *pw;
+-
++#ifndef __ANDROID__
+       while((pw=getpwent()))
+               if (rmatch(word+1, pw->pw_name)) {
+                       char *t = vsncpy(NULL,0,sc("~"));
+                       lst = vaadd(lst, vsncpy(sv(t),sz(pw->pw_name)));
+                       }
+       endpwent();
+-
++#endif
+       return lst;
+ }
+ /********************************************************************/