crosstool-ng/scripts/build/arch
Alexey Neyman 34ecc718d9 arch/all: Add common function to return multilib target
This code was abstracted out of Cody P Schafer's multilib patch.
It doesn't seem right having architecture dependent code in a
specific libc implementation script. So this patch breaks it out into
scripts/build/arch/<arch>.sh in a function:

  multilib_target_to_build="$(CT_DoArchMultilibTarget 'multi_flags'
'target-in')"

Note that this function gets called on each multilib variant with
different sets of compiler flags supplied in 'multi_flags'. The caller
will first filter the flags so that there is no conflicting flags (e.g.,
no '-m32 -m64') supplied.

Changed by Alexey Neyman:
- make option analysis check specific option rather than match global
  options string as a whole. Moreover, old code did not handle multiple
  options in the same multilib, e.g. '-m64 -mlittle'.
- fixed substitutions in powerpc.sh (*le variants did not match the
  pattern in the shell parameter expansion)
- make s390.sh actually apply the flags it gathered from the options.
- straighten the spaghetti in x86.sh by setting two flags, arch & abi.
  Also, do not depend on "gnu" being the last part - we can have
  '*-uclibcx32', for example.

Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
Signed-off-by: Ray Donnelly <ray.donnelly@gmail.com>
Signed-off-by: Alexey Neyman <stilor@att.net>
2016-06-09 17:12:49 -07:00
..
alpha.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
arm.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
avr.sh avr: add support for AVR 8-bit architecture 2015-06-21 20:49:10 -03:00
m68k.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
microblaze.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
mips.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
nios2.sh arch/nios2:add nios2 2015-01-26 20:43:18 +01:00
powerpc.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
s390.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
sh.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
sparc.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
x86.sh arch/all: Add common function to return multilib target 2016-06-09 17:12:49 -07:00
xtensa.sh xtensa: Remove support for CT_CUSTOM_LOCATION_ROOT_DIR 2015-12-08 07:20:35 -08:00