Tests fail on CentOS 6.9 (binutils is 2.20 where addr2line does not support -a flag)
- Dominant language
- Go
- Stars
- 9.3k
- Forks
- 671
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 10
Description
xref: https://github.com/golang/go/issues/23888
### What version of pprof are you using?
a74ae6fb3cd7047c79272e3ea0814b08154a2d3c
### What operating system and processor architecture are you using?
CentOS 6.9, x86_64
### What did you do?
Compiled go from source, tests failed, came to this repo, tried running the tests, was able to reproduce the exact same failure.
### What did you expect to see?
It'd be great if the tests had passed!
### What did you see instead?
The following tests failed:
```
--- FAIL: TestObjFile (0.02s)
--- FAIL: TestObjFile/fake_mapping (0.01s)
binutils_test.go:252: SourceLine: unexpected error write |1: broken pipe
--- FAIL: TestObjFile/fixed_load_address (0.01s)
binutils_test.go:252: SourceLine: unexpected error write |1: broken pipe
--- FAIL: TestObjFile/simulated_ASLR_address (0.01s)
binutils_test.go:252: SourceLine: unexpected error write |1: broken pipe
```
### Why do these tests fail?
The code at https://github.com/google/pprof/blob/a74ae6fb3cd7047c79272e3ea0814b08154a2d3c/internal/binutils/addr2liner.go#L92 assumes that the `-a` flag is available to the binary `addr2line`, which is available if the binutils version is >=2.21 ; but the latest version available on CentOS 6.9 is 2.20
Contributor guide
Assessment
This issue has not been assessed yet.