autotools: add configure check for lambda capture expressions