Adding check and distcheck