diff --git a/clang/test/Format/lit.local.cfg b/clang/test/Format/lit.local.cfg index 8acf02725d701..b060c79226cbd 100644 --- a/clang/test/Format/lit.local.cfg +++ b/clang/test/Format/lit.local.cfg @@ -1,3 +1,6 @@ +import platform +import lit.formats + # Suffixes supported by clang-format. config.suffixes = [ ".c", @@ -19,3 +22,8 @@ config.suffixes = [ ".td", ".test" ] + +# AIX 'diff' command doesn't support --strip-trailing-cr, but the internal +# python implementation does, so use that for cross platform compatibility +if platform.system() == "AIX": + config.test_format = lit.formats.ShTest()