Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package lua-compat-5.3 for openSUSE:Factory 
checked in at 2025-10-27 14:37:11
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/lua-compat-5.3 (Old)
 and      /work/SRC/openSUSE:Factory/.lua-compat-5.3.new.1980 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "lua-compat-5.3"

Mon Oct 27 14:37:11 2025 rev:14 rq:1313522 version:unknown

Changes:
--------
--- /work/SRC/openSUSE:Factory/lua-compat-5.3/lua-compat-5.3.changes    
2024-07-25 15:48:30.173562944 +0200
+++ /work/SRC/openSUSE:Factory/.lua-compat-5.3.new.1980/lua-compat-5.3.changes  
2025-10-27 14:37:12.912239641 +0100
@@ -1,0 +2,29 @@
+Fri Oct 24 14:47:30 UTC 2025 - Matej Cepl <[email protected]>
+
+- Switch off building lua51 build of the package.
+
+-------------------------------------------------------------------
+Fri Oct 17 20:34:32 UTC 2025 - Matej Cepl <[email protected]>
+
+- Update to 0.14.4:
+  - prevent loops when loading files within require (e.g. with a
+    custom package loader)
+- Update to 0.14.3:
+  - win32: fix detection for mingw32
+  - revert change in tolstream
+- Update to 0.14.2:
+  - fix: return third result in file-opening functions
+- Update to 0.14.1:
+  - avoid MSVC build error
+- Update to 0.14:
+  - fix: math.tointeger accepts strings convertible to integers
+  - adjust file metatables for LuaJIT built with 5.2 compat
+    disabled, even in compat53.module mode
+
+-------------------------------------------------------------------
+Fri Oct 10 10:37:25 UTC 2025 - Matej Cepl <[email protected]>
+
+- Fix building on LuaJIT (don’t rely on the version number)
+- Add rpmlintrc
+
+-------------------------------------------------------------------

Old:
----
  lua-compat-5.3-0.13.tar.gz

New:
----
  _scmsync.obsinfo
  build.specials.obscpio
  lua-compat-5.3-0.14.4.tar.gz
  lua-compat-5.3.rpmlintrc

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ lua-compat-5.3.spec ++++++
--- /var/tmp/diff_new_pack.qtmxSv/_old  2025-10-27 14:37:14.720315986 +0100
+++ /var/tmp/diff_new_pack.qtmxSv/_new  2025-10-27 14:37:14.724316155 +0100
@@ -25,7 +25,7 @@
 %else
 %bcond_without bit32
 %endif
-%define mversion 0.13
+%define mversion 0.14.4
 %define bit32_version 5.3.5.1
 Version:        %{mversion}
 Release:        0
@@ -33,7 +33,8 @@
 License:        MIT
 Group:          Development/Libraries/Other
 URL:            https://github.com/lunarmodules/lua-compat-5.3
-Source:         
https://github.com/lunarmodules/lua-compat-5.3/archive/v%{version}.tar.gz#$/%{mod_name}-%{version}.tar.gz
+Source0:        
https://github.com/lunarmodules/lua-compat-5.3/archive/v%{version}.tar.gz#$/%{mod_name}-%{version}.tar.gz
+Source99:       lua-compat-5.3.rpmlintrc
 BuildRequires:  %{flavor}-devel
 BuildRequires:  lua-macros
 BuildRequires:  pkgconfig
@@ -71,7 +72,7 @@
 %autosetup -n %{mod_name}-%{mversion}
 
 %build
-export CC="${COMPILER:-gcc}" DEF="" SRC="" CFLAGS="-Wall -Wextra $(pkg-config 
--cflags lua%{lua_version}) -Ic-api -O2 -fPIC"
+export CC="${COMPILER:-gcc}" DEF="" SRC="" CFLAGS="-Wall -Wextra $(pkg-config 
--cflags lua) -Ic-api -O2 -fPIC"
 if [ "x${EXTERNAL:-}" = xtrue ]; then
     export DEF="-DCOMPAT53_PREFIX=compat53" SRC="c-api/compat-5.3.c"
 fi

