mweastwood / LibHealpix.jl

A Julia wrapper of the Healpix library.
http://mweastwood.info/LibHealpix.jl/stable/
Other
11 stars 7 forks source link

Build the package in OSX #11

Closed pochoi closed 8 years ago

pochoi commented 8 years ago

Refer to the issue #10. It is a minimal fix for building the package in OSX. I just change some types and paths so that it is more robust to different performs.

One needs to build the package with a working GNU gcc/g++ linked to default gcc and g++. To do it, a simple way is to use Homebrew. Install GNU gcc/g++ in Homebrew. Create symlinks (since Homebrew would name the gcc/g++ binary with the versions installed, say, gcc-5 or gcc-4.9). Make sure the directory for packages installed by Homebrew is at the front of PATH.

brew install gcc
ln -s /usr/local/bin/gcc-5 /usr/local/bin/gcc
ln -s /usr/local/bin/g++-5 /usr/local/bin/g++
export PATH=/usr/local/bin:$PATH

I put similar codes in .travis.yml so that it works in the Travis-CI build in OSX. Travis-CI's OSX already has gcc-4.9 installed with Homebrew. So I just make the symlinks and PATH.

It is far from ideal, though. I believe the package should be able to build with Clang.

mweastwood commented 8 years ago

Awesome this is very nice. Thanks for the pull request.

Do issues #12 and #13 now cover the remaining issues discussed in #10?

pochoi commented 8 years ago

Thanks!

The package is not working on the OSX, I guess, because the hard-coded configure files does not work in Clang. It would be awesome to make building script works in Clang.