lkml.org 
[lkml]   [2020]   [Jan]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] perf clang: Fix build with Clang 9
From
Date
On 14.01.2020 23:20, Arnaldo Carvalho de Melo wrote:
> Em Sat, Dec 28, 2019 at 06:13:14PM +0100, Maciej S. Szmigiero escreveu:
>> LLVM D59377 (included in Clang 9) refactored Clang VFS construction a bit,
>> which broke perf clang build.
>> Let's fix it.
>>
>> Signed-off-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
>> Reviewed-by: Dennis Schridde <devurandom@gmx.net>
>> ---
>> tools/perf/util/c++/clang.cpp | 4 ++++
>> 1 file changed, 4 insertions(+)
>>
>> diff --git a/tools/perf/util/c++/clang.cpp b/tools/perf/util/c++/clang.cpp
>> index fc361c3f8570..c8885dfa3667 100644
>> --- a/tools/perf/util/c++/clang.cpp
>> +++ b/tools/perf/util/c++/clang.cpp
>> @@ -71,7 +71,11 @@ getModuleFromSource(llvm::opt::ArgStringList CFlags,
>> CompilerInstance Clang;
>> Clang.createDiagnostics();
>>
>> +#if CLANG_VERSION_MAJOR < 9
>> Clang.setVirtualFileSystem(&*VFS);
>> +#else
>> + Clang.createFileManager(&*VFS);
>> +#endif
>
> Building on ubuntu 19.10 fails, is this related? Or to the other patch? I
> haven't paid attention other than realizing its clang related.

Don't think so, these linker errors you posted look unrelated.

See the following Gentoo bugs for sample compile errors fixed by these
patches:
https://bugs.gentoo.org/695726
https://bugs.gentoo.org/678652

Maciej

\
 
 \ /
  Last update: 2020-01-15 00:18    [W:0.063 / U:0.516 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site