++++++ _multibuild ++++++
--- /var/tmp/diff_new_pack.qtmxSv/_old  2025-10-27 14:37:14.788318857 +0100
+++ /var/tmp/diff_new_pack.qtmxSv/_new  2025-10-27 14:37:14.804319533 +0100
@@ -1,5 +1,5 @@
 <multibuild>
-<package>lua51</package>
+<package>luajit</package>
 <package>lua53</package>
 <package>lua54</package>
 </multibuild>

++++++ _scmsync.obsinfo ++++++
mtime: 1761317251
commit: 89a6ab1ffcf03b48c7a8caef8712a2e083232ff29c9940c3c9557d21e117f650
url: https://src.opensuse.org/lua/lua-compat-5.3.git
revision: 89a6ab1ffcf03b48c7a8caef8712a2e083232ff29c9940c3c9557d21e117f650
projectscmsync: https://src.opensuse.org/lua/_ObsPrj.git

++++++ build.specials.obscpio ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/.gitignore new/.gitignore
--- old/.gitignore      1970-01-01 01:00:00.000000000 +0100
+++ new/.gitignore      2025-10-24 16:47:40.000000000 +0200
@@ -0,0 +1 @@
+.osc

++++++ lua-compat-5.3-0.13.tar.gz -> lua-compat-5.3-0.14.4.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lua-compat-5.3-0.13/compat53/file_mt.lua 
new/lua-compat-5.3-0.14.4/compat53/file_mt.lua
--- old/lua-compat-5.3-0.13/compat53/file_mt.lua        1970-01-01 
01:00:00.000000000 +0100
+++ new/lua-compat-5.3-0.14.4/compat53/file_mt.lua      2025-01-23 
10:27:33.000000000 +0100
@@ -0,0 +1,71 @@
+local lua_version = _VERSION:sub(-3)
+
+local M = {}
+
+local unpack = lua_version == "5.1" and unpack or table.unpack
+
+local function addasterisk(fmt)
+   if type(fmt) == "string" and fmt:sub(1, 1) ~= "*" then
+      return "*"..fmt
+   else
+      return fmt
+   end
+end
+
+function M.update_file_meta(file_meta, is_luajit52)
+
+   -- make '*' optional for file:read and file:lines
+
+   local file_lines = file_meta.__index.lines
+   file_meta.__index.lines = function(self, ...)
+      local n = select('#', ...)
+      for i = 1, n do
+         local a = select(i, ...)
+         local b = addasterisk(a)
+         -- as an optimization we only allocate a table for the
+         -- modified format arguments when we have a '*' somewhere
+         if a ~= b then
+            local args = { ... }
+            args[i] = b
+            for j = i+1, n do
+               args[j] = addasterisk(args[j])
+            end
+            return file_lines(self, unpack(args, 1, n))
+         end
+      end
+      return file_lines(self, ...)
+   end
+
+   local file_read = file_meta.__index.read
+   file_meta.__index.read = function(self, ...)
+      local n = select('#', ...)
+      for i = 1, n do
+         local a = select(i, ...)
+         local b = addasterisk(a)
+         -- as an optimization we only allocate a table for the
+         -- modified format arguments when we have a '*' somewhere
+         if a ~= b then
+            local args = { ... }
+            args[i] = b
+            for j = i+1, n do
+               args[j] = addasterisk(args[j])
+            end
+            return file_read(self, unpack(args, 1, n))
+         end
+      end
+      return file_read(self, ...)
+   end
+
+   if not is_luajit52 then
+      local file_write = file_meta.__index.write
+      file_meta.__index.write = function(self, ...)
+         local ret, err = file_write(self, ...)
+         if ret then
+            return self
+         end
+         return ret, err
+      end
+   end
+end
+
+return M
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lua-compat-5.3-0.13/compat53/init.lua 
new/lua-compat-5.3-0.14.4/compat53/init.lua
--- old/lua-compat-5.3-0.13/compat53/init.lua   2024-02-24 01:06:44.000000000 
+0100
+++ new/lua-compat-5.3-0.14.4/compat53/init.lua 2025-01-23 10:27:33.000000000 
+0100
@@ -17,57 +17,15 @@
    local file_meta = gmt(io.stdout)
 
 
