use cmake to build and test