Bug 203936

Summary: [exp-run] Clang++ overlinking libm
Product: Ports & Packages Reporter: Bryan Drewery <bdrewery>
Component: Ports FrameworkAssignee: Bryan Drewery <bdrewery>
Status: In Progress ---    
Severity: Affects Only Me CC: emaste, jbeich, portmgr, ports-bugs
Priority: --- Keywords: needs-qa, patch
Version: LatestFlags: koobs: exp-run+
Hardware: Any   
OS: Any   

Description Bryan Drewery freebsd_committer 2015-10-21 16:45:29 UTC
https://people.freebsd.org/~bdrewery/patches/clangcxx-libm.diff

Please exp-run this. It avoids overlinking libm. It is possible some
ports are underlinked to libm and need to add an explicit -lm.
Comment 1 Antoine Brodin freebsd_committer 2015-10-29 21:04:15 UTC
Exp-run results:

http://package18.nyi.freebsd.org/jail.html?mastername=headamd64PR203936-default
http://pb2.nyi.freebsd.org/jail.html?mastername=headi386PR203936-default

3 new failures (and 2 new skipped):

+ {"origin"=>"devel/spatialindex", "pkgname"=>"spatialindex-1.8.5", "phase"=>"build", "errortype"=>"linker_error"}
+ {"origin"=>"lang/squirrel", "pkgname"=>"squirrel-2.2.5", "phase"=>"build", "errortype"=>"linker_error"}
+ {"origin"=>"net/udt", "pkgname"=>"udt-4.11_1", "phase"=>"build", "errortype"=>"linker_error"}

Failure logs:

http://package18.nyi.freebsd.org/data/headamd64PR203936-default/2015-10-29_14h41m45s/logs/errors/spatialindex-1.8.5.log
http://package18.nyi.freebsd.org/data/headamd64PR203936-default/2015-10-29_14h41m45s/logs/errors/squirrel-2.2.5.log
http://package18.nyi.freebsd.org/data/headamd64PR203936-default/2015-10-29_14h41m45s/logs/errors/udt-4.11_1.log
Comment 2 Bryan Drewery freebsd_committer 2015-10-29 21:15:09 UTC
Thanks!
Comment 3 Jan Beich freebsd_committer 2018-01-27 14:14:38 UTC
Did the patch land?
Comment 4 Ed Maste freebsd_committer 2018-02-01 14:47:51 UTC
(In reply to Jan Beich from comment #3)
> Did the patch land?

Does not appear so; running clang++ -v hello.cc shows the linker being invoked with -lm not wrapped by --as-needed / --no-as-needed.