Not sure if this is the same, but Mike Nolta and I also had a problem building FITSIO.jl on Travis that we could not reproduce locally on Ubuntu 14.04. We eventually gave up and just used the apt package for cfitsio instead of building it from source.
See https://github.com/JuliaAstro/FITSIO.jl/pull/17 . There’s some noise in that issue, but the root problem for us seemed to be that the generated deps.jl file contained @checked_lib libcfitsio "libcfitsio.so" instead of @checked_lib libcfitsio "actual/path/to/libcfitsio.so" The shared library was built and installed as expected… just the path was wrong. Kyle