Changed from static makefile to cmake