galib: fix clang error with undeclared identifiers

Closes #908.