Mail archive
alpine-user

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

From: Natanael Copa <ncopa_at_alpinelinux.org>
Date: Mon, 25 Mar 2019 11:12:31 +0000

On Tue, 12 Mar 2019 00:32:46 +0100
Riccardo Mottola <riccardo.mottola_at_libero.it> wrote:

> Hi all,
>
> with the hunspell and other hacks in place, I get relatively far
> compiling ArcticFox now, howevr linking fails with tons of errors about
> undefined symbols.ù

Have you reported this to ArticFox developers?

>
> Here the first ones:
>
> 162:53.94     INPUT("StaticXULComponentsEnd/StaticXULComponentsEnd.o")
> 162:53.94
> 162:53.94
> /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
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
> /home/multix/code/Arctic-Fox/xpcom/glue/nsCRTGlue.cpp:280: undefined
> reference to `srand'
> 162:53.95
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
> ../../netwerk/base/Unified_cpp_netwerk_base0.o: in function
> `mozilla::net::Predictor::ParseMetaDataEntry(char const*, char const*,
> nsIURI**, unsigned int&, unsigned int&, unsigned int&)':
> 162:53.95 /home/multix/code/Arctic-Fox/netwerk/base/Predictor.cpp:1529:
> undefined reference to `atoi'
> 162:53.95
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
> /home/multix/code/Arctic-Fox/netwerk/base/Predictor.cpp:1545: undefined
> reference to `atoi'
> 162:53.96
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
> /home/multix/code/Arctic-Fox/netwerk/base/Predictor.cpp:1555: undefined
> reference to `atoi'
> 162:53.96
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
> /home/multix/code/Arctic-Fox/netwerk/base/Predictor.cpp:1559: undefined
> reference to `atoi'
> 162:53.96
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
> ../../netwerk/base/Unified_cpp_netwerk_base0.o: in function
> `mozilla::net::Predictor::LearnForSubresource(nsICacheEntry*, nsIURI*)':
> 162:53.96 /home/multix/code/Arctic-Fox/netwerk/base/Predictor.cpp:1451:
> undefined reference to `atoi'
> 162:53.96
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
> ../../netwerk/base/Unified_cpp_netwerk_base2.o:/home/multix/code/Arctic-Fox/netwerk/base/nsProtocolProxyService.cpp:882:
> more undefined references to `atoi' follow
> 162:53.97
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
> ../../netwerk/base/Unified_cpp_netwerk_base3.o: in function
> `nsSocketTransportService::Run()':
> 162:53.97
> /home/multix/code/Arctic-Fox/netwerk/base/nsSocketTransportService2.cpp:723:
> undefined reference to `srand'
> 162:53.97
> /usr/lib/gcc/i586-alpine-linux-musl/8.3.0/../../../../i586-alpine-linux-musl/bin/ld:
> ../../netwerk/streamconv/converters/Unified_cpp_converters0.o: in
> function `ParseFTPList(char const*, list_state*, list_result*)':
> 162:53.97
> /home/multix/code/Arctic-Fox/netwerk/streamconv/converters/ParseFTPList.cpp:666:
> undefined reference to `atoi'
>
> 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.



---
Unsubscribe:  alpine-user+unsubscribe_at_lists.alpinelinux.org
Help:         alpine-user+help_at_lists.alpinelinux.org
---
Received on Mon Mar 25 2019 - 11:12:31 UTC