Gentoo Archives: gentoo-commits

From: "Anthony G. Basile" <blueness@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/musl:master commit in: app-misc/tmux/files/, app-misc/tmux/
Date: Thu, 31 Mar 2016 09:53:27
Message-Id: 1459418157.7944c53ee75ebcd5b93546525188ce71a23450d8.blueness@gentoo
1 commit: 7944c53ee75ebcd5b93546525188ce71a23450d8
2 Author: Masanori Ogino <masanori.ogino <AT> gmail <DOT> com>
3 AuthorDate: Thu Mar 31 02:32:40 2016 +0000
4 Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
5 CommitDate: Thu Mar 31 09:55:57 2016 +0000
6 URL: https://gitweb.gentoo.org/proj/musl.git/commit/?id=7944c53e
7
8 app-misc/tmux: Fix build on musl.
9
10 Signed-off-by: Masanori Ogino <masanori.ogino <AT> gmail.com>
11
12 app-misc/tmux/Manifest | 6 +++
13 app-misc/tmux/files/tmux-2.0-flags.patch | 18 +++++++
14 app-misc/tmux/files/tmux-2.1-cdefs.patch | 25 +++++++++
15 app-misc/tmux/files/tmux.vim | 1 +
16 app-misc/tmux/metadata.xml | 21 ++++++++
17 app-misc/tmux/tmux-2.1-r99.ebuild | 91 ++++++++++++++++++++++++++++++++
18 6 files changed, 162 insertions(+)
19
20 diff --git a/app-misc/tmux/Manifest b/app-misc/tmux/Manifest
21 new file mode 100644
22 index 0000000..808313f
23 --- /dev/null
24 +++ b/app-misc/tmux/Manifest
25 @@ -0,0 +1,6 @@
26 +AUX tmux-2.0-flags.patch 584 SHA256 17dba9f233ca99e31d0619a47ca1cfd1f78bc429bfc9564e3fbc0174b39b61e7 SHA512 029a29182f5998c19883f24eab980d16f2e89c72f4150354e0a1101f9092491e836952fb9442e511508f47fd701c8cc8171f29c6ff097248894b6696d108f6dd WHIRLPOOL 026220084ff52382a168053b67bc5133b6d0d455059108ff85f58bb98eaab1656d1d76cd2c7814b9a7fde75e30cf79dfdf65c6c4429aa51852dfb9e6afef13e4
27 +AUX tmux-2.1-cdefs.patch 562 SHA256 3f8f066899976ff4ec8cba7f7426e64546c9edfdc695a64bafda7f44cc5ebd9c SHA512 94654d2567d9fcdb2788da9da692a5c7e0557dd742a865b0d22ce5b337a8a150674efe6524b9f80da6dbe4dd9519d90df60a7b25689344aceff9268fe90fab4a WHIRLPOOL ce4d40db7bfd35ba10ac3c482adf1ddf142bbe07e21526c6f6e4cbf4e84e71cad1694a6e19e91ae283ece8be594a59d18298c8133753563618478fec9a56098e
28 +AUX tmux.vim 55 SHA256 ab10a475aa32e2aacba7b47e9ca38057ee2e447a953497a0349f1640167be6b7 SHA512 5307bf7d27209ce143d7a57856440ba0462783f5b047b00ec5a5046f1b72110e62ef8bca47b67807cb9e9ffcede06c512f6136d825260f735cc32a63706c9e5e WHIRLPOOL fa0019bcfcbe46aa9d383f8778ea4b7d8ec94f7b58f9c38b07c9b6649ea17363f2436e684d83c0c262711e30b62f90fe7f65d87e3a2c9dc5b391633f75a5d7ca
29 +DIST tmux-2.1.tar.gz 462965 SHA256 31564e7bf4bcef2defb3cb34b9e596bd43a3937cad9e5438701a81a5a9af6176 SHA512 0faa0a60a84b777ca3cf572cf741d0e4f82a9f32d27dfeddfda41bad57830823a6d5f2323f27ba794b86e194d9f7db7028c94dc6a15bb4ac5a18508f890bdaa4 WHIRLPOOL 983024886bdb868bb69ccedc18e9fd62cc5a8f147d647ea43b6f20e297b9b3c45a061e542bcb590ab50cf5d3db43d22015c3a8f18bee33d9c76552bfe13424ed
30 +EBUILD tmux-2.1-r99.ebuild 2349 SHA256 bde8849ede880ac0ba642e9185d60cdd92add9851d4efb49fad45f9cae5a0243 SHA512 78141bef98733e171f1df3d6c2af056eca5d2ed078d0fe509c77feb09185ba6502fa5f4ac883119751a9f1b6960c5d5afa90d2bd32f7bcbc90c6dda50016ff6c WHIRLPOOL 52ed81a4410bc350600c305f71b1b2fd58138632ad4b792e00515263b5246f013b2a87a42cd26b99fb49f11e7dbcbc31354c2808bc1647554dfe298928570e36
31 +MISC metadata.xml 758 SHA256 d8b1acdbe0283795479436be5437f76037fb54e0c6f32ec6cbe4142964bc1889 SHA512 560576353d246b8b63fb5287e3ead7054e8f7307c0d78e02dee378537a6ffb03edc3b444f1c54809a4807cb4ce1f22e7967ae5825692d3804b89cd1b4655e2c7 WHIRLPOOL 048f7302af5a1ed297d4664880e973304627e12565ceffd394a2564b7cf6efba94d0f6ac14d032262970d4b30b09db4ea83a7294f4ce7cdca5512510939f0d36
32
33 diff --git a/app-misc/tmux/files/tmux-2.0-flags.patch b/app-misc/tmux/files/tmux-2.0-flags.patch
34 new file mode 100644
35 index 0000000..d2c40e0
36 --- /dev/null
37 +++ b/app-misc/tmux/files/tmux-2.0-flags.patch
38 @@ -0,0 +1,18 @@
39 + Makefile.am | 3 +--
40 + 1 file changed, 1 insertion(+), 2 deletions(-)
41 +
42 +diff --git a/Makefile.am b/Makefile.am
43 +index 63e20b1..a2fec1e 100644
44 +--- a/Makefile.am
45 ++++ b/Makefile.am
46 +@@ -25,9 +25,8 @@ endif
47 + # Set flags for gcc. gcc4 whines abouts silly stuff so it needs slightly
48 + # different flags.
49 + if IS_GCC
50 +-CFLAGS += -std=gnu99 -O2
51 ++CFLAGS += -std=gnu99
52 + if IS_DEBUG
53 +-CFLAGS += -g
54 + CFLAGS += -Wno-long-long -Wall -W -Wnested-externs -Wformat=2
55 + CFLAGS += -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations
56 + CFLAGS += -Wwrite-strings -Wshadow -Wpointer-arith -Wsign-compare
57
58 diff --git a/app-misc/tmux/files/tmux-2.1-cdefs.patch b/app-misc/tmux/files/tmux-2.1-cdefs.patch
59 new file mode 100644
60 index 0000000..f26a761
61 --- /dev/null
62 +++ b/app-misc/tmux/files/tmux-2.1-cdefs.patch
63 @@ -0,0 +1,25 @@
64 +Remove the dependency on sys/cdefs.h.
65 +
66 +Note that upstream has already done similar changes so it would be unnecessary
67 +with newer versions.
68 +
69 +diff -ru tmux-2.1.orig/compat/vis.h tmux-2.1/compat/vis.h
70 +--- tmux-2.1.orig/compat/vis.h 2016-03-31 11:16:36.113228256 +0900
71 ++++ tmux-2.1/compat/vis.h 2016-03-31 11:17:04.263228615 +0900
72 +@@ -73,9 +73,6 @@
73 + */
74 + #define UNVIS_END 1 /* no more characters */
75 +
76 +-#include <sys/cdefs.h>
77 +-
78 +-__BEGIN_DECLS
79 + char *vis(char *, int, int, int);
80 + int strvis(char *, const char *, int);
81 + int stravis(char **, const char *, int);
82 +@@ -85,6 +82,4 @@
83 + int unvis(char *, char, int *, int);
84 + ssize_t strnunvis(char *, const char *, size_t);
85 +
86 +-__END_DECLS
87 +-
88 + #endif /* !_VIS_H_ */
89
90 diff --git a/app-misc/tmux/files/tmux.vim b/app-misc/tmux/files/tmux.vim
91 new file mode 100644
92 index 0000000..baac50a
93 --- /dev/null
94 +++ b/app-misc/tmux/files/tmux.vim
95 @@ -0,0 +1 @@
96 +au BufNewFile,BufRead .tmux.conf*,tmux.conf* setf tmux
97
98 diff --git a/app-misc/tmux/metadata.xml b/app-misc/tmux/metadata.xml
99 new file mode 100644
100 index 0000000..c2ae9d3
101 --- /dev/null
102 +++ b/app-misc/tmux/metadata.xml
103 @@ -0,0 +1,21 @@
104 +<?xml version="1.0" encoding="UTF-8"?>
105 +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
106 +<pkgmetadata>
107 + <maintainer type="person">
108 + <email>wired@g.o</email>
109 + <name>Alex Alexander</name>
110 + </maintainer>
111 + <maintainer type="project">
112 + <email>shell-tools@g.o</email>
113 + <name>Gentoo Shell Tools Project</name>
114 + </maintainer>
115 + <longdescription>
116 + tmux is a "terminal multiplexer", it enables a number of terminals
117 + (or windows) to be accessed and controlled from a single terminal.
118 + tmux is intended to be a simple, modern, BSD-licensed alternative to
119 + programs such as <pkg>app-misc/screen</pkg>.
120 + </longdescription>
121 + <upstream>
122 + <remote-id type="github">tmux/tmux</remote-id>
123 + </upstream>
124 +</pkgmetadata>
125
126 diff --git a/app-misc/tmux/tmux-2.1-r99.ebuild b/app-misc/tmux/tmux-2.1-r99.ebuild
127 new file mode 100644
128 index 0000000..533b36f
129 --- /dev/null
130 +++ b/app-misc/tmux/tmux-2.1-r99.ebuild
131 @@ -0,0 +1,91 @@
132 +# Copyright 1999-2016 Gentoo Foundation
133 +# Distributed under the terms of the GNU General Public License v2
134 +# $Id$
135 +
136 +EAPI=5
137 +
138 +AUTOTOOLS_AUTORECONF=true
139 +
140 +inherit autotools-utils bash-completion-r1 flag-o-matic versionator
141 +
142 +DESCRIPTION="Terminal multiplexer"
143 +HOMEPAGE="http://tmux.github.io/"
144 +SRC_URI="https://github.com/${PN}/${PN}/releases/download/${PV}/${P}.tar.gz"
145 +
146 +LICENSE="ISC"
147 +SLOT="0"
148 +KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~x86-fbsd ~x64-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
149 +IUSE="debug selinux vim-syntax kernel_FreeBSD kernel_linux"
150 +
151 +CDEPEND="
152 + || (
153 + =dev-libs/libevent-2.0*
154 + >=dev-libs/libevent-2.1.5-r4
155 + )
156 + kernel_linux? ( sys-libs/libutempter )
157 + kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-lib-9.0 sys-libs/libutempter ) )
158 + sys-libs/ncurses:0="
159 +DEPEND="${CDEPEND}
160 + virtual/pkgconfig"
161 +RDEPEND="${CDEPEND}
162 + selinux? ( sec-policy/selinux-screen )
163 + vim-syntax? (
164 + || (
165 + app-editors/vim
166 + app-editors/gvim
167 + )
168 + )"
169 +
170 +DOCS=( CHANGES FAQ README TODO )
171 +
172 +PATCHES=( "${FILESDIR}"/${PN}-2.0-flags.patch "${FILESDIR}"/${PN}-2.1-cdefs.patch )
173 +
174 +src_prepare() {
175 + # bug 438558
176 + # 1.7 segfaults when entering copy mode if compiled with -Os
177 + replace-flags -Os -O2
178 +
179 + # regenerate aclocal.m4 to support earlier automake versions
180 + rm aclocal.m4 || die
181 +
182 + autotools-utils_src_prepare
183 +}
184 +
185 +src_configure() {
186 + local myeconfargs=(
187 + --sysconfdir="${EPREFIX}"/etc
188 + $(use_enable debug)
189 + )
190 + autotools-utils_src_configure
191 +}
192 +
193 +src_install() {
194 + autotools-utils_src_install
195 +
196 + newbashcomp examples/bash_completion_tmux.sh ${PN}
197 +
198 + docinto examples
199 + dodoc examples/*.conf
200 +
201 + if use vim-syntax; then
202 + insinto /usr/share/vim/vimfiles/syntax
203 + doins examples/tmux.vim
204 +
205 + insinto /usr/share/vim/vimfiles/ftdetect
206 + doins "${FILESDIR}"/tmux.vim
207 + fi
208 +}
209 +
210 +pkg_postinst() {
211 + if ! version_is_at_least 1.9a ${REPLACING_VERSIONS:-1.9a}; then
212 + echo
213 + ewarn "Some configuration options changed in this release."
214 + ewarn "Please read the CHANGES file in /usr/share/doc/${PF}/"
215 + ewarn
216 + ewarn "WARNING: After updating to ${P} you will _not_ be able to connect to any"
217 + ewarn "older, running tmux server instances. You'll have to use an existing client to"
218 + ewarn "end your old sessions or kill the old server instances. Otherwise you'll have"
219 + ewarn "to temporarily downgrade to access them."
220 + echo
221 + fi
222 +}