Revert "build: remove extraneous AC_CHECK_LIB"

This reverts commit 0f200f4c3ae66d29c35c843a83d12fb3de98b76e.

These fuctions are actually provided by glibc, not glib. Vala hides them
in the glib namespace. Lightsoff won't link without this.