Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 690840 - sys-process/htop-2.2.0[-unicode] fails to build
Summary: sys-process/htop-2.2.0[-unicode] fails to build
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Christian Ruppert (idl0r)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: tinfo
  Show dependency tree
 
Reported: 2019-07-28 02:36 UTC by John Moore
Modified: 2020-12-07 14:46 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build log (sys-process:htop-2.2.0:20190728-020433.log,23.01 KB, text/x-log)
2019-07-28 02:36 UTC, John Moore
Details
emerge --info htop (htop.txt,7.39 KB, text/plain)
2019-07-28 02:47 UTC, John Moore
Details

Note You need to log in before you can comment on or make changes to this bug.
Description John Moore 2019-07-28 02:36:58 UTC
Created attachment 584858 [details]
build log

If I have USE="-unicode", emerge htop-2.2.0 fails with 
/usr/lib/gcc/x86_64-pc-linux-gnu/8.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: CRT.o: undefined reference to symbol 'keypad'

Setting USE="unicode", emerge htop is successful
Comment 1 John Moore 2019-07-28 02:47:23 UTC
Created attachment 584860 [details]
emerge --info htop
Comment 2 Guillermo D. H. 2019-07-28 19:09:35 UTC
Likely a consequence of setting USE=tinfo in the profiles.

x86_64-pc-linux-gnu-gcc ... -o htop ... CRT.o ... linux/Battery.o  -lncurses -lm  
/usr/lib/gcc/x86_64-pc-linux-gnu/8.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: CRT.o: undefined reference to symbol 'keypad'
/usr/lib/gcc/x86_64-pc-linux-gnu/8.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: /lib64/libtinfo.so.6: error adding symbols: DSO missing from command line

nm -D libtinfo.so.6.1 | grep keypad
0000000000013200 T keypad
0000000000013170 T _nc_keypad

And no -ltinfo in gcc's command line. Another one for bug #457530 I guess.
Comment 3 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2019-08-04 11:56:35 UTC
This issue requires special attention. 
Seems like the upstream author put extra (uselessly?) complicated effort into checking for either ncurses with unicode support and ncurses without unicode support depending on the --(en|dis)able-unicode configure switch. 
He even wrote his own m4 macros for that... m(
Comment 4 Jaco Kroon 2020-01-20 10:48:23 UTC
Workaround:  LDFLAGS=-ltinfo emerge -1av htop

Would love to see some kind of fix on this.  Gettng somewhat annoying.
Comment 5 Rolf Eike Beer archtester 2020-12-02 21:46:43 UTC
Still affects 3.0.2
Comment 6 Larry the Git Cow gentoo-dev 2020-12-07 14:46:59 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fcb9a9dd103f542b2382497615c72817ab61ad73

commit fcb9a9dd103f542b2382497615c72817ab61ad73
Author:     Lars Wendler <polynomial-c@gentoo.org>
AuthorDate: 2020-12-07 14:46:37 +0000
Commit:     Lars Wendler <polynomial-c@gentoo.org>
CommitDate: 2020-12-07 14:46:57 +0000

    sys-process/htop: Fixed build with USE="-unicode"
    
    Closes: https://bugs.gentoo.org/690840
    Package-Manager: Portage-3.0.11, Repoman-3.0.2
    Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>

 sys-process/htop/files/htop-3.0.3-tinfo.patch | 38 +++++++++++++++++++++++++++
 sys-process/htop/htop-3.0.2.ebuild            |  4 ++-
 sys-process/htop/htop-3.0.3.ebuild            |  4 +++
 3 files changed, 45 insertions(+), 1 deletion(-)