FS#42053 - [llvm] Error linking sparse-llvm: undefined references to pthread functions
Attached to Project:
Arch Linux
Opened by Alain Kalker (ackalker) - Sunday, 21 September 2014, 17:22 GMT
Last edited by Evangelos Foutras (foutrelis) - Sunday, 21 September 2014, 18:53 GMT
Opened by Alain Kalker (ackalker) - Sunday, 21 September 2014, 17:22 GMT
Last edited by Evangelos Foutras (foutrelis) - Sunday, 21 September 2014, 18:53 GMT
|
Details
Description:
When building smatch-git from the AUR[1], and also when building sparse sparse from clean git master[2], I'm getting link errors involving undefined references to pthread functions. As I'm reporting this against llvm because smatch/sparse get their compile and link configuration from llvm-config, and don't add any pthread-related configuration of their own. From some Googling, I found an upstream bug[3] that might be related, but I haven't fully investigated this, so it's a very long shot. [1]: https://aur.archlinux.org/packages/smatch-git [2]: git://git.kernel.org/pub/scm/devel/sparse/sparse.git [3]: Bug 20287 – libc++abi dependency on pthread when -fuse-ld=gold used : http://llvm.org/bugs/show_bug.cgi?id=20287 Additional info: * package version(s) llvm 3.5.0-2.1 * config and/or log files etc. build.log: Output of `make V=1` for [2], showing the link errors Steps to reproduce: |
This task depends upon
Closed by Evangelos Foutras (foutrelis)
Sunday, 21 September 2014, 18:53 GMT
Reason for closing: Not a bug
Sunday, 21 September 2014, 18:53 GMT
Reason for closing: Not a bug
I don't know how recent this "--system-libs" option is, but I honestly would not expect the developers of sparse to have simply 'forgotten' about it.
[1]: c++ - Why am I getting "undefined reference to `dladdr'" even with -ldl for this simple program? - Stack Overflow : http://stackoverflow.com/questions/12993460/why-am-i-getting-undefined-reference-to-dladdr-even-with-ldl-for-this-simpl
http://reviews.llvm.org/rL197664
I guess this bug can be closed then, I will report to sparse-dev mailing list instead.
Sorry for wasting your time :)