aboutsummaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorMaxim Storchak <m.storchak@gmail.com>2014-06-14 07:55:27 +0300
committerMaxim Storchak <m.storchak@gmail.com>2014-06-14 07:56:28 +0300
commit0baba8b1f581aed58c001a12b71991c938fe0936 (patch)
tree0b43576ac4207144cdae0c634f64e5ac0bfb94bb /utils
parent13d6e6f3b40fa7b20108f9f36c7760f1780886b8 (diff)
tmux: import from packages, update to latest
Signed-off-by: Maxim Storchak <m.storchak@gmail.com>
Diffstat (limited to 'utils')
-rw-r--r--utils/tmux/Makefile43
-rw-r--r--utils/tmux/patches/100-b64_ntop-conflict_compath_h.patch15
-rw-r--r--utils/tmux/patches/101-b64_ntop-conflict_compat_b64_ntop_c.patch13
-rw-r--r--utils/tmux/patches/102-b64_ntop-conflict_tty_c.patch13
4 files changed, 84 insertions, 0 deletions
diff --git a/utils/tmux/Makefile b/utils/tmux/Makefile
new file mode 100644
index 000000000..ba46808f2
--- /dev/null
+++ b/utils/tmux/Makefile
@@ -0,0 +1,43 @@
+#
+# Copyright (C) 2009-2012 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=tmux
+PKG_VERSION:=1.9a
+PKG_RELEASE:=1
+
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_SOURCE_URL:=@SF/tmux
+PKG_MD5SUM:=b07601711f96f1d260b390513b509a2d
+
+PKG_INSTALL:=1
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/tmux
+ SECTION:=utils
+ CATEGORY:=Utilities
+ TITLE:=Terminal multiplexer
+ DEPENDS:=+libncurses +libevent2 +libpthread +librt
+ URL:=http://tmux.sourceforge.net/
+endef
+
+define Package/tmux/description
+ tmux is a modern, BSD-licensed alternative to GNU screen.
+endef
+
+MAKE_FLAGS += \
+ PREFIX="/usr" \
+ PLATFORM="linux"
+
+define Package/tmux/install
+ $(INSTALL_DIR) $(1)/usr/bin
+ $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/tmux $(1)/usr/bin/
+endef
+
+$(eval $(call BuildPackage,tmux))
diff --git a/utils/tmux/patches/100-b64_ntop-conflict_compath_h.patch b/utils/tmux/patches/100-b64_ntop-conflict_compath_h.patch
new file mode 100644
index 000000000..3b216698c
--- /dev/null
+++ b/utils/tmux/patches/100-b64_ntop-conflict_compath_h.patch
@@ -0,0 +1,15 @@
+diff --git a/compat.h b/compat.h
+index 65d6ec7..7fc3aa7 100644
+--- a/compat.h
++++ b/compat.h
+@@ -219,7 +219,9 @@ int daemon(int, int);
+ #ifndef HAVE_B64_NTOP
+ /* b64_ntop.c */
+ #undef b64_ntop /* for Cygwin */
+-int b64_ntop(const char *, size_t, char *, size_t);
++int local_b64_ntop(const char *, size_t, char *, size_t);
++#else
++#define local_b64_ntop b64_ntop
+ #endif
+
+ #ifndef HAVE_FORKPTY
diff --git a/utils/tmux/patches/101-b64_ntop-conflict_compat_b64_ntop_c.patch b/utils/tmux/patches/101-b64_ntop-conflict_compat_b64_ntop_c.patch
new file mode 100644
index 000000000..a03d18fab
--- /dev/null
+++ b/utils/tmux/patches/101-b64_ntop-conflict_compat_b64_ntop_c.patch
@@ -0,0 +1,13 @@
+diff --git a/compat/b64_ntop.c b/compat/b64_ntop.c
+index 2b4dc2d..a1314ca 100644
+--- a/compat/b64_ntop.c
++++ b/compat/b64_ntop.c
+@@ -122,7 +122,7 @@ static const char Pad64 = '=';
+ */
+
+ int
+-b64_ntop(uint8_t const *src, size_t srclength, char *target, size_t targsize) {
++local_b64_ntop(uint8_t const *src, size_t srclength, char *target, size_t targsize) {
+ size_t datalength = 0;
+ uint8_t input[3];
+ uint8_t output[4];
diff --git a/utils/tmux/patches/102-b64_ntop-conflict_tty_c.patch b/utils/tmux/patches/102-b64_ntop-conflict_tty_c.patch
new file mode 100644
index 000000000..72e0a0789
--- /dev/null
+++ b/utils/tmux/patches/102-b64_ntop-conflict_tty_c.patch
@@ -0,0 +1,13 @@
+diff --git a/tty.c b/tty.c
+index eb2511c..576edbc 100644
+--- a/tty.c
++++ b/tty.c
+@@ -1067,7 +1067,7 @@ tty_cmd_setselection(struct tty *tty, const struct tty_ctx *ctx)
+ off = 4 * ((ctx->num + 2) / 3) + 1; /* storage for base64 */
+ buf = xmalloc(off);
+
+- b64_ntop(ctx->ptr, ctx->num, buf, off);
++ local_b64_ntop(ctx->ptr, ctx->num, buf, off);
+ tty_putcode_ptr2(tty, TTYC_MS, "", buf);
+
+ free(buf);