Skip to content
This repository has been archived by the owner on Jul 4, 2023. It is now read-only.

let pango use system cairo on Lion #9238

Closed
wants to merge 1 commit into from
Closed

Conversation

camillol
Copy link
Contributor

It's the latest version, and it works fine.

It's the latest version.
@Sharpie
Copy link
Contributor

Sharpie commented Dec 23, 2011

Pango was linked against a Homebrew-built Cairo to fix some bugs in GraphViz. See this commit for reference:

85ead60

If someone could figure out how to use the system library that would be awesome as Cairo is a pain to build for XCode 4.x users as it fails with LLVM.

@camillol
Copy link
Contributor Author

That commit fixed the symptoms of some bugs. I've since fixed the causes, so that those bugs don't apply any more. glib uses the system iconv now (pull request #6868, closed), so the libiconv linking problems are gone. I've also updated the Graphviz formula so that it does not require Cairo for PDF output (pull request #9100, open), and in fact it does not depend on Cairo unless explicitly required. When Cairo is explicitly required, it links with the system version on Lion, and I've verified that PDF output still works as expected when forcing the use of Cairo.

@Sharpie
Copy link
Contributor

Sharpie commented Dec 23, 2011

Thanks a bunch for the additional info and for getting to the bottom of these issues. I will try to get this merged along with #9100 this weekend.

@camillol
Copy link
Contributor Author

Great, thanks!

@Sharpie
Copy link
Contributor

Sharpie commented Dec 24, 2011

Did some preliminary testing. If I apply this patch, then apply #9100 and build GraphViz on Lion using the --with-pangocairo option, I get the same out of memory error reported in issue #7140 when trying to create PDF files.

@Sharpie
Copy link
Contributor

Sharpie commented Dec 24, 2011

So, the problem could be a Pixman issue as reported on MacPorts:

https://trac.macports.org/ticket/30370

If the version of libpixman that ships with Lion was built by Apple with LLVM-GCC, then Lion's Cairo could be irreparably broken as far as Graphviz is concerned.

@camillol
Copy link
Contributor Author

Ah, you're right! I didn't have this patch applied when I tested #9100, so it still brings in a new Cairo through Pango. However, with this patch, the system Cairo is actually used, which then fails with an out of memory error.
I think you're correct, the Cairo that ships with Lion ('s X11) is broken: I just tested this patch with XQuartz's Cairo instead, and it works fine.

I think the best way of dealing with old/broken versions of the libraries that ship with OS X as part of X11 is to make Homebrew use XQuartz when installed, and require its installation for formulas that are known not to work with the version of X11 that ships with the installed version of OS X. See also my comment on pull request #5636.

I think I'm going to try and make an XQuartz support patch.

@Sharpie
Copy link
Contributor

Sharpie commented Dec 25, 2011

Allright, at least we have something concrete to add as a comment for formula that depend on Cairo with Lion.

I don't know if depending on XQuartz would be viable as it tramples all over the "no duplicates" policy. But I think it would be worthwhile to float the idea on the mailing list to see what the general consensus is.

@Sharpie Sharpie closed this in e562953 Dec 25, 2011
wesen pushed a commit to wesen/homebrew that referenced this pull request Jan 8, 2012
Add a comment to Pango explaining why Cairo is required on Lion. Remove Cairo
dependencies from Graphviz as the Pango dependency will include it if needed.

Closes Homebrew#8821.
Closes Homebrew#9238.
@camillol
Copy link
Contributor Author

camillol commented Jun 8, 2012

The XQuartz patch is now at #12607. Graphviz + Pango work with the Cairo in XQuartz 2.7.2.

Sharpie added a commit to Sharpie/homebrew that referenced this pull request Sep 12, 2012
Add a comment to Pango explaining why Cairo is required on Lion. Remove Cairo
dependencies from Graphviz as the Pango dependency will include it if needed.

Closes Homebrew#8821.
Closes Homebrew#9238.
snakeyroc3 pushed a commit to snakeyroc3/homebrew that referenced this pull request Dec 17, 2012
Add a comment to Pango explaining why Cairo is required on Lion. Remove Cairo
dependencies from Graphviz as the Pango dependency will include it if needed.

Closes Homebrew#8821.
Closes Homebrew#9238.
@Homebrew Homebrew 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.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants