Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 905442 - net-dialup/ppp-2.5.0-r2: pppd-auth.o is incompatible with elf32-i386 on llvm profile
Summary: net-dialup/ppp-2.5.0-r2: pppd-auth.o is incompatible with elf32-i386 on llvm ...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords: PullRequest
: 913565 (view as bug list)
Depends on:
Blocks: LD-is-lld, systemwide-lld
  Show dependency tree
 
Reported: 2023-05-02 05:31 UTC by Brahmajit Das
Modified: 2024-03-05 19:51 UTC (History)
2 users (show)

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


Attachments
emerge --info (emerge--info,6.02 KB, text/plain)
2023-05-02 05:31 UTC, Brahmajit Das
Details
build log (HPga.log,42.23 KB, text/plain)
2023-05-02 05:32 UTC, Brahmajit Das
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Brahmajit Das 2023-05-02 05:31:25 UTC
Created attachment 861028 [details]
emerge --info

Building net-dialup/ppp-2.5.0-r2 fails on llvm profile with the following error

ld.lld: error: /usr/lib/gcc/x86_64-pc-linux-gnu/12/../../../../lib64/Scrt1.o is incompatible with elf32-i386
ld.lld: error: /usr/lib/gcc/x86_64-pc-linux-gnu/12/../../../../lib64/crti.o is incompatible with elf32-i386
ld.lld: error: /usr/lib/llvm/16/bin/../../../../lib/clang/16/lib/linux/clang_rt.crtbegin-x86_64.o is incompatible with elf32-i386
ld.lld: error: pppd-auth.o is incompatible with elf32-i386
ld.lld: error: pppd-ccp.o is incompatible with elf32-i386
ld.lld: error: pppd-chap-md5.o is incompatible with elf32-i386
ld.lld: error: pppd-chap.o is incompatible with elf32-i386
ld.lld: error: pppd-demand.o is incompatible with elf32-i386
ld.lld: error: pppd-eap.o is incompatible with elf32-i386
ld.lld: error: pppd-ecp.o is incompatible with elf32-i386
ld.lld: error: pppd-fsm.o is incompatible with elf32-i386
ld.lld: error: pppd-ipcp.o is incompatible with elf32-i386
ld.lld: error: pppd-lcp.o is incompatible with elf32-i386
ld.lld: error: pppd-magic.o is incompatible with elf32-i386
ld.lld: error: pppd-main.o is incompatible with elf32-i386
ld.lld: error: pppd-options.o is incompatible with elf32-i386
ld.lld: error: pppd-session.o is incompatible with elf32-i386
ld.lld: error: pppd-tty.o is incompatible with elf32-i386
ld.lld: error: pppd-upap.o is incompatible with elf32-i386
ld.lld: error: pppd-utils.o is incompatible with elf32-i386
ld.lld: error: too many errors emitted, stopping now (use --error-limit=0 to see all errors)
Comment 1 Brahmajit Das 2023-05-02 05:32:32 UTC
Created attachment 861029 [details]
build log
Comment 2 Ionen Wolkens gentoo-dev 2023-05-02 05:38:05 UTC
<snip> -L/usr/lib -lssl -lcrypto

From a quick look it's likely just these -L/usr/lib given lld will try to use it if passed (bfd ignores), only did a quick look seems to be coming from m4/ax_check_openssl.m4, ax_check_pam.m4, and others, they about all have e.g.:

OPENSSL_LDFLAGS="-L$ssldir/lib"
Comment 3 Brahmajit Das 2023-08-06 11:01:30 UTC
I was able to somewhat get around the bug by cd-ing into /var/tmp/portage/net-dialup/ppp-2.5.0-r4/work/ppp-2.5.0/pppd and then

clang -O2 -pipe -Wl,-E -Wl,-O1 -Wl,--as-needed -fuse-ld=lld -rtlib=compiler-rt -unwindlib=libunwind -Wl,--as-needed -o pppd pppd-auth.o pppd-ccp.o pppd-chap-md5.o pppd-chap.o pppd-demand.o pppd-eap.o pppd-ecp.o pppd-fsm.o pppd-ipcp.o pppd-lcp.o pppd-magic.o pppd-main.o pppd-options.o pppd-session.o pppd-tty.o pppd-upap.o pppd-utils.o pppd-sys-linux.o pppd-chap_ms.o pppd-crypto_ms.o pppd-cbcp.o pppd-mppe.o pppd-ipv6cp.o pppd-eui64.o pppd-eap-tls.o pppd-tls.o pppd-peap.o  -lcrypt -ldl ./.libs/libppp_crypto.a -L/usr/lib64 -lssl -lcrypto

So I guess @Ionen Wolkens was right.
Comment 4 Mike Gilbert gentoo-dev 2024-03-05 18:46:12 UTC
*** Bug 913565 has been marked as a duplicate of this bug. ***
Comment 5 Larry the Git Cow gentoo-dev 2024-03-05 19:51:39 UTC
The bug has been closed via the following commit(s):

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

commit c77e202de12022ab787403085c70c7b4c6801591
Author:     Mike Gilbert <floppym@gentoo.org>
AuthorDate: 2024-03-05 19:49:19 +0000
Commit:     Mike Gilbert <floppym@gentoo.org>
CommitDate: 2024-03-05 19:49:19 +0000

    net-dialup/ppp: fix build with lld
    
    Closes: https://bugs.gentoo.org/905442
    Signed-off-by: Mike Gilbert <floppym@gentoo.org>

 .../ppp/files/ppp-2.5.0-openssl-pkgconfig.patch    | 79 +++++++++++++++++++++
 net-dialup/ppp/files/ppp-2.5.0-pam-pkgconfig.patch | 81 ++++++++++++++++++++++
 net-dialup/ppp/ppp-2.5.0-r6.ebuild                 |  7 +-
 3 files changed, 165 insertions(+), 2 deletions(-)