diff options
author | Solomon Peachy <pizza@shaftnet.org> | 2023-05-24 09:37:20 -0400 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2024-05-08 21:45:42 -0400 |
commit | 8c86fb6da0b9c068ee4b4220dee11171e322f67f (patch) | |
tree | 35d458f5d8015f659593fb57df67b5e99afb5462 /tools/configure | |
parent | 0a89d1d4df0d24f2b73888fe3c457679acfb48aa (diff) | |
download | rockbox-8c86fb6da0b9c068ee4b4220dee11171e322f67f.tar.gz rockbox-8c86fb6da0b9c068ee4b4220dee11171e322f67f.zip |
arm: Use -masm-syntax-unified when compiling with gcc8 or newer
Annoyingly, this makes all of the '.S' files we compile get treated as
divided syntax, so we need to make the syntax in them explicit.
Change-Id: I56a3916b7b24c84a1214a5d6bc4ed4d651f002cf
Diffstat (limited to 'tools/configure')
-rwxr-xr-x | tools/configure | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tools/configure b/tools/configure index 8a2e499a29..be4b0e3902 100755 --- a/tools/configure +++ b/tools/configure | |||
@@ -4533,7 +4533,11 @@ if [ -z "$arch" ]; then | |||
4533 | elif [ -n "$(echo $cpp_defines | grep -w __arm__)" ]; then | 4533 | elif [ -n "$(echo $cpp_defines | grep -w __arm__)" ]; then |
4534 | arch="arm" | 4534 | arch="arm" |
4535 | # cpp defines like "#define __ARM_ARCH_4TE__ 1" (where we want to extract the 4) | 4535 | # cpp defines like "#define __ARM_ARCH_4TE__ 1" (where we want to extract the 4) |
4536 | arch_version="$(echo $cpp_defines | tr ' ' '\012' | grep __ARM_ARCH | sed -e 's,.*\([0-9]\).*,\1,' | grep -v __ARM_ARCH)" | 4536 | arch_version="$(echo $cpp_defines | tr ' ' '\012' | grep __ARM_ARCH | sed -e 's,.*\([0-9]\).*,\1,' | grep -v __ARM_ARCH | head -1)" |
4537 | if test "$gccnum" -ge "800"; then | ||
4538 | # GCC8+ can natively emit unified asm syntax | ||
4539 | GCCOPTS="$GCCOPTS -masm-syntax-unified" | ||
4540 | fi | ||
4537 | elif [ -n "$(echo $cpp_defines | grep -w __mips__)" ]; then | 4541 | elif [ -n "$(echo $cpp_defines | grep -w __mips__)" ]; then |
4538 | arch="mips" | 4542 | arch="mips" |
4539 | arch_version="$(echo $cpp_defines | tr ' ' '\012' | grep _MIPS_ARCH_MIPS | sed -e 's,.*\([0-9][0-9]\).*,\1,' | grep -v _MIPS_ARCH_MIPS)" | 4543 | arch_version="$(echo $cpp_defines | tr ' ' '\012' | grep _MIPS_ARCH_MIPS | sed -e 's,.*\([0-9][0-9]\).*,\1,' | grep -v _MIPS_ARCH_MIPS)" |