updated to build with cmake