function(FilterPlatformPaths sourcesVar) if (IOS) list(FILTER ${sourcesVar} EXCLUDE REGEX ".*GLFW.*") else () list(FILTER ${sourcesVar} EXCLUDE REGEX ".*[\\/]Host[\\/]iOS[\\/].*") endif () if (NOT LINUX) list(FILTER ${sourcesVar} EXCLUDE REGEX ".*[\\/]Host[\\/]Linux[\\/].*") endif () if (NOT WIN32) list(FILTER ${sourcesVar} EXCLUDE REGEX ".*[\\/]Host[\\/]Windows[\\/].*") endif () list(FILTER sources EXCLUDE REGEX "main\.(m|mm|c|cpp)") endfunction()