fnuecke / eris

Heavy Duty Persistence for Lua 5.2 and 5.3
Other
169 stars 23 forks source link

some lua unit test failures when using `make mingw` with latest eris release (1.1.0-5.3) #18

Closed cbeck88 closed 9 years ago

cbeck88 commented 9 years ago

I have been trying to get all the lua unit tests to pass for my project whether I build for linux native or cross-compile with mingw. I have had some problems with the mingw version -- most likely there are some problems in my projects configuration.

However, in trying to pinpoint it I also found that when I do a default build of eris (1.1.0-5.3) I don't pass all of the lua-5.3.0 unit tests either, when I run through wine.

I am testing using the given make file with make mingw and running the executable through wine. My test script looks like this, if you care:

I am using i686-w64-mingw32-gcc.

#!/bin/bash
#rm -rf eris-1.1.0-5.3/
#tar -xzf eris-1.1.0-5.3.tar.gz
# Must override provided makefile to use the mingw compiler!

cd eris-1.1.0-5.3/
make clean
make mingw
cd src
cp lua.exe ../../
cp lua53.dll ../../
cd ../../lua-5.3.0-tests/
wine ./../lua.exe -e "_port=true" all.lua

The specific tests that I fail are: Some test in strings.lua, apparently related to format %a:

***** FILE 'calls.lua'*****
testing functions and calls
+
+
+
+
.............................................................................................................................................................................................................................................................................................................................................................testing binary chunks
OK
.testing strings and string library
testing 'format %a %A'
Z:\home\chris\eris-5.3-master-tests\lua.exe: strings.lua:231: assertion failed!
stack traceback:
    [C]: in function 'assert'
    strings.lua:231: in main chunk
    [C]: in function 'dofile'
    all.lua:153: in main chunk
    [C]: in ?
.>>> closing state <<<

And I fail some verybig.lua test (but this looks OS-related):

***** FILE 'verybig.lua'*****
testing RK
testing large programs (>64k)
Z:\home\chris\eris-5.3-master-tests\lua.exe: cannot open file '\s8.' (Permission denied)
stack traceback:
    [C]: in function 'io.output'
    ?: in main chunk
    (...tail calls...)
    all.lua:180: in main chunk
    [C]: in ?
.>>> closing state <<<

Anyways I thought maybe it's worth reporting. Do you think I should be worried about any of this?


Edit: For what it's worth, I fiddled around with this some more, the '%a' issue seems to be fixed if I disable it in luaconf.h

//#if !defined(LUA_USE_C89) || defined(LUA_USE_WINDOWS)
//#define LUA_USE_AFORMAT
//#endif

It might just be poor support for the feature or something in my version of mingw? Possibly related SO post

fnuecke commented 9 years ago

Hmm, strings.lua is from the standard Lua test-suite I assume? That's... odd, I don't recall Eris digging into anything on the Lua side that would change runtime behavior.

cbeck88 commented 9 years ago

So, after more investigation, this is what I've found --

So I don't think that either of these are actually eris issues, sorry to bother you :smile:

fnuecke commented 9 years ago

Allright, glad to hear it! :-)