linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] scripts/gcc-goto.sh: Show stdout and stderr for potential errors
@ 2018-08-09  8:34 zhe.he
  2018-09-17  9:43 ` He Zhe
  0 siblings, 1 reply; 2+ messages in thread
From: zhe.he @ 2018-08-09  8:34 UTC (permalink / raw)
  To: tglx, kstewart, pombredanne, gregkh, linux-kernel; +Cc: zhe.he

From: He Zhe <zhe.he@windriver.com>

The check may fail not only because ${CC} does not support the asm
feature, but also due to potential defects of ${CC} itself like what
we experienced below or even it's missing.

Assembler messages:
Fatal error: The input and output files must be distinct
(introduced by binutils-2.31 "Stop the assembler from overwriting its
output file.")

This patch enables stdout and stderr to give user direct error
information for those cases, while not polluting the output for normal
cases.

Signed-off-by: He Zhe <zhe.he@windriver.com>
---
 scripts/gcc-goto.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/gcc-goto.sh b/scripts/gcc-goto.sh
index 083c526..bd7fc8eb 100755
--- a/scripts/gcc-goto.sh
+++ b/scripts/gcc-goto.sh
@@ -3,7 +3,7 @@
 # Test for gcc 'asm goto' support
 # Copyright (C) 2010, Jason Baron <jbaron@redhat.com>
 
-cat << "END" | $@ -x c - -c -o /dev/null >/dev/null 2>&1 && echo "y"
+cat << "END" | $@ -x c - -c -o /dev/null && echo "y"
 int main(void)
 {
 #if defined(__arm__) || defined(__aarch64__)
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] scripts/gcc-goto.sh: Show stdout and stderr for potential errors
  2018-08-09  8:34 [PATCH] scripts/gcc-goto.sh: Show stdout and stderr for potential errors zhe.he
@ 2018-09-17  9:43 ` He Zhe
  0 siblings, 0 replies; 2+ messages in thread
From: He Zhe @ 2018-09-17  9:43 UTC (permalink / raw)
  To: tglx, kstewart, pombredanne, gregkh, linux-kernel

May I have your input?

Thanks,
Zhe

On 2018年08月09日 16:34, zhe.he@windriver.com wrote:
> From: He Zhe <zhe.he@windriver.com>
>
> The check may fail not only because ${CC} does not support the asm
> feature, but also due to potential defects of ${CC} itself like what
> we experienced below or even it's missing.
>
> Assembler messages:
> Fatal error: The input and output files must be distinct
> (introduced by binutils-2.31 "Stop the assembler from overwriting its
> output file.")
>
> This patch enables stdout and stderr to give user direct error
> information for those cases, while not polluting the output for normal
> cases.
>
> Signed-off-by: He Zhe <zhe.he@windriver.com>
> ---
>  scripts/gcc-goto.sh | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/scripts/gcc-goto.sh b/scripts/gcc-goto.sh
> index 083c526..bd7fc8eb 100755
> --- a/scripts/gcc-goto.sh
> +++ b/scripts/gcc-goto.sh
> @@ -3,7 +3,7 @@
>  # Test for gcc 'asm goto' support
>  # Copyright (C) 2010, Jason Baron <jbaron@redhat.com>
>  
> -cat << "END" | $@ -x c - -c -o /dev/null >/dev/null 2>&1 && echo "y"
> +cat << "END" | $@ -x c - -c -o /dev/null && echo "y"
>  int main(void)
>  {
>  #if defined(__arm__) || defined(__aarch64__)


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-09-17  9:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-09  8:34 [PATCH] scripts/gcc-goto.sh: Show stdout and stderr for potential errors zhe.he
2018-09-17  9:43 ` He Zhe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).