From 4c255d2fca7ce5701b131c701e3ccb0adff1a803 Mon Sep 17 00:00:00 2001 From: Alexander M Pickering Date: Sun, 8 Dec 2024 22:51:09 -0600 Subject: Patch luarocks tar to not require 5.3 --- tar.lua.patch | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 tar.lua.patch (limited to 'tar.lua.patch') diff --git a/tar.lua.patch b/tar.lua.patch new file mode 100644 index 0000000..a94ee3c --- /dev/null +++ b/tar.lua.patch @@ -0,0 +1,18 @@ +diff --git a/src/luarocks/tools/tar.lua b/src/luarocks/tools/tar.lua +index 6db1334a..49139615 100644 +--- a/src/luarocks/tools/tar.lua ++++ b/src/luarocks/tools/tar.lua +@@ -51,11 +51,11 @@ local function octal_to_number(octal) + local number = 0 + octal = octal:gsub("%s", "") + for i = #octal, 1, -1 do +- local digit = math.tointeger(octal:sub(i, i)) ++ local digit = tonumber(octal:sub(i, i)) + if not digit then + break + end +- number = number + (digit * math.tointeger(8 ^ exp)) ++ number = number + (digit * (8 ^ exp)) + exp = exp + 1 + end + return number -- cgit v1.2.3-55-g6feb