[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YD42IobxI3rym7N0@kernel.org>
Date: Tue, 2 Mar 2021 09:57:06 -0300
From: Arnaldo Carvalho de Melo <acme@...nel.org>
To: Antonio Terceiro <antonio.terceiro@...aro.org>
Cc: linux-kernel@...r.kernel.org,
Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
Mark Rutland <mark.rutland@....com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Jiri Olsa <jolsa@...hat.com>,
Namhyung Kim <namhyung@...nel.org>,
He Zhe <zhe.he@...driver.com>, stable@...r.kernel.org
Subject: Re: [PATCH] perf: fix ccache usage in $(CC) when generating arch
errno table
Em Wed, Feb 24, 2021 at 10:00:46AM -0300, Antonio Terceiro escreveu:
> This was introduced by commit e4ffd066ff440a57097e9140fa9e16ceef905de8.
>
> Assuming the first word of $(CC) is the actual compiler breaks usage
> like CC="ccache gcc": the script ends up calling ccache directly with
> gcc arguments, what fails. Instead of getting the first word, just
> remove from $(CC) any word that starts with a "-". This maintains the
> spirit of the original patch, while not breaking ccache users.
Thanks, tested, added:
Fixes: e4ffd066ff440a57 ("perf: Normalize gcc parameter when generating arch errno table")
And applied to perf/urgent.
- Arnaldo
> Signed-off-by: Antonio Terceiro <antonio.terceiro@...aro.org>
> Cc: Peter Zijlstra <peterz@...radead.org>
> Cc: Ingo Molnar <mingo@...hat.com>
> Cc: Arnaldo Carvalho de Melo <acme@...nel.org>
> Cc: Mark Rutland <mark.rutland@....com>
> Cc: Alexander Shishkin <alexander.shishkin@...ux.intel.com>
> Cc: Jiri Olsa <jolsa@...hat.com>
> Cc: Namhyung Kim <namhyung@...nel.org>
> Cc: He Zhe <zhe.he@...driver.com>
> CC: stable@...r.kernel.org
> ---
> tools/perf/Makefile.perf | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
> index 5345ac70cd83..9bfc725db608 100644
> --- a/tools/perf/Makefile.perf
> +++ b/tools/perf/Makefile.perf
> @@ -607,7 +607,7 @@ arch_errno_hdr_dir := $(srctree)/tools
> arch_errno_tbl := $(srctree)/tools/perf/trace/beauty/arch_errno_names.sh
>
> $(arch_errno_name_array): $(arch_errno_tbl)
> - $(Q)$(SHELL) '$(arch_errno_tbl)' $(firstword $(CC)) $(arch_errno_hdr_dir) > $@
> + $(Q)$(SHELL) '$(arch_errno_tbl)' '$(patsubst -%,,$(CC))' $(arch_errno_hdr_dir) > $@
>
> sync_file_range_arrays := $(beauty_outdir)/sync_file_range_arrays.c
> sync_file_range_tbls := $(srctree)/tools/perf/trace/beauty/sync_file_range.sh
> --
> 2.30.1
>
--
- Arnaldo
Powered by blists - more mailing lists