From: voidlinux-github@inbox.vuxu.org
To: ml@inbox.vuxu.org
Subject: Re: [ISSUE] [CLOSED] cross-arm-none-eabi fail to link
Date: Sat, 01 Jun 2019 20:42:02 +0200 [thread overview]
Message-ID: <20190601184202.BHIy-M7d4vYbAW5s0jI4SLZ_SkiuXjBaV47mIj71lPg@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-1824@inbox.vuxu.org>
[-- Attachment #1: Type: text/plain, Size: 1867 bytes --]
Closed issue by herveq on void-packages repository
https://github.com/void-linux/void-packages/issues/1824
Description: ### System
Void 4.16.9_1 x86_64-musl GenuineIntel notuptodate hold rrrnF
package cross-arm-none-eabi
Hi all
I have been playing with a compiler gcc-arm-none-eabi-4_9-2015q2-20150609
from launchpad.net for stm32, since many months. I had to compile it to run
on Void Linux musl. For the discussion, I call it REF1.
Recently, I discovered the Void Linux package cross-arm-none-eabi and I
thought it could serve the same purpose as REF1. So I installed it, modified
my test project makefile to use it. I call it REF2.
The compiler looks to work fine, but the linker complains about:
undefined reference to `memcpy'
undefined reference to `strlen'...
That is like a missing library. REF2 libraries are installed in
/usr/arm-none-eabi/usr/lib that has exactly the same structure as my
REF1/arm-none-eabi/usr/lib
For a test, I replaced REF2/arm-none-eabi/usr/lib with
REF1/arm-none-eabi/usr/lib. And then the link succeeded, that means
REF2/libs are bad formatted. Some tests on libs:
REF1 lib/libc_nano.a
ls -l /home8/gnuarm/arm-none-eabi/arm-none-eabi/lib/libc_nano.a
-rw-r--r-- 1 hq hq 4090018 Feb 17 2017 /home8/gnuarm/arm-none-eabi/arm-none-eabi/lib/libc_nano.a
ar x /home8/gnuarm/arm-none-eabi/arm-none-eabi/lib/libc_nano.a
nm lib_a-memcpy.o
00000000 t $a
00000010 N $d
00000000 T memcpy
REF2 arm-none-eabi/usr/lib/libc_nano.a
ls -l /usr/arm-none-eabi/usr/lib/libc_nano.a
-rw-r--r-- 2 root root 561896 Jul 28 07:13 /usr/arm-none-eabi/usr/lib/libc_nano.a
ar x /usr/arm-none-eabi/usr/lib/libc_nano.a
nm lib_a-memcpy.o
nm: lib_a-memcpy.o: no symbols
The REF2 libs are 7 times smaller than REF1 and provide no symbols!
Did you strip too much the objects before making the libraries ?.
parent reply other threads:[~2019-06-01 18:42 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-1824@inbox.vuxu.org>]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190601184202.BHIy-M7d4vYbAW5s0jI4SLZ_SkiuXjBaV47mIj71lPg@z \
--to=voidlinux-github@inbox.vuxu.org \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).