Run make before make check, in case libraries are not all built yet.