Gentoo Archives: gentoo-commits

From: "Vadim A. Misbakh-Soloviov" <mva@×××.name>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/lua:master commit in: dev-lang/lua/, dev-lang/lua/files/patches/5.3.4/, ...
Date: Thu, 02 Nov 2017 06:39:20
Message-Id: 1509603879.a50ea72816faadd68763c8f8df9e46b2b5d8bef2.mva@gentoo
1 commit: a50ea72816faadd68763c8f8df9e46b2b5d8bef2
2 Author: Vadim A. Misbakh-Soloviov <git <AT> mva <DOT> name>
3 AuthorDate: Thu Nov 2 06:24:39 2017 +0000
4 Commit: Vadim A. Misbakh-Soloviov <mva <AT> mva <DOT> name>
5 CommitDate: Thu Nov 2 06:24:39 2017 +0000
6 URL: https://gitweb.gentoo.org/proj/lua.git/commit/?id=a50ea728
7
8 lua: porting to patch eclass, sync with tree
9
10 dev-lang/lua/Manifest | 2 +-
11 dev-lang/lua/files/{configure.in => configure.ac} | 0
12 .../5.1.5/0001_make.patch} | 12 ++--
13 .../5.1.5/0002_module_paths.patch} | 6 +-
14 .../no-deprecated/0001_no-deprecated.patch} | 6 +-
15 .../conditional/no-deprecated/0002_tests.patch} | 4 +-
16 .../no-readline/0001_no-readline.patch} | 4 +-
17 .../conditional/static/0001_make-static.patch} | 6 +-
18 .../5.2.4/0001_make.patch} | 0
19 .../5.3.4/0001_make.patch} | 32 +++++++---
20 dev-lang/lua/lua-5.1.5-r101.ebuild | 68 ++++++++--------------
21 dev-lang/lua/lua-5.2.4.ebuild | 54 +++++++++--------
22 .../lua/{lua-5.3.3.ebuild => lua-5.3.4.ebuild} | 58 +++++++++---------
23 13 files changed, 130 insertions(+), 122 deletions(-)
24
25 diff --git a/dev-lang/lua/Manifest b/dev-lang/lua/Manifest
26 index 6b3273b..08f1547 100644
27 --- a/dev-lang/lua/Manifest
28 +++ b/dev-lang/lua/Manifest
29 @@ -1,3 +1,3 @@
30 DIST lua-5.1.5.tar.gz 221213 SHA256 2640fc56a795f29d28ef15e13c34a47e223960b0240e8cb0a82d9b0738695333 SHA512 0142fefcbd13afcd9b201403592aa60620011cc8e8559d4d2db2f92739d18186860989f48caa45830ff4f99bfc7483287fd3ff3a16d4dec928e2767ce4d542a9 WHIRLPOOL 9dac93b73b9ad1ef6c69e0aa11fb53d5efe89274b65c55a1ac30bab23e8a255851b0e44306db54212b1d481e658cecd38e5ff22a25e1fa974858b7b03fb45b75
31 DIST lua-5.2.4.tar.gz 252651 SHA256 b9e2e4aad6789b3b63a056d442f7b39f0ecfca3ae0f1fc0ae4e9614401b69f4b SHA512 cd77148aba4b707b6c159758b5e8444e04f968092eb98f6b4c405b2fb647e709370d5a8dcf604176101d3407e196a7433b5dcdce4fe9605c76191d3649d61a8c WHIRLPOOL 4ddd1aefa63ea2df5d7e2a774aa89a427fa6753c11db26c70ebf82eece7b05807b7ada2c0966057fe2ddebf8ab792c0060aa51b0d29cd58572b2a0ba9dbabfdc
32 -DIST lua-5.3.3.tar.gz 294290 SHA256 5113c06884f7de453ce57702abaac1d618307f33f6789fa870e87a59d772aca2 SHA512 7b8122ed48ea2a9faa47d1b69b4a5b1523bb7be67e78f252bb4339bf75e957a88c5405156e22b4b63ccf607a5407bf017a4cee1ce12b1aa5262047655960a3cc WHIRLPOOL e9d58093327e3c67e167dad9952796f1f2f0dbfa4f165c0ec5a8808a6a73d3b25e564797a2804d408bdaeb7229e7684f907491137d4521119ba918ce87c781bc
33 +DIST lua-5.3.4.tar.gz 303586 SHA256 f681aa518233bc407e23acf0f5887c884f17436f000d453b2491a9f11a52400c SHA512 739e31f82e6a60fa99910c2005e991b3a1e21339af52847f653cb190b30842054d189ca116ffcfdf9b36e07888c9ce5642b1dd2988cc7eff9f8789f9a2e34997 WHIRLPOOL d7d05431f8740c18bea29068f7e82132055d6b236592a5153f2f45043394ac7d6f18982ca62388428e5f57b299351ecf1fe1d675da6e6e9117d3549bb9daf382
34
35 diff --git a/dev-lang/lua/files/configure.in b/dev-lang/lua/files/configure.ac
36 similarity index 100%
37 rename from dev-lang/lua/files/configure.in
38 rename to dev-lang/lua/files/configure.ac
39
40 diff --git a/dev-lang/lua/files/lua-5.1-make-r2.patch b/dev-lang/lua/files/patches/5.1.5/0001_make.patch
41 similarity index 88%
42 rename from dev-lang/lua/files/lua-5.1-make-r2.patch
43 rename to dev-lang/lua/files/patches/5.1.5/0001_make.patch
44 index 2905a62..bcce5b2 100644
45 --- a/dev-lang/lua/files/lua-5.1-make-r2.patch
46 +++ b/dev-lang/lua/files/patches/5.1.5/0001_make.patch
47 @@ -1,6 +1,6 @@
48 -diff -ru lua-5.1.5.orig/Makefile lua-5.1.5/Makefile
49 ---- lua-5.1.5.orig/Makefile 2014-04-15 17:43:34.845435031 +0200
50 -+++ lua-5.1.5/Makefile 2014-04-15 19:05:08.669304987 +0200
51 +diff -ru a/Makefile b/Makefile
52 +--- a/Makefile 2014-04-15 17:43:34.845435031 +0200
53 ++++ b/Makefile 2014-04-15 19:05:08.669304987 +0200
54 @@ -11,7 +11,7 @@
55 # so take care if INSTALL_TOP is not an absolute path.
56 INSTALL_TOP= /usr/local
57 @@ -32,9 +32,9 @@ diff -ru lua-5.1.5.orig/Makefile lua-5.1.5/Makefile
58 + cd src; $(LIBTOOL) --mode=install $(INSTALL_EXEC) lua$V luac$V $(INSTALL_BIN)
59 + cd src; $(INSTALL_DATA) $(TO_INC) $(INSTALL_INC)
60 + cd src; $(LIBTOOL) --mode=install $(INSTALL_DATA) liblua$V.la $(INSTALL_LIB)
61 -diff -ru lua-5.1.5.orig/src/Makefile lua-5.1.5/src/Makefile
62 ---- lua-5.1.5.orig/src/Makefile 2014-04-15 17:43:34.844435031 +0200
63 -+++ lua-5.1.5/src/Makefile 2014-04-15 18:07:21.427397122 +0200
64 +diff -ru a/src/Makefile b/src/Makefile
65 +--- a/src/Makefile 2014-04-15 17:43:34.844435031 +0200
66 ++++ b/src/Makefile 2014-04-15 18:07:21.427397122 +0200
67 @@ -29,10 +29,10 @@
68 LIB_O= lauxlib.o lbaselib.o ldblib.o liolib.o lmathlib.o loslib.o ltablib.o \
69 lstrlib.o loadlib.o linit.o
70
71 diff --git a/dev-lang/lua/files/lua-5.1-module_paths.patch b/dev-lang/lua/files/patches/5.1.5/0002_module_paths.patch
72 similarity index 83%
73 rename from dev-lang/lua/files/lua-5.1-module_paths.patch
74 rename to dev-lang/lua/files/patches/5.1.5/0002_module_paths.patch
75 index 29ac4c3..5b765c6 100644
76 --- a/dev-lang/lua/files/lua-5.1-module_paths.patch
77 +++ b/dev-lang/lua/files/patches/5.1.5/0002_module_paths.patch
78 @@ -5,9 +5,9 @@
79 ## DP: Set Lua's default PATH and CPATH.
80
81 @DPATCH@
82 -diff -urNad trunk~/src/luaconf.h trunk/src/luaconf.h
83 ---- trunk~/src/luaconf.h 2006-02-10 12:44:06.000000000 -0500
84 -+++ trunk/src/luaconf.h 2006-02-17 21:32:55.000000000 -0500
85 +diff -urNad a/src/luaconf.h b/src/luaconf.h
86 +--- a/src/luaconf.h 2006-02-10 12:44:06.000000000 -0500
87 ++++ b/src/luaconf.h 2006-02-17 21:32:55.000000000 -0500
88 @@ -83,13 +83,17 @@
89
90 #else
91
92 diff --git a/dev-lang/lua/files/lua-5.1.4-deprecated.patch b/dev-lang/lua/files/patches/5.1.5/conditional/no-deprecated/0001_no-deprecated.patch
93 similarity index 86%
94 rename from dev-lang/lua/files/lua-5.1.4-deprecated.patch
95 rename to dev-lang/lua/files/patches/5.1.5/conditional/no-deprecated/0001_no-deprecated.patch
96 index a88a991..8e5296a 100644
97 --- a/dev-lang/lua/files/lua-5.1.4-deprecated.patch
98 +++ b/dev-lang/lua/files/patches/5.1.5/conditional/no-deprecated/0001_no-deprecated.patch
99 @@ -1,6 +1,6 @@
100 -diff -rdu lua-5.1.3.orig/src/luaconf.h lua-5.1.3/src/luaconf.h
101 ---- lua-5.1.3.orig/src/luaconf.h 2008-02-12 17:00:03.000000000 +0000
102 -+++ lua-5.1.3/src/luaconf.h 2008-02-12 17:07:55.000000000 +0000
103 +diff -rdu a/src/luaconf.h b/src/luaconf.h
104 +--- a/src/luaconf.h 2008-02-12 17:00:03.000000000 +0000
105 ++++ b/src/luaconf.h 2008-02-12 17:07:55.000000000 +0000
106 @@ -340,14 +340,14 @@
107 ** CHANGE it to undefined as soon as your programs use only '...' to
108 ** access vararg parameters (instead of the old 'arg' table).
109
110 diff --git a/dev-lang/lua/files/lua-5.1.4-test.patch b/dev-lang/lua/files/patches/5.1.5/conditional/no-deprecated/0002_tests.patch
111 similarity index 66%
112 rename from dev-lang/lua/files/lua-5.1.4-test.patch
113 rename to dev-lang/lua/files/patches/5.1.5/conditional/no-deprecated/0002_tests.patch
114 index 99b4ad6..7ba4495 100644
115 --- a/dev-lang/lua/files/lua-5.1.4-test.patch
116 +++ b/dev-lang/lua/files/patches/5.1.5/conditional/no-deprecated/0002_tests.patch
117 @@ -1,5 +1,5 @@
118 ---- test/sieve.lua~ 2002-10-31 03:52:58.000000000 +0100
119 -+++ test/sieve.lua 2008-02-20 17:44:22.468281121 +0100
120 +--- a/test/sieve.lua 2002-10-31 03:52:58.000000000 +0100
121 ++++ b/test/sieve.lua 2008-02-20 17:44:22.468281121 +0100
122 @@ -14,7 +14,7 @@
123 while 1 do
124 local n = g()
125
126 diff --git a/dev-lang/lua/files/lua-5.1-readline.patch b/dev-lang/lua/files/patches/5.1.5/conditional/no-readline/0001_no-readline.patch
127 similarity index 63%
128 rename from dev-lang/lua/files/lua-5.1-readline.patch
129 rename to dev-lang/lua/files/patches/5.1.5/conditional/no-readline/0001_no-readline.patch
130 index f144861..1ddeffd 100644
131 --- a/dev-lang/lua/files/lua-5.1-readline.patch
132 +++ b/dev-lang/lua/files/patches/5.1.5/conditional/no-readline/0001_no-readline.patch
133 @@ -1,5 +1,5 @@
134 ---- lua-5.1.1.orig/src/luaconf.h 2006-04-10 20:27:23.000000000 +0200
135 -+++ lua-5.1.1/src/luaconf.h 2006-11-15 14:53:07.000000000 +0100
136 +--- a/src/luaconf.h 2006-04-10 20:27:23.000000000 +0200
137 ++++ b/src/luaconf.h 2006-11-15 14:53:07.000000000 +0100
138 @@ -36,7 +36,6 @@
139 #if defined(LUA_USE_LINUX)
140 #define LUA_USE_POSIX
141
142 diff --git a/dev-lang/lua/files/lua-5.1-make_static-r1.patch b/dev-lang/lua/files/patches/5.1.5/conditional/static/0001_make-static.patch
143 similarity index 73%
144 rename from dev-lang/lua/files/lua-5.1-make_static-r1.patch
145 rename to dev-lang/lua/files/patches/5.1.5/conditional/static/0001_make-static.patch
146 index e5fdc3a..2efb414 100644
147 --- a/dev-lang/lua/files/lua-5.1-make_static-r1.patch
148 +++ b/dev-lang/lua/files/patches/5.1.5/conditional/static/0001_make-static.patch
149 @@ -1,6 +1,6 @@
150 -diff -ru lua-5.1.1.orig/src/Makefile lua-5.1.1/src/Makefile
151 ---- lua-5.1.1.orig/src/Makefile 2006-11-21 07:19:31 +0000
152 -+++ lua-5.1.1/src/Makefile 2006-11-21 07:19:52 +0000
153 +diff -ru a/src/Makefile b/src/Makefile
154 +--- a/src/Makefile 2006-11-21 07:19:31 +0000
155 ++++ b/src/Makefile 2006-11-21 07:19:52 +0000
156 @@ -196,7 +196,7 @@
157 -rpath $(RPATH) $(LDFLAGS) -o $(LIB_NAME) $(LIB_OBJS) $(LIB_LIBS)
158
159
160 diff --git a/dev-lang/lua/files/lua-5.2-make-r1.patch b/dev-lang/lua/files/patches/5.2.4/0001_make.patch
161 similarity index 100%
162 rename from dev-lang/lua/files/lua-5.2-make-r1.patch
163 rename to dev-lang/lua/files/patches/5.2.4/0001_make.patch
164
165 diff --git a/dev-lang/lua/files/lua-5.3-make.patch b/dev-lang/lua/files/patches/5.3.4/0001_make.patch
166 similarity index 74%
167 rename from dev-lang/lua/files/lua-5.3-make.patch
168 rename to dev-lang/lua/files/patches/5.3.4/0001_make.patch
169 index ed22597..b9e9051 100644
170 --- a/dev-lang/lua/files/lua-5.3-make.patch
171 +++ b/dev-lang/lua/files/patches/5.3.4/0001_make.patch
172 @@ -1,5 +1,6 @@
173 ---- lua-5.1.1.orig/Makefile 2006-06-02 12:53:38.000000000 +0200
174 -+++ lua-5.1.1/Makefile 2006-11-16 02:16:53.000000000 +0100
175 +diff -uNr lua-5.3.3.orig/Makefile lua-5.3.3/Makefile
176 +--- lua-5.3.3.orig/Makefile 2016-12-04 22:29:54.839135901 +0100
177 ++++ lua-5.3.3/Makefile 2016-12-04 22:31:14.235851109 +0100
178 @@ -12,7 +12,7 @@
179 # LUA_ROOT, LUA_LDIR, and LUA_CDIR in luaconf.h.
180 INSTALL_TOP= /usr/local
181 @@ -28,20 +29,35 @@
182 + cd src; $(LIBTOOL) --mode=install $(INSTALL_EXEC) lua$V luac$V $(INSTALL_BIN)
183 + cd src; $(INSTALL_DATA) $(TO_INC) $(INSTALL_INC)
184 + cd src; $(LIBTOOL) --mode=install $(INSTALL_DATA) liblua$V.la $(INSTALL_LIB)
185 ---- lua-5.1.1.orig/src/Makefile 2006-03-22 01:41:49.000000000 +0100
186 -+++ lua-5.1.1/src/Makefile 2006-11-16 02:10:27.000000000 +0100
187 -@@ -39,1 +39,1 @@
188 +diff -uNr lua-5.3.3.orig/src/Makefile lua-5.3.3/src/Makefile
189 +--- lua-5.3.3.orig/src/Makefile 2016-12-04 22:29:54.840135910 +0100
190 ++++ lua-5.3.3/src/Makefile 2016-12-04 22:34:55.980848068 +0100
191 +@@ -36,10 +36,10 @@
192 + lmathlib.o loslib.o lstrlib.o ltablib.o lutf8lib.o loadlib.o linit.o
193 + BASE_O= $(CORE_O) $(LIB_O) $(MYOBJS)
194 +
195 -LUA_T= lua
196 +LUA_T= lua$V
197 -@@ -42,1 +42,1 @@
198 + LUA_O= lua.o
199 +
200 -LUAC_T= luac
201 +LUAC_T= luac$V
202 -@@ -62,1 +62,1 @@
203 + LUAC_O= luac.o
204 +
205 + ALL_O= $(BASE_O) $(LUA_O) $(LUAC_O)
206 +@@ -59,10 +59,10 @@
207 + $(AR) $@ $(BASE_O)
208 + $(RANLIB) $@
209 +
210 -$(LUA_T): $(LUA_O) $(LUA_A)
211 +origin$(LUA_T): $(LUA_O) $(LUA_A)
212 -@@ -65,1 +65,1 @@
213 + $(CC) -o $@ $(LDFLAGS) $(LUA_O) $(LUA_A) $(LIBS)
214 +
215 -$(LUAC_T): $(LUAC_O) $(LUA_A)
216 +origin$(LUAC_T): $(LUAC_O) $(LUA_A)
217 + $(CC) -o $@ $(LDFLAGS) $(LUAC_O) $(LUA_A) $(LIBS)
218 +
219 + clean:
220 @@ -195,3 +195,30 @@
221 lobject.h ltm.h lzio.h
222
223
224 diff --git a/dev-lang/lua/lua-5.1.5-r101.ebuild b/dev-lang/lua/lua-5.1.5-r101.ebuild
225 index 11b0934..d4c6967 100644
226 --- a/dev-lang/lua/lua-5.1.5-r101.ebuild
227 +++ b/dev-lang/lua/lua-5.1.5-r101.ebuild
228 @@ -1,9 +1,9 @@
229 -# Copyright 1999-2016 Gentoo Foundation
230 +# Copyright 1999-2017 Gentoo Foundation
231 # Distributed under the terms of the GNU General Public License v2
232
233 -EAPI=5
234 +EAPI=6
235
236 -inherit eutils multilib multilib-minimal portability toolchain-funcs versionator
237 +inherit eutils multilib multilib-minimal portability toolchain-funcs versionator patches
238
239 DESCRIPTION="A powerful light-weight programming language designed for extending applications"
240 HOMEPAGE="http://www.lua.org/"
241 @@ -12,11 +12,13 @@ SRC_URI="http://www.lua.org/ftp/${P}.tar.gz"
242 LICENSE="MIT"
243 SLOT="5.1"
244 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~arm-linux ~x86-linux"
245 -IUSE="+deprecated emacs readline static"
246 +IUSE="+deprecated emacs readline +static"
247
248 -RDEPEND="readline? ( >=sys-libs/readline-6.2_p5-r1[${MULTILIB_USEDEP}] )
249 +RDEPEND="
250 + readline? ( >=sys-libs/readline-6.3:0[${MULTILIB_USEDEP}] )
251 app-eselect/eselect-lua
252 - !!dev-lang/lua:0"
253 + !dev-lang/lua:0
254 +"
255 DEPEND="${RDEPEND}
256 sys-devel/libtool"
257 PDEPEND="emacs? ( app-emacs/lua-mode )"
258 @@ -24,45 +26,29 @@ PDEPEND="emacs? ( app-emacs/lua-mode )"
259 SAN_SLOT="${SLOT//.}"
260
261 MULTILIB_WRAPPED_HEADERS=(
262 - /usr/include/lua${SLOT}/luaconf.h
263 + "/usr/include/lua${SLOT}/luaconf.h"
264 )
265
266 src_prepare() {
267 - local PATCH_PV=${SLOT}
268 -
269 - epatch "${FILESDIR}"/${PN}-${PATCH_PV}-make-r2.patch
270 - epatch "${FILESDIR}"/${PN}-${PATCH_PV}-module_paths.patch
271 -
272 - [ -d "${FILESDIR}/${PV}" ] && \
273 - EPATCH_SOURCE="${FILESDIR}/${PV}" EPATCH_SUFFIX="upstream.patch" epatch
274 + patches_src_prepare
275
276 # correct lua versioning
277 sed -i -e 's/\(LIB_VERSION = \)6:1:1/\16:5:1/' src/Makefile
278
279 sed -i -e 's:\(/README\)\("\):\1.gz\2:g' doc/readme.html
280
281 - if ! use deprecated ; then
282 - # patches from 5.1.4 still apply
283 - epatch "${FILESDIR}"/${PN}-5.1.4-deprecated.patch
284 - epatch "${FILESDIR}"/${PN}-5.1.4-test.patch
285 - fi
286 -
287 - if ! use readline ; then
288 - epatch "${FILESDIR}"/${PN}-${PATCH_PV}-readline.patch
289 - fi
290 -
291 - # Using dynamic linked lua is not recommended for performance
292 - # reasons. http://article.gmane.org/gmane.comp.lang.lua.general/18519
293 - # Mainly, this is of concern if your arch is poor with GPRs, like x86
294 - # Note that this only affects the interpreter binary (named lua), not the lua
295 - # compiler (built statically) nor the lua libraries (both shared and static
296 - # are installed)
297 - if use static ; then
298 - epatch "${FILESDIR}"/${PN}-${PATCH_PV}-make_static-r1.patch
299 - fi
300 -
301 # custom Makefiles
302 multilib_copy_sources
303 +
304 + cp "${FILESDIR}/lua.pc" "${S}"
305 + # A slotted Lua uses different directories for headers & names for
306 + # libraries, and pkgconfig should reflect that.
307 + sed -r -i \
308 + -e "s:^V=.*:V= ${SLOT}:" \
309 + -e "s:^R=.*:R= ${PV}:" \
310 + -e "s:/,lib,:/$(get_libdir):g" \
311 + -e "/^Libs:/s,((-llua)($| )),\2${SLOT}\3," \
312 + "${S}"/lua.pc
313 }
314
315 multilib_src_configure() {
316 @@ -101,20 +87,14 @@ multilib_src_install() {
317 emake INSTALL_TOP="${ED}/usr" INSTALL_LIB="${ED}/usr/$(get_libdir)" \
318 V=${SLOT} gentoo_install
319
320 - cp "${FILESDIR}/lua.pc" "${WORKDIR}"
321 - sed \
322 - -e "s:^V=.*:V= ${SLOT}:" \
323 - -e "s:^R=.*:R= ${PV}:" \
324 - -e "s:/,lib,:/$(get_libdir):g" \
325 - -i "${WORKDIR}/lua.pc"
326 -
327 insinto "/usr/$(get_libdir)/pkgconfig"
328 - newins "${WORKDIR}/lua.pc" "lua${SLOT}.pc"
329 + newins "${S}/lua.pc" "lua${SLOT}.pc"
330 }
331
332 multilib_src_install_all() {
333 - dodoc HISTORY README
334 - dohtml doc/*.html doc/*.png doc/*.css doc/*.gif
335 + DOCS=(HISTORY README)
336 + HTML_DOCS=(doc/*.html doc/*.png doc/*.css doc/*.gif)
337 + einstalldocs
338
339 doicon etc/lua.ico
340
341
342 diff --git a/dev-lang/lua/lua-5.2.4.ebuild b/dev-lang/lua/lua-5.2.4.ebuild
343 index f93da1d..d355aff 100644
344 --- a/dev-lang/lua/lua-5.2.4.ebuild
345 +++ b/dev-lang/lua/lua-5.2.4.ebuild
346 @@ -1,9 +1,9 @@
347 -# Copyright 1999-2016 Gentoo Foundation
348 +# Copyright 1999-2017 Gentoo Foundation
349 # Distributed under the terms of the GNU General Public License v2
350
351 -EAPI=5
352 +EAPI=6
353
354 -inherit eutils autotools multilib multilib-minimal portability toolchain-funcs
355 +inherit eutils autotools multilib multilib-minimal portability toolchain-funcs patches
356
357 DESCRIPTION="A powerful light-weight programming language designed for extending applications"
358 HOMEPAGE="http://www.lua.org/"
359 @@ -12,26 +12,29 @@ SRC_URI="http://www.lua.org/ftp/${P}.tar.gz"
360 LICENSE="MIT"
361 SLOT="5.2"
362 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~arm-linux ~x86-linux"
363 -IUSE="+deprecated emacs readline static"
364 +IUSE="+deprecated emacs readline +static"
365
366 -RDEPEND="readline? ( sys-libs/readline )
367 +RDEPEND="
368 + readline? ( >=sys-libs/readline-6.3:0[${MULTILIB_USEDEP}] )
369 app-eselect/eselect-lua
370 - !dev-lang/lua:0"
371 + !dev-lang/lua:0
372 +"
373 DEPEND="${RDEPEND}
374 sys-devel/libtool"
375 PDEPEND="emacs? ( app-emacs/lua-mode )"
376
377 MULTILIB_WRAPPED_HEADERS=(
378 - /usr/include/lua${SLOT}/luaconf.h
379 + "/usr/include/lua${SLOT}/luaconf.h"
380 )
381
382 src_prepare() {
383 - local PATCH_PV=${SLOT}
384 + patches_src_prepare
385
386 - epatch "${FILESDIR}"/${PN}-${PATCH_PV}-make-r1.patch
387 -
388 - [ -d "${FILESDIR}/${PV}" ] && \
389 - EPATCH_SOURCE="${FILESDIR}/${PV}" EPATCH_SUFFIX="upstream.patch" epatch
390 + # use glibtool on Darwin (versus Apple libtool)
391 + if [[ ${CHOST} == *-darwin* ]] ; then
392 + sed -i -e '/LIBTOOL = /s:/libtool:/glibtool:' \
393 + Makefile src/Makefile || die
394 + fi
395
396 # correct lua versioning
397 sed -i -e 's/\(LIB_VERSION = \)6:1:1/\10:0:0/' src/Makefile || die
398 @@ -53,11 +56,21 @@ src_prepare() {
399 fi
400
401 # upstream does not use libtool, but we do (see bug #336167)
402 - cp "${FILESDIR}/configure.in" "${S}"/ || die
403 + cp "${FILESDIR}/configure.ac" "${S}"/ || die
404 eautoreconf
405
406 # custom Makefiles
407 multilib_copy_sources
408 +
409 + cp "${FILESDIR}/lua.pc" "${S}"
410 + # A slotted Lua uses different directories for headers & names for
411 + # libraries, and pkgconfig should reflect that.
412 + sed -r -i \
413 + -e "s:^V=.*:V= ${SLOT}:" \
414 + -e "s:^R=.*:R= ${PV}:" \
415 + -e "s:/,lib,:/$(get_libdir):g" \
416 + -e "/^Libs:/s,((-llua)($| )),\2${SLOT}\3," \
417 + "${S}"/lua.pc
418 }
419
420 multilib_src_configure() {
421 @@ -104,21 +117,14 @@ multilib_src_install() {
422 emake INSTALL_TOP="${ED}/usr" INSTALL_LIB="${ED}/usr/$(get_libdir)" \
423 V=${SLOT} gentoo_install
424
425 - # We want packages to find our things...
426 - cp "${FILESDIR}/lua.pc" "${WORKDIR}"
427 - sed \
428 - -e "s:^V=.*:V= ${SLOT}:" \
429 - -e "s:^R=.*:R= ${PV}:" \
430 - -e "s:/,lib,:/$(get_libdir):g" \
431 - -i "${WORKDIR}/lua.pc"
432 -
433 insinto "/usr/$(get_libdir)/pkgconfig"
434 - newins "${WORKDIR}/lua.pc" "lua${SLOT}.pc"
435 + newins "${S}/lua.pc" "lua${SLOT}.pc"
436 }
437
438 multilib_src_install_all() {
439 - dodoc README
440 - dohtml doc/*.html doc/*.png doc/*.css doc/*.gif
441 + DOCS=(README)
442 + HTML_DOCS=(doc/*.html doc/*.png doc/*.css doc/*.gif)
443 + einstalldocs
444
445 newman doc/lua.1 lua${SLOT}.1
446 newman doc/luac.1 luac${SLOT}.1
447
448 diff --git a/dev-lang/lua/lua-5.3.3.ebuild b/dev-lang/lua/lua-5.3.4.ebuild
449 similarity index 68%
450 rename from dev-lang/lua/lua-5.3.3.ebuild
451 rename to dev-lang/lua/lua-5.3.4.ebuild
452 index e2fe750..060ee45 100644
453 --- a/dev-lang/lua/lua-5.3.3.ebuild
454 +++ b/dev-lang/lua/lua-5.3.4.ebuild
455 @@ -1,9 +1,9 @@
456 -# Copyright 1999-2016 Gentoo Foundation
457 +# Copyright 1999-2017 Gentoo Foundation
458 # Distributed under the terms of the GNU General Public License v2
459
460 -EAPI=5
461 +EAPI=6
462
463 -inherit eutils autotools multilib multilib-minimal portability toolchain-funcs
464 +inherit eutils autotools multilib multilib-minimal portability toolchain-funcs patches
465
466 DESCRIPTION="A powerful light-weight programming language designed for extending applications"
467 HOMEPAGE="http://www.lua.org/"
468 @@ -11,27 +11,30 @@ SRC_URI="http://www.lua.org/ftp/${P}.tar.gz"
469
470 LICENSE="MIT"
471 SLOT="5.3"
472 -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~arm-linux ~x86-linux"
473 -IUSE="+deprecated emacs readline static"
474 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
475 +IUSE="+deprecated emacs readline +static"
476
477 -RDEPEND="readline? ( sys-libs/readline )
478 +RDEPEND="
479 + readline? ( >=sys-libs/readline-6.3:0[${MULTILIB_USEDEP}] )
480 app-eselect/eselect-lua
481 - !dev-lang/lua:0"
482 + !dev-lang/lua:0
483 +"
484 DEPEND="${RDEPEND}
485 sys-devel/libtool"
486 PDEPEND="emacs? ( app-emacs/lua-mode )"
487
488 MULTILIB_WRAPPED_HEADERS=(
489 - /usr/include/lua${SLOT}/luaconf.h
490 + "/usr/include/lua${SLOT}/luaconf.h"
491 )
492
493 src_prepare() {
494 - local PATCH_PV=${SLOT}
495 + patches_src_prepare
496
497 - epatch "${FILESDIR}"/${PN}-${PATCH_PV}-make.patch
498 -
499 - [ -d "${FILESDIR}/${PV}" ] && \
500 - EPATCH_SOURCE="${FILESDIR}/${PV}" EPATCH_SUFFIX="upstream.patch" epatch
501 + # use glibtool on Darwin (versus Apple libtool)
502 + if [[ ${CHOST} == *-darwin* ]] ; then
503 + sed -i -e '/LIBTOOL = /s:/libtool:/glibtool:' \
504 + Makefile src/Makefile || die
505 + fi
506
507 sed -i -e 's:\(/README\)\("\):\1.gz\2:g' doc/readme.html || die
508
509 @@ -52,11 +55,21 @@ src_prepare() {
510 fi
511
512 # upstream does not use libtool, but we do (see bug #336167)
513 - cp "${FILESDIR}/configure.in" "${S}"/ || die
514 + cp "${FILESDIR}/configure.ac" "${S}"/ || die
515 eautoreconf
516
517 # custom Makefiles
518 multilib_copy_sources
519 +
520 + cp "${FILESDIR}/lua.pc" "${S}"
521 + # A slotted Lua uses different directories for headers & names for
522 + # libraries, and pkgconfig should reflect that.
523 + sed -r -i \
524 + -e "s:^V=.*:V= ${SLOT}:" \
525 + -e "s:^R=.*:R= ${PV}:" \
526 + -e "s:/,lib,:/$(get_libdir):g" \
527 + -e "/^Libs:/s,((-llua)($| )),\2${SLOT}\3," \
528 + "${S}"/lua.pc
529 }
530
531 multilib_src_configure() {
532 @@ -83,7 +96,7 @@ multilib_src_compile() {
533 cd src
534
535 local myCFLAGS;
536 - use deprecated && myCFLAGS="-DLUA_COMPAT_5_2 -DLUA_COMPAT_5_1"
537 + use deprecated && myCFLAGS="-DLUA_COMPAT_5_2 -DLUA_COMPAT_5_1 -DLUA_COMPAT_ALL"
538 # -DLUA_COMPAT_FLOATSTRING"
539
540 case "${CHOST}" in
541 @@ -104,21 +117,14 @@ multilib_src_install() {
542 emake INSTALL_TOP="${ED}/usr" INSTALL_LIB="${ED}/usr/$(get_libdir)" \
543 V=${SLOT} gentoo_install
544
545 - # We want packages to find our things...
546 - cp "${FILESDIR}/lua.pc" "${WORKDIR}"
547 - sed \
548 - -e "s:^V=.*:V= ${SLOT}:" \
549 - -e "s:^R=.*:R= ${PV}:" \
550 - -e "s:/,lib,:/$(get_libdir):g" \
551 - -i "${WORKDIR}/lua.pc"
552 -
553 insinto "/usr/$(get_libdir)/pkgconfig"
554 - newins "${WORKDIR}/lua.pc" "lua${SLOT}.pc"
555 + newins "${S}/lua.pc" "lua${SLOT}.pc"
556 }
557
558 multilib_src_install_all() {
559 - dodoc README
560 - dohtml doc/*.html doc/*.png doc/*.css doc/*.gif
561 + DOCS=(README)
562 + HTML_DOCS=(doc/*.html doc/*.png doc/*.css doc/*.gif)
563 + einstalldocs
564
565 newman doc/lua.1 lua${SLOT}.1
566 newman doc/luac.1 luac${SLOT}.1