Graphviz failed to build on 10.8 #15905

Closed
dlo opened this Issue Nov 7, 2012 · 25 comments

Comments

Projects
None yet
5 participants
Contributor

dlo commented Nov 7, 2012

This has been verified on another installation of Homebrew, so this isn't specific to my install.

$ brew install graphviz
==> Downloading http://www.graphviz.org/pub/graphviz/stable/SOURCES/graphviz-2.28.0.tar.gz
Already downloaded: /Library/Caches/Homebrew/graphviz-2.28.0.tar.gz
==> Downloading patches
######################################################################## 100.0%
==> Patching
patching file lib/gvc/Makefile.in
patching file plugin/quartz/Makefile.in
patching file macosx/graphviz.xcodeproj/project.pbxproj
==> ./configure --prefix=/usr/local/Cellar/graphviz/2.28.0 --without-qt --with-quartz --disable-swig --without-pangocairo
==> make install
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[3]: *** [libgvplugin_gd.la] Error 1
make[2]: *** [install-recursive] Error 1
make[1]: *** [install-recursive] Error 1
make: *** [install] Error 2
Contributor

2bits commented Nov 9, 2012

works for me

Contributor

dlo commented Nov 9, 2012

Just tried again (after updating homebrew), still failing. :-/

Contributor

2bits commented Nov 9, 2012

If you want to gist some logs, follow the troubleshooting wiki, and include your brew doctor and brew --config outputs. Thanks.

Contributor

dlo commented Nov 9, 2012

Contributor

2bits commented Nov 9, 2012

You seem to have 80 unlinked kegs. Please explain.

Contributor

dlo commented Nov 9, 2012

I have no idea what I can explain. I just use homebrew as any normal user would, running brew install XYZ when I need things, and running brew link X when it says it needs to link something. Not sure what else I can say.

Contributor

dlo commented Nov 9, 2012

Is there a command I can run to link all my unlinked kegs?

Contributor

jacknagel commented Nov 9, 2012

Copy the list to the clipboard, run pbpaste | xargs brew link

Contributor

dlo commented Nov 9, 2012

$ pbpaste | xargs brew link
Error: ack has multiple installed versions
Contributor

dlo commented Nov 9, 2012

😢

Contributor

dlo commented Nov 9, 2012

If I then remove ack from the list, I see this:

$ pbpaste | xargs brew link
Error: cabextract has multiple installed versions

This is a separate issue, but there should probably be a built in command for this.

Contributor

dlo commented Nov 9, 2012

Strangely enough, graphviz is in that list of unbrewed kegs.

Contributor

dlo commented Nov 9, 2012

$ brew link graphviz
Linking /usr/local/Cellar/graphviz/2.26.3... 328 symlinks created

I am really confused right now. Actually, now I remember, I unlinked when it told me I had to when trying to install the updated version. So back to square one.

Contributor

dlo commented Nov 9, 2012

$ for i in `pbpaste`; do brew link $i; done

is working like a charm. I'll post back here when it finishes.

Contributor

dlo commented Nov 9, 2012

Here is my updated brew doctor: https://gist.github.com/4048525

Contributor

2bits commented Nov 9, 2012

Join the club :-)

Contributor

2bits commented Nov 9, 2012

You may just want to wipe /usr/local and start again. Often it's quicker than trying to fix things, but it's up to you. We could try to debug this more, but it's not obvious that anything is wrong. You can link each one of those excluding ones that make an error. Then brew rm -f appthatmakeserror and install it again.

Contributor

dlo commented Nov 9, 2012

Might be less traumatic to install in a another directory first to see if a new setup doesn't have the same issues, before wiping out my existing kegs. I'll keep y'all posted.

Contributor

2bits commented Nov 10, 2012

I apologize for not suggesting moving /usr/local to /usr/local.bak and creating a new one. I agree that is easier and safer in case you want to restore.

sudo mv /usr/local /usr/local.bak
sudo mkdir /usr/local
sudo chown $USER:admin /usr/local
chmod 775 /usr/local
cd /usr/local
and install Homebrew again.
Contributor

2bits commented Nov 20, 2012

@dlo Any news here before Thanksgiving?

mckk commented Dec 6, 2012

I think I have the same problem, but no of the linking issues in brew doctor.

Build log:

==> Downloading http://www.graphviz.org/pub/graphviz/stable/SOURCES/graphviz-2.2
Already downloaded: /Library/Caches/Homebrew/graphviz-2.28.0.tar.gz
==> Downloading patches
######################################################################## 100.0%
==> Patching
patching file macosx/graphviz.xcodeproj/project.pbxproj
patching file lib/gvc/Makefile.in
patching file plugin/quartz/Makefile.in
==> ./configure --prefix=/usr/local/Cellar/graphviz/2.28.0 --without-qt --with-q
==> make install
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[3]: *** [libgvplugin_gd.la] Error 1
make[2]: *** [install-recursive] Error 1
make[1]: *** [install-recursive] Error 1
make: *** [install] Error 2

brew doctor and logs: https://gist.github.com/4220762 (A tiny error in brew doctor, I'm fixing it now, but it probably doesn't influence this)
brew --config: https://gist.github.com/4220711

I went through most of the recommendations on the troubleshooting page (I think all of the relevant ones).
Anyone has any ideas?

Contributor

dlo commented Dec 6, 2012

I ended up getting a new computer. Not because I couldn't install graphviz. It was just old.

Contributor

dlo commented Dec 6, 2012

Needless to say, I couldn't figure it out, and resetting /usr/local didn't fix it.

Contributor

adamv commented Jan 15, 2013

ld: library not found for -lpng12 wonder where png12 is coming from here.

Contributor

adamv commented Jan 15, 2013

Closing because...I guess the new computer fixed the OP's problem.

adamv closed this Jan 15, 2013

xu-cheng locked and limited conversation to collaborators Feb 16, 2016

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