[PATCH 1/2] Revert "virt-result.m4: Colourize summary printings"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The colorization based on the string itself makes little to no sense as
the semantic meaning of the color (red = bad, green = good) is not
extracted from the semantics of the message:

1) If there is some additional string a 'yes' is marked yellow:

configure:       driver_modules: yes (CFLAGS='' LIBS='-ldl')

2) In some cases a 'no' is actually good:

configure:                  hal: no

3) Few good/recommended configuration options are still yellow:

configure:                 QEMU: qemu:qemu

while using 'root:root' would still be yellow.

4) fields dumping config (e.g. the warning flags line) is a giant blob
  of colored text which makes little sense

configure:        Warning Flags:  -fno-common -W -Wabsolute-value
-Waddress -Waddress-of-packed-member -Waggressive-loop-optimizations
-Wall -Wattribute-warning -Wattributes -Wbad-function-cast
-Wbool-compare -Wbool-operation -Wbuiltin-declaration-mismatch
-Wbuiltin-macro-redefined -Wcannot-profile -Wcast-align
-Wcast-align=strict -Wcast-function-type -Wchar-subscripts -Wclobbered
-Wcomment -Wcomments -Wcoverage-mismatch -Wcpp -Wdangling-else
-Wdate-time -Wdeprecated-declarations -Wdesignated-init
-Wdiscarded-array-qualifiers -Wdiscarded-qualifiers -Wdiv-by-zero
-Wdouble-promotion -Wduplicated-cond -Wduplicate-decl-speci ...

In addition if the idea is to switch to a more usable build system it
does not make sense to clutter the current one with more code.

This reverts commit 4b3ab5d2135a0dccd654491ef3a4f5b71575deae.
---
 m4/virt-result.m4 | 21 +++------------------
 1 file changed, 3 insertions(+), 18 deletions(-)

diff --git a/m4/virt-result.m4 b/m4/virt-result.m4
index 9115be5774..36973ba0b5 100644
--- a/m4/virt-result.m4
+++ b/m4/virt-result.m4
@@ -31,27 +31,12 @@ dnl  eg
 dnl
 dnl  LIBVIRT_RESULT([yajl], [yes], [-I/opt/yajl/include -lyajl])
 dnl
-
-m4_defun_init([_AS_ECHO_LOG_N],
-[AS_REQUIRE([_AS_LINENO_PREPARE])],
-[_AS_ECHO_N([$as_me:${as_lineno-$LINENO}: $1], AS_MESSAGE_LOG_FD)])
-
-m4_defun_init([AS_MESSAGE_N],
-[AS_REQUIRE([_AS_ME_PREPARE])],
-[m4_ifval(AS_MESSAGE_LOG_FD,
-	  [{ _AS_ECHO_LOG_N([$1])
-_AS_ECHO_N([$as_me: $1], [$2]);}],
-	  [_AS_ECHO_N([$as_me: $1], [$2])])[]])
-
 AC_DEFUN([LIBVIRT_RESULT], [
-  STR=`printf "%20s: " "$1"`
   if test "$2" = "no" || test -z "$3" ; then
-    VAL=`printf "%s" "$2"`
+    STR=`printf "%20s: %s" "$1" "$2"`
   else
-    VAL=`printf "%s (%s)" "$2" "$3"`
+    STR=`printf "%20s: %s (%s)" "$1" "$2" "$3"`
   fi

-  AS_MESSAGE_N([$STR])
-  _AS_ECHO([$VAL], AS_MESSAGE_LOG_FD)
-  COLORIZE_RESULT([$VAL])
+  AC_MSG_NOTICE([$STR])
 ])
-- 
2.21.0

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux