Add tools.mk and xref check