Fix build on ARM and add Travis tests#72
Conversation
ARM doesn't have long doubles.
This builds Openlibm on the Travis build host (x86) and also cross-compiles to ARM. Note: the tests currently fail on ARM, as noted in JuliaMath#18
|
Thanks - I had been meaning to get around to testing this for a while. |
|
We really do need much better unit testing for openlibm. I am not a fan of the current tests, but that is better than having nothing. |
Fix build on ARM and add Travis tests
|
How will it run the ARM tests on an x86 box? |
|
BTW, any idea how to enable the tests for osx? I think I don't fully understand the travis configuration. |
|
It uses qemu to run the ARM tests on x86. I think OS X support on Travis is on some kind of limited beta, and not generally available. |
|
@ViralBShah see the Julia repo, you need an |
|
Oh you already did in 769a422, nevermind. You probably want to exclude the arm build for osx, similar to how I did here tkelman/julia@a38da6c |
|
Will this do the trick: |
|
I believe so |
Recent changes had broken the build on ARM by adding more long double functions. These should be skipped on ARM, where double = long double.
This commit also adds Travis CI tests, which can be run automatically on every push to github. To do that, go to https://travis-ci.org/ and enable tests for the repository (it's free). Ideally, do this before merging (it will only run the tests for commits made after enabling it).
Here's the output from my fork (which has tests enabled): https://travis-ci.org/talex5/openlibm/builds/45933733
It does two builds on each commit, one on x86 and one cross-compiling to arm (which would detect the bug fixed above). On x86, it also runs the unit-tests. As the unit-tests currently fail on ARM I have disabled them, but if you set LOADER to
ld-linux-armhf.so.3in the.travis.shfile (it's commented out at the moment) then it will run them too, if you want to debug it.