[Bug 29591] configure could be improved to check for libSM explicitly