-   -- make '*' optional for file:read and file:lines
-   if type(file_meta) == "table" and type(file_meta.__index) == "table" then
+   -- detect LuaJIT (including LUAJIT_ENABLE_LUA52COMPAT compilation flag)
+   local is_luajit = (string.dump(function() end) or ""):sub(1, 3) == "\027LJ"
+   local is_luajit52 = is_luajit and
+     #setmetatable({}, { __len = function() return 1 end }) == 1
 
-      local function addasterisk(fmt)
-         if type(fmt) == "string" and fmt:sub(1, 1) ~= "*" then
-            return "*"..fmt
-         else
-            return fmt
-         end
-      end
-
-      local file_lines = file_meta.__index.lines
-      file_meta.__index.lines = function(self, ...)
-         local n = select('#', ...)
-         for i = 1, n do
-            local a = select(i, ...)
-            local b = addasterisk(a)
-            -- as an optimization we only allocate a table for the
-            -- modified format arguments when we have a '*' somewhere
-            if a ~= b then
-               local args = { ... }
-               args[i] = b
-               for j = i+1, n do
-                  args[j] = addasterisk(args[j])
-               end
-               return file_lines(self, unpack(args, 1, n))
-            end
-         end
-         return file_lines(self, ...)
-      end
-
-      local file_read = file_meta.__index.read
-      file_meta.__index.read = function(self, ...)
-         local n = select('#', ...)
-         for i = 1, n do
-            local a = select(i, ...)
-            local b = addasterisk(a)
-            -- as an optimization we only allocate a table for the
-            -- modified format arguments when we have a '*' somewhere
-            if a ~= b then
-               local args = { ... }
-               args[i] = b
-               for j = i+1, n do
-                  args[j] = addasterisk(args[j])
-               end
-               return file_read(self, unpack(args, 1, n))
-            end
-         end
-         return file_read(self, ...)
-      end
 
+   if type(file_meta) == "table" and type(file_meta.__index) == "table" then
+      local file_mt = require("compat53.file_mt")
+      file_mt.update_file_meta(file_meta, is_luajit52)
    end -- got a valid metatable for file objects
 
 
@@ -85,12 +43,6 @@
       local io_type = io.type
 
 
