> Date: Sun, 16 Apr 2017 22:00:23 +0200 (CEST) > From: Mark Kettenis <mark.kette...@xs4all.nl> > > > Date: Sun, 16 Apr 2017 21:21:24 +0200 > > From: Patrick Wildt <patr...@blueri.se> > > > > Hi, > > > > this diff disables the color diagnostics by default so that LLVM's lld > > does not throw any ANSI sequences. > > > > ok? > > Wouldn't it be better to just change > lib/Support/Unix/Process.inc:terminalHasColors() to always return false? > > that should take care of the color stuff in all the different llvm tools.
So here is a diff I was thinking of. Fixes the issue that Theo discovered. I think this means the other diffs can be reverted, but I'll do that in a separate diff. ok? Index: gnu/llvm/lib/Support/Unix/Process.inc =================================================================== RCS file: /cvs/src/gnu/llvm/lib/Support/Unix/Process.inc,v retrieving revision 1.1.1.3 diff -u -p -r1.1.1.3 Process.inc --- gnu/llvm/lib/Support/Unix/Process.inc 24 Jan 2017 08:33:36 -0000 1.1.1.3 +++ gnu/llvm/lib/Support/Unix/Process.inc 17 Apr 2017 16:21:16 -0000 @@ -342,7 +342,7 @@ static ManagedStatic<sys::Mutex> TermCol #endif static bool terminalHasColors(int fd) { -#ifdef HAVE_TERMINFO +#if defined(HAVE_TERMINFO) && !defined(__OpenBSD__) // First, acquire a global lock because these C routines are thread hostile. MutexGuard G(*TermColorMutex);