Fail to build pango #14426
Comments
Same problem ... |
Same here on mountain lion. Have a clean brew doctor and this is my brew config: https://gist.github.com/3447797 |
Same for me... Any ideas? |
Same on my side : OS-X ML (last OS update done) : In file included from pangocairo-fontmap.c:30: |
Same problem. |
Same problem. It seemed that there is no file name 'cairo-quartz.h' in /opt/X11/include/cairo |
I was able to get pango to build and install correctly by ensuring the pkgconfig for my Homebrew installs was referenced. I added "PKG_CONFIG_PATH=/usr/local/lib/pkgconfig", to the configure command in pango.rb. (/usr/local is my |
The main Homebrew pkg-config paths are built into pkg-config when it is compiled, which is why it isn't added to the PKG_CONFIG_PATH variable. |
When pango fails to find cairo-quartz.h, the Homebrew config.log shows output of pango configure step with this:
This does not include any reference to /usr/local/lib/pkgconfig. |
That's because it is built into the pkg-config binary when pkg-config is compiled. It is not in PKG_CONFIG_PATH. |
You can do |
Yes, that does look to be true. Yet still, pango without this modification is unable to find cairo on my system - or finds it first in /opt/X11, which does not have cairo-quartz. |
Followed mikegray's advice and Pango installed. Thank you! Now I've got a new "'pango/pangoxft.h' file not found" error coming up when I try to install fontforge, but at least there's progress ... |
It worked out with @mikegray's workaround. Didn't get an error about |
When this sort of thing happens with pkg-config, you |
Follow mikegray's comment I made Pango installed. Then I met new problem when continue to install gtk When configure, it keeps complain about:
Not sure whether this is problem of gtk or related with pango build? or cairo build? Following issue #10421 I also tried
not work yet... build error output:
|
did exactly the same as evanmeng and have the same error. this entry was usefull to me |
I get the same err as originally described (on Xcode-only system here).
Could that be a reason? |
@jacknagel you are right about the built-in path:
The PKG_CONFIG_PATH env var is: Perhaps, the env var takes precedence over the built in defaults here, so the And indeed, the opt/X11/include/cairo is added:
|
So, what to do about it? Add homebrew's pkgcnfig directories (several) in the PKG_CONFIG_PATH before the /opt/X11 stuff? |
samueljohn to resolve this i only exported the PKG_CONFIG_PATH and build it. It worked well |
@clementbethuys what do you mean ny "exported"? Where did you put the export statement? In the formula, the variable should already be set. |
you can export in the same terminal before using the command or directly in the recipe i put the X11 before. |
So what's your var then? |
@h-h please gist such long outputs. It floods this thread with mostly unuseful text. Thanks. |
To all: The work-around is to ENV.prepend 'PKG_CONFIG_PATH', "#{HOMEBREW_PREFIX}/lib/pkgconfig", ':' @h-h we seek for a proper fix, which would involve to set the |
@samueljohn Thanks for the workaround, did it for me as well! |
Same here. The workaround worked :) |
Clearly @samueljohn has found something and fixed it. So in addition to what he specifically fixed but without experimenting myself I need to say something. Within the last two weeks many changes have been made to Homebrew concerning cairo, fontforge, freetype2, libpng, and X11. Some changes were made the day after the OP posted. Everyone who experiences problems with any of those should seriously consider updating, removing their brews, and starting over because of how the formula have changed without changing versions (when that happens you are not told you have outdated formula). As an example of what I mean, we no longer require XQuartz for many formula. We instead will install freetype or libpng or cairo if you don't have X11. Those are new formula to the main repo within the last week or two. They are being adjusted as necessary (cairo just got a glib dep last night iirc). This is what I did after backing up my data:
|
I should test removing all involved formulae and then I'll report back. I don't expect that will resolve the issue. The workaround has been discovered by the other people in this thread, I just posted the exact line of code :-) I must stress that this is not a good fix in the long run. For sure @jacknagel knows how to fix properly :-) Further I am in the process of making a pull request to highlight formulae that are currently installed and need to be upgraded (based on changed version numbers) when one |
The problem here is that our cairo has an This wasn't a problem before because cairo was keg-only, and keg-only paths are prepended to PKG_CONFIG_PATH after the xquartz path. |
By disabling quartz in cairo and restoring "--with-x" to pango I can overcome these problems, and build gtk+. I suggest we restore pango's :x11 dep and "--with-x" flag for the time being. When my work on passing options to dependencies lands, we can remove it again and add a "with-x" option, and then gtk+ can do |
Sounds good. Might it be a good idea to always have homebrews pkgconfig dirs first in the PKG_CONFIG_PATH? |
No, that has the potential to break other stuff, and is just hacking around the real problems. PKG_CONFIG_PATH is about overriding the default search path, so we shouldn't abuse it in that way. |
Convinced. |
Can someone apply https://github.com/jacknagel/homebrew/compare/x and see if it improves the situation? |
Yes. It compiles well.
and no :-) but that test I wrote was getting hammered a month or so before XQuartz and HB-0.9.2. It started back when glib was changed to include gobject I think. |
It seems pango-view doesn't like the def test
mktemp do
system "#{bin}/pango-view", "-t", "test-image",
"--waterfall", "--rotate=10",
"--annotate=1", "--header"
end
end |
Pushed my pango/gtk fixups; other than the test, are there any outstanding issues here? |
With the fix, can get gtk and pango built. However, test gtk failed:
|
My fault, I didn't make XQuartz my default X11 environment after installing it. after
and restart, gtk works. |
@evanmeng phew! That's good news. |
@2bits @jacknagel does the doctor detect, if XQuartz is not the default X11 environment? Should he? |
I think Apple's default X11 should also work. The problem I met may be caused by the fact I didn't set any X11 environment to be default and start with my system. In fact, if you manually start XQartz.app (or X11.app, I think) and run gtk-demo there, it will work. |
With all those fixes I'm a bit lost (I'm a huge noob with homebrew) |
@a-foutoyet given you have installed XQuartz and Xcode and Please leave a note either if that works or not. |
@evanmeng Ya, perhaps it's okay but I would be curious what your |
@samueljohn thanks a lot for your feedback. I've made a brew update, then brew doctor (told me to brew install freetype...) PATH: /usr/local/Cellar/libffi/3.0.11/bin:/usr/local/Cellar/gettext/0.18.1.1/bin:/opt/X11/bin:/opt/subversion/bin/:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin:/opt/subversion/bin/:/opt/X11/bin:/usr/local/Library/Contributions/cmds Error: Failed executing: make (fontforge.rb:77) bash-3.2$ brew doctor Do you know how I could edit the directories listed above in order to delete the last slash (Warning) ? |
Your PATH is usually set in one of these files that are in your home directory (you might not have all of them):
usually on a line that says something like export PATH=/opt/subversion/bin/:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin:/opt/subversion/bin/:/opt/X11/bin But you want it to be more like this: export PATH=/opt/subversion/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin Once you have edited the file (on my system it is |
It seems that there is a missing dependency.
I am on OS X 10.8 and I have installed xQuatz.
The text was updated successfully, but these errors were encountered: