Skip to content

Tests: Disable broken RunCMake.FindPkgConfig test cases for Windows

Craig Scott requested to merge craig.scott/cmake:tests-FindPkgConfig into master

The Windows implementation of a number of these tests have been found to not handle Windows paths and path separators properly. The whole approach taken in these tests appears dubious, so they may need to be significantly rewritten. I've disabled them in this MR to stop them giving us false positives in the meantime. #22031 will remain open until the affected tests are properly fixed.

Parts of the FindPkgConfig_IMPORTED_TARGET test case are also disabled by this MR. It was found that some pkg-config implementations on Windows (notably the one from Strawberry perl) don't extract out the expected contents from Libs and Cflags. This causes those tests to report false positives due to deficiencies on those pkg-config implementations, not in CMake or its tests, so the tests have been modified to skip those checks on Windows only.

It was also found that the FindPkgConfig_VERSION_OPERATORS test was relying on a relaxed form of a moduleSpec being supported. At least one Windows implementation of png-config (the one from Strawberry perl) doesn't support spaces around equality/inequality operators, so that test has been updated to avoid relying on such support.

Merge request reports