You are not logged in.

#1 2010-07-06 21:32:58

stqn
Member
Registered: 2010-03-19
Posts: 1,191
Website

glproto suddenly required by "pkg-config --cflags gl"

Something weird happened yesterday: I was working on a C++ project that uses SDL, GL and GTK. Everything was compiling fine without any warning (in Code::Blocks), and then suddenly after having changed a couple of source files and trying to build again, the compiler tells me "fatal error: gtk/gtk.h: No such file or directory".

To cut a long story short, I found out today that the problem was with pkg-config:

> pkg-config --cflags gl
Package glproto was not found in the pkg-config search path.
Perhaps you should add the directory containing `glproto.pc'
to the PKG_CONFIG_PATH environment variable
Package 'glproto', required by 'gl', not found

Code::Blocks doesn't output pkg-config errors so it took me a while to find out.

Now, what I don't understand is that I never installed the glproto package (as per /var/log/pacman.log), nor did I install, uninstall or upgrade any related package yesterday (pkg-config, mesa, codeblocks...) So why did pkg-config suddenly start asking for glproto?

Edit: I just tried installing glproto and I can now compile as before. But that doesn't explain how it happened!

Last edited by stqn (2010-07-06 21:45:09)

Offline

#2 2010-09-11 19:07:37

naxan
Member
From: Denver, CO
Registered: 2010-09-11
Posts: 24
Website

Re: glproto suddenly required by "pkg-config --cflags gl"

Found this post while researching a similar problem I was having (makepkg would bomb when trying to compile any GTK application, claiming that it could not find gtk/gtk.h, a GNOME library or something similar). In my case, it turns out that the issue was due to having cairo-snapshot (which implicitly requires glproto) rather than cairo installed.

Mostly leaving this comment in case someone else runs into a similar issue.


For I dipt into the future, far as human eye could see,
Saw the Vision of the world, and all the wonder that would be...

Offline

Board footer

Powered by FluxBB