fix cmake files. Thx to Dakon and ngladitz