Fix build issue regarding cmake 3.21.3