Skip to content
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

Homebrew problems with building HDF5 (tries to build gcc without a bottle) #237

Open
nickeubank opened this issue Jul 22, 2018 · 7 comments

Comments

@nickeubank
Copy link

@staticfloat

Note sure if this is a problem here or not, but they're claiming in the Homebrew project (here) this is fixed, and HDF5 is claiming it's upstream (here). Any chance problem is in this intermediate link in the chain?

@nickeubank
Copy link
Author

@staticfloat As per your request, ping!

@BoundaryValueProblems
Copy link

BoundaryValueProblems commented Jul 31, 2018

@staticfloat , I have the same problem. Somehow, updating Homebrew.jl ends up compiling gcc-8.2.0 from the source, and takes a huge amount of time to build it. In fact, the compilation failed. Here is the output from my julia session:

Uninstalling gcc... (1,493 files, 349.4MB)
==> Installing gcc from staticfloat/juliatranslated
==> Downloading https://homebrew.bintray.com/bottles/gcc-8.2.0.el_capitan.bottle
######################################################################## 100.0%
==> Pouring gcc-8.2.0.el_capitan.bottle.tar.gz
Error: Failed changing install name in /Users/xxx/.julia/v0.6/Homebrew/deps/usr/Cellar/gcc/8.2.0/lib/gcc/8/i386/libubsan.1.dylib
  from @@HOMEBREW_CELLAR@@/gcc/8.2.0/lib/gcc/8/i386/libstdc++.6.dylib
    to /Users/xxx/.julia/v0.6/Homebrew/deps/usr/Cellar/gcc/8.2.0/lib/gcc/8/i386/libstdc++.6.dylib
Error: Updated load commands do not fit in the header of /Users/xxx/.julia/v0.6/Homebrew/deps/usr/Cellar/gcc/8.2.0/lib/gcc/8/i386/libubsan.1.dylib. /Users/xxx/.julia/v0.6/Homebrew/deps/usr/Cellar/gcc/8.2.0/lib/gcc/8/i386/libubsan.1.dylib needs to be relinked, possibly with -headerpad or -headerpad_max_install_names
Warning: Bottle installation failed: building from source.
==> Downloading https://ftp.gnu.org/gnu/gcc/gcc-8.2.0/gcc-8.2.0.tar.xz
######################################################################## 100.0%
==> ../configure --build=x86_64-apple-darwin15.6.0 --prefix=/Users/xxx/.julia/
==> make

Last 15 lines from /Users/xxx/Library/Logs/Homebrew/gcc/02.make:
                 ^
11 errors generated.
make[3]: *** [graphite-isl-ast-to-gimple.o] Error 1
../../gcc/graphite-optimize-isl.c:58:19: error: use of undeclared identifier 'isl_space_dim'
  unsigned dims = isl_space_dim (space, isl_dim_set);
                  ^
../../gcc/graphite-optimize-isl.c:61:3: error: use of undeclared identifier 'isl_space_free'
  isl_space_free (space);
  ^
2 errors generated.
make[3]: *** [graphite-optimize-isl.o] Error 1
rm gcc.pod
make[2]: *** [all-stage1-gcc] Error 2
make[1]: *** [stage1-bubble] Error 2
make: *** [all] Error 2

Thanks for your help!

@andreasnoack
Copy link
Contributor

See Homebrew/homebrew-core#27751

@nickeubank
Copy link
Author

@andreasnoack Unfortunately they closed that without solving it. See Homebrew/homebrew-core#27751 (comment) . They just said "not our problem".

@BoundaryValueProblems
Copy link

See my comments #245. Somehow, it worked today though it took a long time to build gcc 8.2.0 automatically via Homebrew.jl...

@gideonsimpson
Copy link

I'm having HDF5 issues too on both 0.6.4 and 0.7.0 on MacOS High Sierra. Both are the same sort of error, about a problem with a gmp library:

INFO: Building HDF5
WARNING: Couldn't find bottle stanza in autoconf
==> Installing gmp from staticfloat/juliatranslated
==> Downloading https://homebrew.bintray.com/bottles/gmp-6.1.2_2.high_sierra.bot
Already downloaded: /Users/gideonsimpson/Library/Caches/Homebrew.jl/gmp-6.1.2_2.high_sierra.bottle.tar.gz
==> Pouring gmp-6.1.2_2.high_sierra.bottle.tar.gz
Warning: The post-install step did not complete successfully
You can try again using `brew postinstall staticfloat/juliatranslated/gmp`
==> Summary
🍺  /Users/gideonsimpson/.julia/v0.6/Homebrew/deps/usr/Cellar/gmp/6.1.2_2: 18 files, 3.1MB
================================[ ERROR: HDF5 ]=================================

LoadError: failed process: Process(`/Users/gideonsimpson/.julia/v0.6/Homebrew/deps/usr/bin/brew install --ignore-dependencies staticfloat/juliatranslated/gmp`, ProcessExited(1)) [1]
while loading /Users/gideonsimpson/.julia/v0.6/HDF5/deps/build.jl, in expression starting on line 41

@lewisl
Copy link

lewisl commented Sep 10, 2018

Just install system Homebrew. Install HDF5 at the system level. Then, add the Julia wrapper: Pkg.add("HDF5") (or using the groovy new REPL Pkg: add HDF5). When the Julia wrapper is installed, it DOES find the HDF5 installed in the system level Brew Cellar. I had to do this when Homebrew.add("HDF5") failed in Julia as for the original poster. Installing at the system level, then adding the wrapper worked perfectly. For some reason, the system level brew always tends to be much faster.

This, yet again, shows the problem of forking this kind of infrastructure: the fork has its own problems and can't keep up with the vast amount of work that goes into maintaining Homebrew (also by volunteers--donate!--but more of them). It's not that the idea of a forked, captive Homebrew is so bad--it's ok. It's just extra work that doesn't really need to be done when there aren't enough well-meaning, hard-working arms and legs to do it. By not duplicating, we free up effort to go into cool Julia packages.

It DOES make sense to have special Brew formula for Julia to handle Julia-specific dependencies. The good news is that Homebrew allows this. This contradicts the stated reason for using a private Homebrew instead of the system Homebrew. The Homebrew developers have seen this entirely legitimate need for private dependencies and ways to avoid name conflicts. They solved it.

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

No branches or pull requests

5 participants