Permalink
Browse files

[runtime] [test] Use more portable short options to sort(1)

Pass `-n -s` instead of `--numeric --stable` to sort(1), as long options
are not supported by NetBSD sort implementation.  `-n` is defined
by POSIX, so it should be fully portable.  `-s` is used consistently
at least in GNU sort and FreeBSD sort, and I honestly doubt it would
cause issues with any other implementation supporting `--stable`.

Differential Revision: https://reviews.llvm.org/D55479
  • Loading branch information...
mgorny committed Dec 11, 2018
1 parent f41a2fe commit 7e201e9cacd8b8d5104509796f0525000a3df904
Showing with 1 addition and 1 deletion.
  1. +1 −1 openmp/runtime/test/lit.cfg
@@ -116,7 +116,7 @@ config.substitutions.append(("%flags", config.test_flags))

if config.has_ompt:
config.substitutions.append(("FileCheck", config.test_filecheck))
config.substitutions.append(("%sort-threads", "sort --numeric-sort --stable"))
config.substitutions.append(("%sort-threads", "sort -n -s"))
if config.operating_system == 'Windows':
# No such environment variable on Windows.
config.substitutions.append(("%preload-tool", "true ||"))

0 comments on commit 7e201e9

Please sign in to comment.