-      -- detect LuaJIT (including LUAJIT_ENABLE_LUA52COMPAT compilation flag)
-      local is_luajit = (string.dump(function() end) or ""):sub(1, 3) == 
"\027LJ"
-      local is_luajit52 = is_luajit and
-        #setmetatable({}, { __len = function() return 1 end }) == 1
-
-
       -- make package.searchers available as an alias for package.loaders
       local p_index = { searchers = package.loaders }
       setmetatable(package, {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lua-compat-5.3-0.13/compat53/module.lua 
new/lua-compat-5.3-0.14.4/compat53/module.lua
--- old/lua-compat-5.3-0.13/compat53/module.lua 2024-02-24 01:06:44.000000000 
+0100
+++ new/lua-compat-5.3-0.14.4/compat53/module.lua       2025-01-23 
10:27:33.000000000 +0100
@@ -13,7 +13,11 @@
          debug, io, math, package, string, table
    local io_lines = io.lines
    local io_read = io.read
+   local io_open = io.open
+   local io_popen = io.popen
+   local io_tmpfile = io.tmpfile
    local unpack = lua_version == "5.1" and unpack or table.unpack
+   local debug_setmetatable = type(debug) == "table" and debug.setmetatable
 
    -- create module table
    M = {}
@@ -115,6 +119,7 @@
       M.math.mininteger = minint
 
       function M.math.tointeger(n)
+         n = tonumber(n)
          if type(n) == "number" and n <= maxint and n >= minint and n % 1 == 0 
then
             return n
          end
@@ -450,7 +455,6 @@
       if type(debug) == "table" then
          local debug_setfenv = debug.setfenv
          local debug_getfenv = debug.getfenv
-         local debug_setmetatable = debug.setmetatable
 
          M.debug = setmetatable({}, { __index = debug })
 
@@ -822,6 +826,60 @@
          end
       end -- not luajit
 
+      if is_luajit then
+         local compat_file_meta = {}
+         local compat_file_meta_loaded = 0
+
+         local function load_compat_file_meta(file_meta)
+            -- fill compat_file_meta with original entries
+            for k, v in pairs(file_meta) do
+               compat_file_meta[k] = v
+            end
+            compat_file_meta.__index = {}
+            for k, v in pairs(file_meta.__index) do
+               compat_file_meta.__index[k] = v
+            end
+
+            compat_file_meta_loaded = 1
+
+            -- update it with compatibility functions
+            local file_mt_ok, file_mt = pcall(require, "compat53.file_mt")
+            if file_mt_ok then
+               file_mt.update_file_meta(compat_file_meta, is_luajit52)
+
+               compat_file_meta_loaded = 2
+            end
+         end
+
+         local function return_fd(fd, err, code)
+            if not fd then
+               return fd, err, code
+            end
+            if fd and debug_setmetatable then
+               if compat_file_meta_loaded == 0 then
+                  local file_meta = gmt(fd)
+                  load_compat_file_meta(file_meta)
+               end
+               if compat_file_meta_loaded == 2 then
+                  debug_setmetatable(fd, compat_file_meta)
+               end
+            end
+            return fd
+         end
+
+         function M.io.open(...)
+            return return_fd(io_open(...))
+         end
+
+         function M.io.popen(...)
+            return return_fd(io_popen(...))
+         end
+
+         function M.io.tmpfile(...)
+            return return_fd(io_tmpfile(...))
+         end
+      end
+
    end -- lua 5.1
 
    -- further write should be forwarded to _G
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lua-compat-5.3-0.13/lprefix.h 
new/lua-compat-5.3-0.14.4/lprefix.h
--- old/lua-compat-5.3-0.13/lprefix.h   2024-02-24 01:06:44.000000000 +0100
+++ new/lua-compat-5.3-0.14.4/lprefix.h 2025-01-23 10:27:33.000000000 +0100
@@ -195,6 +195,9 @@
 #  endif
 
 /* choose which popen implementation to pick */
+#  if (defined(_WIN32) && !defined(__CYGWIN__))
+#    define LUA_USE_WINDOWS 1
+#  endif
 #  if (!defined(LUA_USE_WINDOWS) && !defined(LUA_USE_POSIX)) && \
       ((defined(_POSIX_C_SOURCE) && _POSIX_C_SOURCE >= 200112L) || \
        (defined(_XOPEN_SOURCE) && _XOPEN_SOURCE >= 600) || \
@@ -242,13 +245,17 @@
 #  undef LUA_FILEHANDLE
 #  define LUA_FILEHANDLE COMPAT53_LUA_PFILEHANDLE
 
+LUAMOD_API int luaopen_compat53_io (lua_State *L) {
+  luaL_Reg const funcs[] = {
+
 /* for PUC-Rio Lua 5.1 only */
 #  if defined(LUA_VERSION_NUM) && LUA_VERSION_NUM == 501 && 
!defined(LUA_JITLIBNAME)
 
-LUAMOD_API int luaopen_compat53_io (lua_State *L) {
-  luaL_Reg const funcs[] = {
     { "popen", io_popen },
     { "type", io_ptype },
+
+#  endif /* for PUC-Rio Lua 5.1 only */
+
     { NULL, NULL }
   };
   luaL_newlib(L, funcs);
@@ -256,7 +263,6 @@
   return 1;
 }
 
-#  endif /* for PUC-Rio Lua 5.1 only */
 
 /* fake CLANG feature detection on other compilers */
 #  ifndef __has_attribute
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/lua-compat-5.3-0.13/rockspecs/compat53-0.14-1.rockspec 
new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14-1.rockspec
--- old/lua-compat-5.3-0.13/rockspecs/compat53-0.14-1.rockspec  1970-01-01 
01:00:00.000000000 +0100
+++ new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14-1.rockspec        
2025-01-23 10:27:33.000000000 +0100
@@ -0,0 +1,33 @@
+package = "compat53"
+version = "0.14-1"
+source = {
+   url = "https://github.com/lunarmodules/lua-compat-5.3/archive/v0.14.zip";,
+   dir = "lua-compat-5.3-0.14"
+}
+description = {
+   summary = "Compatibility module providing Lua-5.3-style APIs for Lua 5.2 
and 5.1",
+   detailed = [[
+      This is a small module that aims to make it easier to write Lua
+      code in a Lua-5.3-style that runs on Lua 5.1+.
+      It does *not* make Lua 5.2 (or even 5.1) entirely compatible
+      with Lua 5.3, but it brings the API closer to that of Lua 5.3.
+   ]],
+   homepage = "https://github.com/lunarmodules/lua-compat-5.3";,
+   license = "MIT"
+}
+dependencies = {
+   "lua >= 5.1, < 5.5"
+   --"struct" -- make Roberto's struct module optional
+}
+build = {
+   type = "builtin",
+   modules = {
+      ["compat53.file_mt"] = "compat53/file_mt.lua",
+      ["compat53.init"] = "compat53/init.lua",
+      ["compat53.io"] = "liolib.c",
+      ["compat53.module"] = "compat53/module.lua",
+      ["compat53.string"] = "lstrlib.c",
+      ["compat53.table"] = "ltablib.c",
+      ["compat53.utf8"] = "lutf8lib.c"
+   }
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/lua-compat-5.3-0.13/rockspecs/compat53-0.14.1-1.rockspec 
new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14.1-1.rockspec
--- old/lua-compat-5.3-0.13/rockspecs/compat53-0.14.1-1.rockspec        
1970-01-01 01:00:00.000000000 +0100
+++ new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14.1-1.rockspec      
2025-01-23 10:27:33.000000000 +0100
@@ -0,0 +1,33 @@
+package = "compat53"
+version = "0.14.1-1"
+source = {
+   url = "https://github.com/lunarmodules/lua-compat-5.3/archive/v0.14.1.zip";,
+   dir = "lua-compat-5.3-0.14.1"
+}
+description = {
+   summary = "Compatibility module providing Lua-5.3-style APIs for Lua 5.2 
and 5.1",
+   detailed = [[
+      This is a small module that aims to make it easier to write Lua
+      code in a Lua-5.3-style that runs on Lua 5.1+.
+      It does *not* make Lua 5.2 (or even 5.1) entirely compatible
+      with Lua 5.3, but it brings the API closer to that of Lua 5.3.
+   ]],
+   homepage = "https://github.com/lunarmodules/lua-compat-5.3";,
+   license = "MIT"
+}
+dependencies = {
+   "lua >= 5.1, < 5.5"
+   --"struct" -- make Roberto's struct module optional
+}
+build = {
+   type = "builtin",
+   modules = {
+      ["compat53.file_mt"] = "compat53/file_mt.lua",
+      ["compat53.init"] = "compat53/init.lua",
+      ["compat53.io"] = "liolib.c",
+      ["compat53.module"] = "compat53/module.lua",
+      ["compat53.string"] = "lstrlib.c",
+      ["compat53.table"] = "ltablib.c",
+      ["compat53.utf8"] = "lutf8lib.c"
+   }
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/lua-compat-5.3-0.13/rockspecs/compat53-0.14.2-1.rockspec 
new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14.2-1.rockspec
--- old/lua-compat-5.3-0.13/rockspecs/compat53-0.14.2-1.rockspec        
1970-01-01 01:00:00.000000000 +0100
+++ new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14.2-1.rockspec      
2025-01-23 10:27:33.000000000 +0100
@@ -0,0 +1,32 @@
+package = "compat53"
+version = "0.14.2-1"
+source = {
+   url = "https://github.com/lunarmodules/lua-compat-5.3/archive/v0.14.2.zip";,
+   dir = "lua-compat-5.3-0.14.2"
+}
+description = {
+   summary = "Compatibility module providing Lua-5.3-style APIs for Lua 5.2 
and 5.1",
+   detailed = [[
+      This is a small module that aims to make it easier to write Lua
+      code in a Lua-5.3-style that runs on Lua 5.1+.
+      It does *not* make Lua 5.2 (or even 5.1) entirely compatible
+      with Lua 5.3, but it brings the API closer to that of Lua 5.3.
+   ]],
+   homepage = "https://github.com/lunarmodules/lua-compat-5.3";,
+   license = "MIT"
+}
+dependencies = {
+   "lua >= 5.1, < 5.5"
+}
+build = {
+   type = "builtin",
+   modules = {
+      ["compat53.file_mt"] = "compat53/file_mt.lua",
+      ["compat53.init"] = "compat53/init.lua",
+      ["compat53.io"] = "liolib.c",
+      ["compat53.module"] = "compat53/module.lua",
+      ["compat53.string"] = "lstrlib.c",
+      ["compat53.table"] = "ltablib.c",
+      ["compat53.utf8"] = "lutf8lib.c"
+   }
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/lua-compat-5.3-0.13/rockspecs/compat53-0.14.3-1.rockspec 
new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14.3-1.rockspec
--- old/lua-compat-5.3-0.13/rockspecs/compat53-0.14.3-1.rockspec        
1970-01-01 01:00:00.000000000 +0100
+++ new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14.3-1.rockspec      
2025-01-23 10:27:33.000000000 +0100
@@ -0,0 +1,32 @@
+package = "compat53"
+version = "0.14.3-1"
+source = {
+   url = "https://github.com/lunarmodules/lua-compat-5.3/archive/v0.14.3.zip";,
+   dir = "lua-compat-5.3-0.14.3"
+}
+description = {
+   summary = "Compatibility module providing Lua-5.3-style APIs for Lua 5.2 
and 5.1",
+   detailed = [[
+      This is a small module that aims to make it easier to write Lua
+      code in a Lua-5.3-style that runs on Lua 5.1+.
+      It does *not* make Lua 5.2 (or even 5.1) entirely compatible
+      with Lua 5.3, but it brings the API closer to that of Lua 5.3.
+   ]],
+   homepage = "https://github.com/lunarmodules/lua-compat-5.3";,
+   license = "MIT"
+}
+dependencies = {
+   "lua >= 5.1, < 5.5"
+}
+build = {
+   type = "builtin",
+   modules = {
+      ["compat53.file_mt"] = "compat53/file_mt.lua",
+      ["compat53.init"] = "compat53/init.lua",
+      ["compat53.io"] = "liolib.c",
+      ["compat53.module"] = "compat53/module.lua",
+      ["compat53.string"] = "lstrlib.c",
+      ["compat53.table"] = "ltablib.c",
+      ["compat53.utf8"] = "lutf8lib.c"
+   }
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/lua-compat-5.3-0.13/rockspecs/compat53-0.14.4-1.rockspec 
new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14.4-1.rockspec
--- old/lua-compat-5.3-0.13/rockspecs/compat53-0.14.4-1.rockspec        
1970-01-01 01:00:00.000000000 +0100
+++ new/lua-compat-5.3-0.14.4/rockspecs/compat53-0.14.4-1.rockspec      
2025-01-23 10:27:33.000000000 +0100
@@ -0,0 +1,32 @@
+package = "compat53"
+version = "0.14.4-1"
+source = {
+   url = "https://github.com/lunarmodules/lua-compat-5.3/archive/v0.14.4.zip";,
+   dir = "lua-compat-5.3-0.14.4"
+}
+description = {
+   summary = "Compatibility module providing Lua-5.3-style APIs for Lua 5.2 
and 5.1",
+   detailed = [[
+      This is a small module that aims to make it easier to write Lua
+      code in a Lua-5.3-style that runs on Lua 5.1+.
+      It does *not* make Lua 5.2 (or even 5.1) entirely compatible
+      with Lua 5.3, but it brings the API closer to that of Lua 5.3.
+   ]],
+   homepage = "https://github.com/lunarmodules/lua-compat-5.3";,
+   license = "MIT"
+}
+dependencies = {
+   "lua >= 5.1, < 5.5"
+}
+build = {
+   type = "builtin",
+   modules = {
+      ["compat53.file_mt"] = "compat53/file_mt.lua",
+      ["compat53.init"] = "compat53/init.lua",
+      ["compat53.io"] = "liolib.c",
+      ["compat53.module"] = "compat53/module.lua",
+      ["compat53.string"] = "lstrlib.c",
+      ["compat53.table"] = "ltablib.c",
+      ["compat53.utf8"] = "lutf8lib.c"
+   }
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/lua-compat-5.3-0.13/rockspecs/compat53-scm-0.rockspec 
new/lua-compat-5.3-0.14.4/rockspecs/compat53-scm-0.rockspec
--- old/lua-compat-5.3-0.13/rockspecs/compat53-scm-0.rockspec   2024-02-24 
01:06:44.000000000 +0100
+++ new/lua-compat-5.3-0.14.4/rockspecs/compat53-scm-0.rockspec 1970-01-01 
01:00:00.000000000 +0100
@@ -1,33 +0,0 @@
-package = "compat53"
-version = "scm-0"
-source = {
-   url = "https://github.com/lunarmodules/lua-compat-5.3/archive/master.zip";,
-   dir = "lua-compat-5.3-master",
-}
-description = {
-   summary = "Compatibility module providing Lua-5.3-style APIs for Lua 5.2 
and 5.1",
-   detailed = [[
-      This is a small module that aims to make it easier to write Lua
-      code in a Lua-5.3-style that runs on Lua 5.1+.
-      It does *not* make Lua 5.2 (or even 5.1) entirely compatible
-      with Lua 5.3, but it brings the API closer to that of Lua 5.3.
-   ]],
-   homepage = "https://github.com/lunarmodules/lua-compat-5.3";,
-   license = "MIT"
-}
-dependencies = {
-   "lua >= 5.1, < 5.5",
-   --"struct" -- make Roberto's struct module optional
-}
-build = {
-   type = "builtin",
-   modules = {
-      ["compat53.init"] = "compat53/init.lua",
-      ["compat53.module"] = "compat53/module.lua",
-      ["compat53.utf8"] = "lutf8lib.c",
-      ["compat53.table"] = "ltablib.c",
-      ["compat53.string"] = "lstrlib.c",
-      ["compat53.io"] = "liolib.c",
-   }
-}
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/lua-compat-5.3-0.13/rockspecs/compat53-scm-1.rockspec 
new/lua-compat-5.3-0.14.4/rockspecs/compat53-scm-1.rockspec
--- old/lua-compat-5.3-0.13/rockspecs/compat53-scm-1.rockspec   1970-01-01 
01:00:00.000000000 +0100
+++ new/lua-compat-5.3-0.14.4/rockspecs/compat53-scm-1.rockspec 2025-01-23 
10:27:33.000000000 +0100
@@ -0,0 +1,34 @@
+package = "compat53"
+version = "scm-1"
+source = {
+   url = "https://github.com/lunarmodules/lua-compat-5.3/archive/master.zip";,
+   dir = "lua-compat-5.3-master",
+}
+description = {
+   summary = "Compatibility module providing Lua-5.3-style APIs for Lua 5.2 
and 5.1",
+   detailed = [[
+      This is a small module that aims to make it easier to write Lua
+      code in a Lua-5.3-style that runs on Lua 5.1+.
+      It does *not* make Lua 5.2 (or even 5.1) entirely compatible
+      with Lua 5.3, but it brings the API closer to that of Lua 5.3.
+   ]],
+   homepage = "https://github.com/lunarmodules/lua-compat-5.3";,
+   license = "MIT"
+}
+dependencies = {
+   "lua >= 5.1, < 5.5",
+   --"struct" -- make Roberto's struct module optional
+}
+build = {
+   type = "builtin",
+   modules = {
+      ["compat53.init"] = "compat53/init.lua",
+      ["compat53.module"] = "compat53/module.lua",
+      ["compat53.file_mt"] = "compat53/file_mt.lua",
+      ["compat53.utf8"] = "lutf8lib.c",
+      ["compat53.table"] = "ltablib.c",
+      ["compat53.string"] = "lstrlib.c",
+      ["compat53.io"] = "liolib.c",
+   }
+}
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lua-compat-5.3-0.13/tests/test.lua 
new/lua-compat-5.3-0.14.4/tests/test.lua
--- old/lua-compat-5.3-0.13/tests/test.lua      2024-02-24 01:06:44.000000000 
+0100
+++ new/lua-compat-5.3-0.14.4/tests/test.lua    2025-01-23 10:27:33.000000000 
+0100
@@ -36,6 +36,8 @@
 local V = _VERSION:gsub("^.*(%d+)%.(%d+)$", "%1%2")
 if jit then V = "jit" end
 
+local is_puclua51 = (_VERSION == "Lua 5.1" and not jit)
+
 local mode = "global"
 if arg[1] == "module" then
   mode = "module"
@@ -228,6 +230,7 @@
 ___''
 print("math.tointeger", math.tointeger(0))
 print("math.tointeger", math.tointeger(math.pi))
+print("math.tointeger", math.tointeger("123"))
 print("math.tointeger", math.tointeger("hello"))
 print("math.tointeger", math.tointeger(math.maxinteger+2.0))
 print("math.tointeger", math.tointeger(math.mininteger*2.0))
@@ -575,7 +578,7 @@
 do
    print("io.write()", io.type(io.write("hello world\n")))
    local f = assert(io.tmpfile())
-   print("file:write()", io.type(f:write("hello world\n")))
+   print("io.tmpfile => file:write()", io.type(f:write("hello world\n")))
    f:close()
 end
 
@@ -588,13 +591,18 @@
    io.input("data.txt")
    print("io.read()", io.read("n", "number", "l", "a"))
    io.input(io.stdin)
-   if mode ~= "module" then
-     local f = assert(io.open("data.txt", "r"))
-     print("file:read()", f:read("*n", "*number", "*l", "*a"))
-     f:close()
-     f = assert(io.open("data.txt", "r"))
-     print("file:read()", f:read("n", "number", "l", "a"))
-     f:close()
+   if not is_puclua51 then
+      local f = assert(io.open("data.txt", "r"))
+      print("file:read()", f:read("*n", "*number", "*l", "*a"))
+      f:close()
+      f = assert(io.open("data.txt", "r"))
+      print("file:read()", f:read("n", "number", "l", "a"))
+      f:close()
+      os.remove("data.txt")
+
+      local g = assert(io.open("data.txt", "w"))
+      print("io.open => file:write()", type(g:write("hello")))
+      g:close()
    end
    os.remove("data.txt")
 end

++++++ lua-compat-5.3.rpmlintrc ++++++
addFilter("W: no-%check-section")
addFilter("E: devel-file-in-non-devel-package.*/usr/include/")

Reply via email to