redbpf icon indicating copy to clipboard operation
redbpf copied to clipboard

llvm 15 support

Open LessThanGreaterThan opened this issue 3 years ago • 4 comments

Hey, currently llvm 15 support is missing.

error:

error: No suitable version of LLVM was found system-wide or pointed
              to by LLVM_SYS_120_PREFIX.
       
              Consider using `llvmenv` to compile an appropriate copy of LLVM, and
              refer to the llvm-sys documentation for more information.
       
              llvm-sys: https://crates.io/crates/llvm-sys
              llvmenv: https://crates.io/crates/llvmenv
   --> /root/.cargo/registry/src/github.com-1ecc6299db9ec823/llvm-sys-120.2.6/src/lib.rs:486:1
    |
486 | / std::compile_error!(concat!(
487 | |     "No suitable version of LLVM was found system-wide or pointed
488 | |        to by LLVM_SYS_",
489 | |     env!("CARGO_PKG_VERSION_MAJOR"),
...   |
496 | |        llvmenv: https://crates.io/crates/llvmenv"
497 | | ));
    | |__^

error: could not compile `llvm-sys` due to previous error
warning: build failed, waiting for other jobs to finish...

LessThanGreaterThan avatar Feb 22 '23 10:02 LessThanGreaterThan

Have a look at this: https://github.com/foniod/redbpf/compare/main...SitinCloud:redbpf:llvm15.

Not satisfied enough to make a PR now, but it works (we use it at Owlyshield).

dlescos avatar Mar 22 '23 17:03 dlescos

@dlescos Tried that and got this error

thread 'main' panicked at 'Surprising failure from llvm-config: Custom { kind: NotFound, error: "llvm-config ret
urned empty output" 
`

wxmbugu avatar Mar 27 '23 11:03 wxmbugu

What does your llvm-config --version display?

dlescos avatar Mar 27 '23 11:03 dlescos

llvm-config --version 15.0.7

wxmbugu avatar Mar 27 '23 11:03 wxmbugu