backport cmake fix
more cmake backports
Merge pull request #1032 from moaiforge/pull-stable-cmake-fix

Pull stable cmake fix