Did you do a 'bmake clean' in /usr/pkgsrc/devel/glib2 ? I'm assuming that if you manually removed the work directory under /usr/obj, references to it will still exist.