]> code.ossystems Code Review - openembedded-core.git/commitdiff
glibc: Compile using thumb2 for arch > armv5 if user chooses
authorKhem Raj <raj.khem@gmail.com>
Sat, 3 Mar 2018 20:24:39 +0000 (12:24 -0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 6 Mar 2018 14:14:00 +0000 (06:14 -0800)
For arm we enforce ARM mode regardless of ARM_INSTRUCTION_SET
choice from config metadata, glibc works fine with thumb2 for
armv7+ so limit the restriction to armv5 and lower, tested on
rpi3 works equally well as arm mode glibc and sheds about 0.5MB
in size for main package alone. Other glibc build packages also
gets smaller

ARM:    2696   KiB     libc6
Thumb2: 2132   KiB     libc6

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-core/glibc/glibc-collateral.inc
meta/recipes-core/glibc/glibc.inc

index de859d5ce9779413b1d6a161eb412b5e28642c9b..aa871ac83db9de7d0ad99ca3ae686fe3f0d9b606 100644 (file)
@@ -7,7 +7,8 @@ HOMEPAGE = "http://www.gnu.org/software/libc/index.html"
 # This needs to match with glibc.inc, otherwise glibc-scripts and glibc-locale
 # will fail to find main glibc, for details see
 # http://lists.openembedded.org/pipermail/openembedded-core/2015-January/100679.html
-ARM_INSTRUCTION_SET = "arm"
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
 
 deltask do_fetch
 deltask do_unpack
index 21bbdc2ad07a6eef30dc65e696203163f68067c6..361a6fde10dc29b009b29367b3bab6d79b0c6b0b 100644 (file)
@@ -57,7 +57,8 @@ INHIBIT_DEFAULT_DEPS = "1"
 # This needs to match with glibc-collateral.inc, otherwise glibc-scripts and glibc-locale
 # will fail to find main glibc, for details see
 # http://lists.openembedded.org/pipermail/openembedded-core/2015-January/100679.html
-ARM_INSTRUCTION_SET = "arm"
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
 
 # glibc uses PARALLELMFLAGS variable to pass parallel build info so transfer
 # PARALLEL_MAKE into PARALLELMFLAGS and empty out PARALLEL_MAKE