[packages/elinks] - use unversioned system lua and fix build against lua 5.3+ - rel 7

baggins baggins at pld-linux.org
Sun May 9 13:44:18 CEST 2021


commit c35867745220221d073e8f9d7e0cce98f3a2b6f6
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Sun May 9 13:43:40 2021 +0200

    - use unversioned system lua and fix build against lua 5.3+
    - rel 7

 elinks-lua40.patch |  9 ---------
 elinks.spec        |  6 +++---
 lua53.patch        | 11 +++++++++++
 3 files changed, 14 insertions(+), 12 deletions(-)
---
diff --git a/elinks.spec b/elinks.spec
index 73fca9b..b434240 100644
--- a/elinks.spec
+++ b/elinks.spec
@@ -39,7 +39,7 @@ Summary(pt_BR.UTF-8):	O links é um browser para modo texto, similar ao lynx
 Name:		elinks
 Version:	0.13
 %define	snap	20180901
-%define	rel	6
+%define	rel	7
 Release:	4.%{snap}.%{rel}
 Epoch:		1
 License:	GPL v2
@@ -51,7 +51,7 @@ Source0:	http://elinks.cz/download/elinks-current-%{version}.tar.bz2
 Source1:	%{name}.desktop
 Source2:	links.png
 Patch0:		%{name}-home_etc.patch
-Patch1:		%{name}-lua40.patch
+Patch1:		lua53.patch
 Patch2:		%{name}-date-format.patch
 Patch3:		%{name}-old_incremental.patch
 Patch4:		%{name}-0.10.0-0.9.3-typeahead-beginning.patch
@@ -72,7 +72,7 @@ BuildRequires:	gpm-devel
 %{?with_brotli:BuildRequires:	libbrotli-devel}
 %{?with_idn:BuildRequires:	libidn-devel}
 %{?with_smb:BuildRequires:	libsmbclient-devel}
-%{?with_lua:BuildRequires:	lua51-devel >= 5.1}
+%{?with_lua:BuildRequires:	lua-devel >= 5.3}
 %{?with_lzma:BuildRequires:	lzma-devel}
 BuildRequires:	ncurses-devel >= 5.1
 %{?with_openssl:BuildRequires:	openssl-devel >= 0.9.7d}
diff --git a/elinks-lua40.patch b/elinks-lua40.patch
deleted file mode 100644
index 9c03c19..0000000
--- a/elinks-lua40.patch
+++ /dev/null
@@ -1,9 +0,0 @@
-diff -ruN elinks-0.9.1./contrib/lua/bm-to-elinks-bookmarks.lua elinks-0.9.1/contrib/lua/bm-to-elinks-bookmarks.lua
---- elinks-0.9.1./contrib/lua/bm-to-elinks-bookmarks.lua	2002-12-20 22:58:30.000000000 +0100
-+++ elinks-0.9.1/contrib/lua/bm-to-elinks-bookmarks.lua	2004-03-28 19:37:23.903271368 +0200
-@@ -1,4 +1,4 @@
--#!/usr/bin/lua -f
-+#!/usr/bin/lua5.1 -f
- -- Convert bm.lua-format bookmarks to ELinks-format bookmarks.
- -- Peter Wang, 2002-12-19
- 
diff --git a/lua53.patch b/lua53.patch
new file mode 100644
index 0000000..7b56a47
--- /dev/null
+++ b/lua53.patch
@@ -0,0 +1,11 @@
+--- elinks-0.13-20180901/src/scripting/lua/hooks.c~	2021-05-09 13:37:55.000000000 +0200
++++ elinks-0.13-20180901/src/scripting/lua/hooks.c	2021-05-09 13:40:47.132600486 +0200
+@@ -145,7 +145,7 @@
+ 	if (err) return EVENT_HOOK_STATUS_NEXT;
+ 
+ 	if (lua_isstring(L, -1)) {
+-		int len = lua_strlen(L, -1);
++		int len = lua_rawlen(L, -1);
+ 
+ 		add_fragment(cached, 0, (unsigned char *) lua_tostring(L, -1), len);
+ 		normalize_cache_entry(cached, len);
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/elinks.git/commitdiff/c35867745220221d073e8f9d7e0cce98f3a2b6f6



More information about the pld-cvs-commit mailing list