pygtk was built from source (I use gentoo and the ebuild
> does nothing out of the ordinary).
> I just re-emerged pygtk-2.3.97 and got the same result. I
> have attached the full output from python setup.py build in
> both cases - if you want to sent it to the pygtk people
> that would be great.
One thing that puzzles me. If you installed pygtk-2.3.97 from src,
normally it would go to /usr/local rather than /usr, unless you
specified a --prefix (did you?).
The error message suggests that matplotlib is using /usr rather than
/usr/local for pygtk
> file included from src/_gtkagg.cpp:8:
> /usr/include/pygtk-2.0/pygobject.h:140: error: expected `, 'or `...' before "typename"
Do you have a /usr/local/include/pygtk-2.0 directory? If so, it may
be that your PKG_CONFIG_PATH may need to be updated to see the new
install. See man pkg-config for help on this environment variable.
You want to make sure that matplotlib sees the right pygtk; matplotlib
uses 'pkg-config --cflags-only-I pygtk-2.0', so you can debug your
setup by making sure this command is returning the right path to pygtk-2.0.