Merge "rust_fuzzer: add toolchain libraries if non-empty" am: d4a58377fd
am: 91f877b495
am: aaf044b75b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1673772 Change-Id: I9d61de00a0d66011bc26fefca79eec07c1cd7222
This commit is contained in:
commit
64bf07c5aa
1 changed files with 6 additions and 4 deletions
10
rust/fuzz.go
10
rust/fuzz.go
|
@ -70,10 +70,12 @@ func (fuzzer *fuzzDecorator) compilerFlags(ctx ModuleContext, flags Flags) Flags
|
|||
}
|
||||
|
||||
func (fuzzer *fuzzDecorator) compilerDeps(ctx DepsContext, deps Deps) Deps {
|
||||
deps.StaticLibs = append(deps.StaticLibs,
|
||||
config.LibFuzzerRuntimeLibrary(ctx.toolchain()))
|
||||
deps.SharedLibs = append(deps.SharedLibs,
|
||||
config.LibclangRuntimeLibrary(ctx.toolchain(), "asan"))
|
||||
if libFuzzerRuntimeLibrary := config.LibFuzzerRuntimeLibrary(ctx.toolchain()); libFuzzerRuntimeLibrary != "" {
|
||||
deps.StaticLibs = append(deps.StaticLibs, libFuzzerRuntimeLibrary)
|
||||
}
|
||||
if libclangRuntimeLibrary := config.LibclangRuntimeLibrary(ctx.toolchain(), "asan"); libclangRuntimeLibrary != "" {
|
||||
deps.SharedLibs = append(deps.SharedLibs, libclangRuntimeLibrary)
|
||||
}
|
||||
deps.SharedLibs = append(deps.SharedLibs, "libc++")
|
||||
deps.Rlibs = append(deps.Rlibs, "liblibfuzzer_sys")
|
||||
|
||||
|
|
Loading…
Reference in a new issue