Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 675368 - sys-fs/lvm2-2.02.145 - /usr/libexec/gcc/aarch64-unknown-linux-musl/ld: ../../libdm/libdevmapper.so: undefined reference to `rpl_malloc'
Summary: sys-fs/lvm2-2.02.145 - /usr/libexec/gcc/aarch64-unknown-linux-musl/ld: ../../...
Status: UNCONFIRMED
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:
Depends on:
Blocks:
 
Reported: 2019-01-14 00:52 UTC by hanetzer
Modified: 2021-02-04 00:34 UTC (History)
4 users (show)

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


Attachments
build.log (file_675368.txt,48.29 KB, text/plain)
2019-01-14 01:07 UTC, hanetzer
Details
aarch64-unknown-linux-musl-emerge --info (file_675368.txt,2.80 KB, text/plain)
2019-01-14 01:09 UTC, hanetzer
Details
emerge --info (native aarch64-unknown-linux-gnu) (file_675368.txt,5.12 KB, text/plain)
2019-01-14 01:11 UTC, hanetzer
Details
x86_64-unknown-linux-musl config.log (config.log,149.93 KB, text/x-log)
2021-02-04 00:29 UTC, dkjii
Details
x86_64-unknown-linux-musl build.log (build.log,39.77 KB, text/x-log)
2021-02-04 00:29 UTC, dkjii
Details
x86_64-unknown-linux-musl emerge --info (log,2.68 KB, text/plain)
2021-02-04 00:33 UTC, dkjii
Details

Note You need to log in before you can comment on or make changes to this bug.
Description hanetzer 2019-01-14 00:52:02 UTC
Unsure if this is actually common to all hardware, trying some other flavors
as I write this, but on a gentoo aarch64-unknown-linux-gnu system emerging
sys-fs/lvm2::musl with an aarch64-unknown-linux-musl cross-toolchain the build
fails with undefined references to rpl_malloc and rpl_realloc

A fix/workaround I've found is to set (either in the ebuild's src_configure
or via pkg.env) ac_cv_func_malloc_0_nonnull=yes and ac_cv_func_realloc_0_nonnull=yes

Unsure where such a fix should be made, either in sys-devel/crossdev's site
files or maybe in the ebuild itself (I've seen it/similar hacks in a lot of
in-tree ebuilds).

Other info inbound as I un'fix' it and rerun builds to capture logs and such.
Comment 1 hanetzer 2019-01-14 01:07:24 UTC
Created attachment 560930 [details]
build.log
Comment 2 hanetzer 2019-01-14 01:09:55 UTC
Created attachment 560932 [details]
aarch64-unknown-linux-musl-emerge --info
Comment 3 hanetzer 2019-01-14 01:11:28 UTC
Created attachment 560934 [details]
emerge --info (native aarch64-unknown-linux-gnu)
Comment 4 Sergei Trofimovich gentoo-dev 2019-01-14 07:24:35 UTC
I guess it would help to see config.log if it's dependent on ./configure output.
My guess would be that
    checking for GNU libc compatible malloc... no
is a relevant piece.
Comment 5 hanetzer 2019-01-14 08:23:58 UTC
(In reply to Sergei Trofimovich from comment #4)
> I guess it would help to see config.log if it's dependent on ./configure
> output.
> My guess would be that
>     checking for GNU libc compatible malloc... no
> is a relevant piece.

Exact same failure on an x86_64-pc-linux-gnu->x86_64-pc-linux-musl cross
Comment 6 dkjii 2021-02-04 00:29:16 UTC
Created attachment 685725 [details]
x86_64-unknown-linux-musl config.log
Comment 7 dkjii 2021-02-04 00:29:39 UTC
Created attachment 685728 [details]
x86_64-unknown-linux-musl build.log
Comment 8 dkjii 2021-02-04 00:33:46 UTC
Created attachment 685731 [details]
x86_64-unknown-linux-musl emerge --info
Comment 9 dkjii 2021-02-04 00:34:09 UTC
(In reply to hanetzer from comment #5)
> (In reply to Sergei Trofimovich from comment #4)
> > I guess it would help to see config.log if it's dependent on ./configure
> > output.
> > My guess would be that
> >     checking for GNU libc compatible malloc... no
> > is a relevant piece.
> 
> Exact same failure on an x86_64-pc-linux-gnu->x86_64-pc-linux-musl cross

Same issue here, added some attachments