[cfe-dev] Cross-compiling Clang on Gentoo Linux

Jakov Smolic via cfe-dev cfe-dev at lists.llvm.org
Tue Jul 7 07:01:29 PDT 2020


Hello,
I have an issue with cross-compilation of Clang. The distribution I am
using is Gentoo Linux. The issue occurs due to the missing
`clang-tblgen` binary, so the build fails with the message
"/usr/bin/clang-tblgen not found or usable", as that binary is needed
to cross compile clang.
I came across some discussions in [1] and [2], and from what I
researched, the `clang-tblgen` binary is not installed by the clang's
build system.
Additional CMake configuration options added when Clang is cross
compiled on Gentoo Linux can be seen in the ebuild [3].
I am not sure whether it is necessary to manually build the `tblgen`
binary, or is there another way to do this? Could someone point me to
a workaround for this?

Thank you for your help!
Sincerely,
Jakov

[1] https://bugs.gentoo.org/442958
[2] https://github.com/NixOS/nixpkgs/issues/40602
[3] https://gitweb.gentoo.org/repo/gentoo.git/tree/sys-devel/clang/clang-10.0.0.ebuild#n228


More information about the cfe-dev mailing list