Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 755194 - sys-devel/clang: fails to build (error: ‘class llvm::Record’ has no member named ‘getValueAsOptionalDef’)
Summary: sys-devel/clang: fails to build (error: ‘class llvm::Record’ has no member na...
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal
Assignee: LLVM support project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-11-18 03:45 UTC by adam
Modified: 2020-12-02 23:22 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build logs and whatnot (clangfail.tar.xz,9.94 KB, application/x-xz)
2020-11-18 03:45 UTC, adam
Details

Note You need to log in before you can comment on or make changes to this bug.
Description adam 2020-11-18 03:45:57 UTC
Created attachment 672106 [details]
build logs and whatnot

the sys-devel/clang version 11 ebuild fails for me on amd64. the llvm ebuild works though. I've attached build log, the output of emerge --info blah blah blah and emerge -pqv. By the look of the errors it's some sort of namespacing issue? I don't understand. previous ebuilds (10.0.1, 10.0.0) also fail similarly.
Comment 1 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2020-11-18 10:03:08 UTC
I have never seen anything like that.  Is there anything uncommon about this system?
Comment 2 adam 2020-11-20 20:20:05 UTC
I don't know what you would consider unusual, but this system does use the ck-sources kernel and -march=skylake. I tried turning off -march=skylake and booting a gentoo-sources kernel and it didn't do anything. I used to have an -O3 setting, but I set it to -O2 and did "emerge @world" before submitting the bug report. I also used to have LLVM_BACKENDS="WebAssembly -BPF", but I don't need that anymore (in fact the only reason I need clang anymore is for firefox and thunderbird, and I can just use firefox-bin and thunderbird-bin instead). I'm going to try building a clang binpkg on another gentoo amd64 system and see if that works. 

does the clang ebuild compile itself with clang or does it use GCC? There's nothing too unusual about the way I have GCC set up other than that I have the mingw-gcc thing that lets me cross-compile to windows, but that shouldn't matter.
Comment 3 adam 2020-12-02 23:22:19 UTC
Now I've built and installed clang binpkgs from another system, and it worked, so it seems like this is a system-specific issue and not a bug.

Interestingly, when trying to fix this I found that i still had a previous version of clang installed (although the "which" command didn't point to it and it was uninstalled/unemerge by portage). I previously built llvm/clang from source outside of portage's system, so I suspect that's what's done it.