core: fix build of tests with autotools