-
Notifications
You must be signed in to change notification settings - Fork 95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tests are failing for mips64el on Debian #441
Comments
Thank you for the report. I'd like to track down the problem, but don't have access to a suitable machine, and using qemu is painfully slow. |
I compared the generated files from mips64el with files from other architectures (amd64, arm64, mipsel) and they are same. It seems to that the generated bindings and stubs are architecture independent. ocaml-ctypes is compiled with ocamlc 4.02.3 which is about one year old. I have access to mips boards, so, if you have any idea I am willing to try. |
Yes, the generated files are architecture-independent. I suspect the problem lies in a wrong libffi-related assumption -- either an assumption in libffi itself, or an assumption about libffi in ctypes (most probably the latter). If I were debugging it I'd probably start with some of the following:
|
It is fixed. Thanks. |
There are new releases out now (e.g. 0.10.1) with the fix. |
The build of ocaml-ctypes is failing for mips64el on Debian with the following message:
full log: https://buildd.debian.org/status/fetch.php?pkg=ocaml-ctypes&arch=mips64el&ver=0.7.0-1&stamp=1470056946
Test is failing on:
assert_equal 1 (higher_order_1 min (-3) 0)
After debugging I have found the following:
higher_order_1 function from tests/clib/test_functions.c is returning 0 for callback(0, -3) == 0 + (-3)
In this test case the callback is min.
The comparison between min(0, -3) and 0 + (-3) equals 0 because callback(0, -3) is returning a positive number.
I compared min(0, -3) with zero to check is it positive or negative.
I did the same thing on mipsel and the result was negative as expected. All tests are passing.
This bug shows up only for mips64el.
Do you have any idea why is this happening?
I was able to fix this issue by modifying the function.
With this workaround the package still fails on testing. It is failing on test-cstdlib (qsort and bsearch).
Any advice will be useful.
The text was updated successfully, but these errors were encountered: