tn3399_openwrt/package
David Thornley da0226fa7e lua: Fixed broken __lt/__le operators caused by lnum patch.
This was found while investigating why luarocks does not work. It was
traced to a quite old lnum patch for 5.1.3. I compared against the
latest 5.1.4 patch - https://github.com/LuaDist/lualnum and discovered
the lessthan/lessequal evaluation was not falling through to the
call_orderTM (tag methods).

I have tested LuCI (simple tests) and used the following lua code to
validate the patch (both host and target patches supplied): -

> local my_mt = {
> __eq = function(v1, v2)
> print("__eq")
> return false
> end,
> __lt = function(v1, v2)
> print("__lt")
> return false
> end,
> __le = function(v1, v2)
> print("__le")
> return false
> end
> }
>
> function get_my(vstring)
> local my = {}
> my.string = vstring;
> setmetatable(my, my_mt);
> return my;
> end
>
> local a = get_my("1.0")
> local b = get_my("1.0")
>
> local eq_works = a == b;
> local lt_works = a < b;
> local gt_works = a > b;
>
> local lte_works = a <= b;
> local gte_works = a >= b;

Without the patch the following error will be presented: -

“attempt to compare two table values”

Signed-off-by: David Thornley <david.thornley@touchstargroup.com>
2016-05-13 17:03:53 +02:00
..
base-files base-files: Fix config_generate when there are no switch VLANs or ports configured in board.json. 2016-05-11 17:06:54 +02:00
boot ramips: add initial support for SamKnows SK-WB8 2016-05-12 03:29:35 +02:00
devel package/devel/gdb: Update to 7.11 2016-03-10 19:11:46 +00:00
firmware package: flag further target specific packages as nonshared 2016-04-26 23:26:43 +02:00
kernel kernel: remove ocf support, cryptodev-linux should be used instead 2016-05-12 19:35:32 +02:00
libs openssl: replace ocf-crypto-headers with a header file from cryptodev-linux 2016-05-12 19:35:32 +02:00
network dropbear: update to 2016.73 2016-05-13 10:23:52 +02:00
system global: change my email address 2016-05-12 03:29:36 +02:00
utils lua: Fixed broken __lt/__le operators caused by lnum patch. 2016-05-13 17:03:53 +02:00
Makefile include: choose package output directory based on repository info 2016-04-06 21:55:44 +02:00