Mail archive
alpine-user

Re: [alpine-user] ArcticFox - musl undefined symbols

From: Natanael Copa <ncopa_at_alpinelinux.org>
Date: Thu, 28 Mar 2019 12:30:45 +0100

On Wed, 27 Mar 2019 18:12:19 +0100
Riccardo Mottola <riccardo.mottola_at_libero.it> wrote:

> Hi Natanael,
>
> Natanael Copa wrote:
> > On Tue, 12 Mar 2019 00:32:46 +0100
> > Riccardo Mottola <riccardo.mottola_at_libero.it> wrote:
> >
> > Have you reported this to ArticFox developers?
>
> I am one of the developers.... so it would be like reporting it to myself.

Ah!

So, this is an Alpine Linux user mailing list. I think it may be more
appropriate to follow this up in an ArticFox bug tracker or similar.

> >>
> >> main culprits are rand, srand, atoi and lateron bsearch
> >>
> >> Any suggestions?
> > musl has all those symbols:
> >
> > $ nm -D /lib/libc.musl-x86_64.so.1 | grep -E -w '(rand|srand|atoi)'
> > 000000000004cccf T atoi
> > 000000000003c996 T rand
> > 000000000003c98b T srand
> >
> > So my guess is that the linker flags are wrong for some reason?
> >
> > This should be reported to ArticFox developers
>
> The linker flags are set somehow automatically by the build system which
> is carried over from PaleMoon and FireFox.

Do you know around which version of firefox it was forked from? maybe
we have had patches for firefox at that time.

> In what could the flag differ from standard linux? It is libc, so I
> wonder why it is not found.

Very good question. There are no reason to not find them. Mozilla build
system is probably doing some nasty stuff, which is not surprising.

> We can see that
>
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
>
>
> is invoked.
>
> Do you know of any specific patche sin the Firefox build system about
> linking? or special linker option to pass in the .mozconfig file?

I am not aware of any specific patches for firefox that affects
linking. I think we may have some patch for workaing around some libc
headers wrapping. I think they wrap all (or some?) of the libc headers
which broke things at some point.

https://git.alpinelinux.org/aports/tree/testing/firefox/fix-fortify-system-wrappers.patch

This is compile time though so I dont think it is the same issue.

> As now I am treating AlpineLInux just as " linux"

I think that is correct. You may make difference between "linux" and
"linux with GNU libc".

>
> Riccardo


Looking over the original errors again:

/usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
../../xpcom/build/Unified_cpp_xpcom_build0.o: in function
`NS_MakeRandomString(char*, int)':
162:53.94 /home/multix/code/Arctic-Fox/xpcom/glue/nsCRTGlue.cpp:285:
undefined reference to `rand'
162:53.95

Would it be possible to recompile `Unified_cpp_xpcom_build0.o` and see
if there are any compile time warnings?

-nc

>
> ---
> Unsubscribe: alpine-user+unsubscribe_at_lists.alpinelinux.org
> Help: alpine-user+help_at_lists.alpinelinux.org
> ---
>



---
Unsubscribe:  alpine-user+unsubscribe_at_lists.alpinelinux.org
Help:         alpine-user+help_at_lists.alpinelinux.org
---
Received on Thu Mar 28 2019 - 12:30:45 UTC