[Buildroot] [RFC PATCH 3/4] Add bpftrace package

Qais Yousef qais.yousef at arm.com
Sun Oct 4 20:10:13 UTC 2020


On 10/03/20 21:56, Qais Yousef wrote:

[...]

> > > diff --git a/package/bpftrace/Config.in b/package/bpftrace/Config.in
> > > new file mode 100644
> > > index 0000000000..a4bae478dc
> > > --- /dev/null
> > > +++ b/package/bpftrace/Config.in
> > > @@ -0,0 +1,27 @@
> > > +config BR2_PACKAGE_BPFTRACE
> > > +	bool "bpftrace"
> > > +	depends on BR2_aarch64 || BR2_aarch64_be || BR2_x86_64
> > > +	depends on BR2_PACKAGE_BCC
> > > +	depends on BR2_PACKAGE_LLVM_RTTI
> > 
> > Why llvm rtti is needed ?
> 
> Good question.
> 
> I think I was seeing failures similar to the one described in the link below.
> Something wasn't found in LLVM library without enabling this option. Will try
> to reproduce and document it better. Unless you know of a better way to handle
> these type of problems :-)
> 
> 	https://github.com/iovisor/bpftrace/issues/1156

This is the error that I get if I don't enable LLVM_RTTI:

buildroot-arm64/output/host/lib/gcc/aarch64-buildroot-linux-gnu/9.3.0/../../../../aarch64-buildroot-linux-gnu/bin/ld: ast/libast.so: undefined reference to `typeinfo for llvm::SectionMemoryManager'
buildroot-arm64/output/host/lib/gcc/aarch64-buildroot-linux-gnu/9.3.0/../../../../aarch64-buildroot-linux-gnu/bin/ld: ast/libast.so: undefined reference to `typeinfo for llvm::orc::SymbolResolver'
collect2: error: ld returned 1 exit status

I understood after a bit of digging that it has hard dependency on having RTTI
enabled.

Is there a preferred way to solve these type of problems?

Thanks

--
Qais Yousef


More information about the buildroot mailing list