cmake utility and sort method