This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
RE: ARM Multilib libc - make install only copies the default libc.a file to the toolchain directory.
- From: James Walmsley <james at fullfat-fs dot co dot uk>
- To: "Gibson, David" <David dot Gibson at analog dot com>, "newlib at sourceware dot org" <newlib at sourceware dot org>
- Date: Tue, 19 Nov 2013 15:38:11 +0000
- Subject: RE: ARM Multilib libc - make install only copies the default libc.a file to the toolchain directory.
- Authentication-results: sourceware.org; auth=none
- References: <8a302e579c8048f999a44c39bc85a02b at DB3PR04MB203 dot eurprd04 dot prod dot outlook dot com>,<DEE282494B151642A2C7A978F0E6129E0A666B5C at NWD2MBX5 dot ad dot analog dot com>
Hi David,
>> Have you configured the appropriate multilib configuration file in GCC to define the appropriate multilib definitions for your compiler?
>> For example, with the bare metal toolchain take a look at gcc/config/arm/t-arm-elf (Assuming you're building a bare metal toolchain).
>> You can uncomment the appropriate lines in there to support the processors you want to produce libs for.
I created my own file, based on the rtems example:
# Custom BT EABI multilibs
MULTILIB_OPTIONS = mthumb march=armv6-m/march=armv7-a/march=armv7-r/march=armv7-m mfpu=neon mfloat-abi=hard
MULTILIB_DIRNAMES = thumb armv6-m armv7-a armv7-r armv7-m neon hard
# Enumeration of multilibs
MULTILIB_EXCEPTIONS =
MULTILIB_EXCEPTIONS += mthumb/march=armv6-m/mfpu=neon/mfloat-abi=hard
MULTILIB_EXCEPTIONS += mthumb/march=armv6-m/mfpu=neon
MULTILIB_EXCEPTIONS += mthumb/march=armv6-m/mfloat-abi=hard
# MULTILIB_EXCEPTIONS += mthumb/march=armv6-m
# MULTILIB_EXCEPTIONS += mthumb/march=armv7-a/mfpu=neon/mfloat-abi=hard
# MULTILIB_EXCEPTIONS += mthumb/march=armv7-a/mfpu=neon
# MULTILIB_EXCEPTIONS += mthumb/march=armv7-a/mfloat-abi=hard
# MULTILIB_EXCEPTIONS += mthumb/march=armv7-a
MULTILIB_EXCEPTIONS += mthumb/march=armv7-r/mfpu=neon/mfloat-abi=hard
MULTILIB_EXCEPTIONS += mthumb/march=armv7-r/mfpu=neon
MULTILIB_EXCEPTIONS += mthumb/march=armv7-r/mfloat-abi=hard
# MULTILIB_EXCEPTIONS += mthumb/march=armv7-r
MULTILIB_EXCEPTIONS += mthumb/march=armv7-m/mfpu=neon/mfloat-abi=hard
MULTILIB_EXCEPTIONS += mthumb/march=armv7-m/mfpu=neon
MULTILIB_EXCEPTIONS += mthumb/march=armv7-m/mfloat-abi=hard
# MULTILIB_EXCEPTIONS += mthumb/march=armv7-m
MULTILIB_EXCEPTIONS += mthumb/mfpu=neon/mfloat-abi=hard
MULTILIB_EXCEPTIONS += mthumb/mfpu=neon
MULTILIB_EXCEPTIONS += mthumb/mfloat-abi=hard
# MULTILIB_EXCEPTIONS += mthumb
MULTILIB_EXCEPTIONS += march=armv6-m/mfpu=neon/mfloat-abi=hard
MULTILIB_EXCEPTIONS += march=armv6-m/mfpu=neon
MULTILIB_EXCEPTIONS += march=armv6-m/mfloat-abi=hard
MULTILIB_EXCEPTIONS += march=armv6-m
#MULTILIB_EXCEPTIONS += march=armv7-a/mfpu=neon/mfloat-abi=hard
#MULTILIB_EXCEPTIONS += march=armv7-a/mfpu=neon
#MULTILIB_EXCEPTIONS += march=armv7-a/mfloat-abi=hard
#MULTILIB_EXCEPTIONS += march=armv7-a
MULTILIB_EXCEPTIONS += march=armv7-r/mfpu=neon/mfloat-abi=hard
MULTILIB_EXCEPTIONS += march=armv7-r/mfpu=neon
MULTILIB_EXCEPTIONS += march=armv7-r/mfloat-abi=hard
MULTILIB_EXCEPTIONS += march=armv7-r
MULTILIB_EXCEPTIONS += march=armv7-m/mfpu=neon/mfloat-abi=hard
MULTILIB_EXCEPTIONS += march=armv7-m/mfpu=neon
MULTILIB_EXCEPTIONS += march=armv7-m/mfloat-abi=hard
MULTILIB_EXCEPTIONS += march=armv7-m
MULTILIB_EXCEPTIONS += mfpu=neon/mfloat-abi=hard
MULTILIB_EXCEPTIONS += mfpu=neon
MULTILIB_EXCEPTIONS += mfloat-abi=hard
Do you think the last exceptions also disable my -mfloat-abi=hard when -march=armv7-a is enabled.
I see the t-arm-elf uses matches rather than exceptions.
>> If you're building a cross compiler you'll typically build the first stage gcc without multilibs, and only enable them (add --enable-multilib) and build the appropriate libraries during the second stage build.
I have --enable-multilibs enabled for both stages, I shall change this and try again.
>> Hope that helps.
>> Dave
Many thanks, I'm beginning to understand this stuff now.
James