Skip to content

Fix build on ARM and add Travis tests#72

Merged
ViralBShah merged 3 commits intoJuliaMath:masterfrom
talex5:travis
Jan 5, 2015
Merged

Fix build on ARM and add Travis tests#72
ViralBShah merged 3 commits intoJuliaMath:masterfrom
talex5:travis

Conversation

@talex5
Copy link
Copy Markdown
Contributor

@talex5 talex5 commented Jan 5, 2015

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.3 in the .travis.sh file (it's commented out at the moment) then it will run them too, if you want to debug it.

talex5 added 3 commits January 5, 2015 10:35
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
@ViralBShah
Copy link
Copy Markdown
Member

Thanks - I had been meaning to get around to testing this for a while.

@ViralBShah
Copy link
Copy Markdown
Member

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.

ViralBShah added a commit that referenced this pull request Jan 5, 2015
Fix build on ARM and add Travis tests
@ViralBShah ViralBShah merged commit 443e13e into JuliaMath:master Jan 5, 2015
@ViralBShah
Copy link
Copy Markdown
Member

How will it run the ARM tests on an x86 box?

@ViralBShah
Copy link
Copy Markdown
Member

BTW, any idea how to enable the tests for osx? I think I don't fully understand the travis configuration.

@talex5
Copy link
Copy Markdown
Contributor Author

talex5 commented Jan 5, 2015

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.

@tkelman
Copy link
Copy Markdown
Contributor

tkelman commented Jan 5, 2015

@ViralBShah see the Julia repo, you need an os: key. And email support@travis-ci.com to ask for them to enable it on this repository. Various packages have been enabling it recently, apparently the turnaround's not too bad right now http://docs.travis-ci.com/user/multi-os/

@tkelman
Copy link
Copy Markdown
Contributor

tkelman commented Jan 5, 2015

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

@ViralBShah
Copy link
Copy Markdown
Member

Will this do the trick:

language: c
script: ./.travis.sh
os:
    - linux
    - osx
env:
    - TARGET=host
    - TARGET=arm32
matrix:
    exclude:
        - os: osx
        env: TARGET="arm32"
notifications:
    email: false

@tkelman
Copy link
Copy Markdown
Contributor

tkelman commented Jan 6, 2015

I believe so

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants