Bug 233463 - japanese/mh: runtime error due to lld 6.0 issue.
Summary: japanese/mh: runtime error due to lld 6.0 issue.
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Kurt Jaeger
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-11-24 06:14 UTC by Yoshihiro Takahashi
Modified: 2019-02-03 10:54 UTC (History)
4 users (show)

See Also:
nyan: maintainer-feedback+
pi: merge-quarterly+


Attachments
a work-around patch (498 bytes, patch)
2018-11-24 06:14 UTC, Yoshihiro Takahashi
no flags Details | Diff
poudriere testport log on 12.0-RC1 without the patch (699.58 KB, text/plain)
2018-11-28 12:33 UTC, WATANABE Kazuhiro
no flags Details
poudriere testport log on 12.0-RC1 with the patch (702.40 KB, text/plain)
2018-11-28 12:35 UTC, WATANABE Kazuhiro
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Yoshihiro Takahashi freebsd_committer freebsd_triage 2018-11-24 06:14:33 UTC
Created attachment 199508 [details]
a work-around patch

Some programs (ex. rcvstore) linked by lld 6.0 fail with 'Undefined symbol' error.

For example:
% ./rcvstore
ld-elf.so.1: /usr/local/lib/libmh.so.3: Undefined symbol "tw_dotw"

The tw_dotw is in libzot.a, and it is linked with no error:
cc -L../sbr -fstack-protector  -Xlinker -rpath -Xlinker /usr/local/lib -o xrcvstore rcvstore.o ../config/config.o  -lmh ../mts/libmts.a  ../zotnet/libzot.a ../config/version.o
(xrcvstore is installed as rcvstore)

But libzot.a isn't linked in fact...

When using lld 7.0 instead of lld 6.0, it works fine.
So I attach a work-around patch until lld 7.0 is in base.
Comment 1 WATANABE Kazuhiro 2018-11-27 12:43:56 UTC
Hi, Takahashi-san.

Thanks for your report!  I have reproduced the problem on 12.0-RC1.
Your workaround (and ld.lld70) works good, so I accept the patch 
as the maintainer.
Comment 2 WATANABE Kazuhiro 2018-11-28 12:33:49 UTC
Created attachment 199637 [details]
poudriere testport log on 12.0-RC1 without the patch
Comment 3 WATANABE Kazuhiro 2018-11-28 12:35:23 UTC
Created attachment 199638 [details]
poudriere testport log on 12.0-RC1 with the patch
Comment 4 WATANABE Kazuhiro 2019-01-20 09:36:54 UTC
* Without the patch

nabe@aquarius-vm:~ % uname -a
FreeBSD aquarius-vm.sign.local 12.0-RELEASE-p2 FreeBSD 12.0-RELEASE-p2 GENERIC  amd64
nabe@aquarius-vm:~ % folders
ld-elf.so.1: /usr/local/lib/libmh.so.3: Undefined symbol "tw_dotw"
nabe@aquarius-vm:~ % 

* With the patch

nabe@aquarius-vm:~ % folders
                Folder      # of messages (  range  ); cur  msg  (other files)
                 inbox+ has   no messages.

                     TOTAL=    0 messages in 1 folder.
nabe@aquarius-vm:~ % 


To committer: Will you commit the patch?  If you need more information, ask me please.
Comment 5 commit-hook freebsd_committer freebsd_triage 2019-02-03 10:51:32 UTC
A commit references this bug:

Author: pi
Date: Sun Feb  3 10:51:16 UTC 2019
New revision: 492045
URL: https://svnweb.freebsd.org/changeset/ports/492045

Log:
  japanese/mh: Fix man pages, runtime error

  - man pages breakage on FreeBSD 11.x and later
  - runtime error due to lld 6.0 issue, fixed by using lld 7.0

  PR:		233463, 235456
  Submitted by:	WATANABE Kazuhiro <CQG00620@nifty.ne.jp> (maintainer), nyan
  MFH:		2019Q1

Changes:
  head/japanese/mh/Makefile
  head/japanese/mh/files/patch-conf_doc_me2man.sed
  head/japanese/mh/files/patch-conf_doc_tmac.h
  head/japanese/mh/files/patch-conf_makefiles_doc
Comment 6 commit-hook freebsd_committer freebsd_triage 2019-02-03 10:54:39 UTC
A commit references this bug:

Author: pi
Date: Sun Feb  3 10:53:45 UTC 2019
New revision: 492046
URL: https://svnweb.freebsd.org/changeset/ports/492046

Log:
  MFH: r492045

  japanese/mh: Fix man pages, runtime error

  - man pages breakage on FreeBSD 11.x and later
  - runtime error due to lld 6.0 issue, fixed by using lld 7.0

  PR:		233463, 235456
  Submitted by:	WATANABE Kazuhiro <CQG00620@nifty.ne.jp> (maintainer), nyan
  Approved by:	portmgr (unbreak blanket)

Changes:
_U  branches/2019Q1/
  branches/2019Q1/japanese/mh/Makefile
  branches/2019Q1/japanese/mh/files/patch-conf_doc_me2man.sed
  branches/2019Q1/japanese/mh/files/patch-conf_doc_tmac.h
  branches/2019Q1/japanese/mh/files/patch-conf_makefiles_doc