diff options
author | Timo Teräs <timo.teras@iki.fi> | 2015-08-28 08:08:57 +0000 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2015-08-28 08:27:59 +0000 |
commit | ad76680320da987e08545018d476c8dbd4060441 (patch) | |
tree | 226067fc2d1c356c95fb4d181aafbbc6e853ec6f /main/guile/0003-Recognize-more-ARM-targets.patch | |
parent | 90faba1d9dd647e1f5751208ad4d766872a043b1 (diff) | |
download | aports-ad76680320da987e08545018d476c8dbd4060441.tar.bz2 aports-ad76680320da987e08545018d476c8dbd4060441.tar.xz |
main/guile: cherry-pick patches from debian/upstream
fixes arm build among other issues
Diffstat (limited to 'main/guile/0003-Recognize-more-ARM-targets.patch')
-rw-r--r-- | main/guile/0003-Recognize-more-ARM-targets.patch | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/main/guile/0003-Recognize-more-ARM-targets.patch b/main/guile/0003-Recognize-more-ARM-targets.patch new file mode 100644 index 0000000000..59fc857f3c --- /dev/null +++ b/main/guile/0003-Recognize-more-ARM-targets.patch @@ -0,0 +1,70 @@ +From ff888821b2bd221ed74ce9bef8d28d94327450d4 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= <ludo@gnu.org> +Date: Fri, 4 Jul 2014 17:26:41 +0200 +Subject: Recognize more ARM targets. + +Suggested by Dale P. Smith. + +* module/system/base/target.scm (cpu-endianness): Add cases for + "arm.*eb", "^aarch64.*be", and "aarch64". Change "arm" case to + "arm.*". + (triplet-pointer-size): Allow underscore as in 'aarch64_be'. +* test-suite/tests/asm-to-bytecode.test ("cross-compilation")["armeb-unknown-linux-gnu", + "aarch64-linux-gnu", "aarch64_be-linux-gnu"]: New tests. + +Origin: upstream, commit: ffd3e55cfd12a3559621e3130d613d319243512d +Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=758463 +Added-by: Rob Browning <rlb@defaultvalue.org> +--- + module/system/base/target.scm | 10 +++++++++- + test-suite/tests/asm-to-bytecode.test | 9 +++++++++ + 2 files changed, 18 insertions(+), 1 deletion(-) + +diff --git a/module/system/base/target.scm b/module/system/base/target.scm +index c74ae67..9d65184 100644 +--- a/module/system/base/target.scm ++++ b/module/system/base/target.scm +@@ -72,6 +72,14 @@ + (endianness big)) + ((string-match "^arm.*el" cpu) + (endianness little)) ++ ((string-match "^arm.*eb" cpu) ++ (endianness big)) ++ ((string-prefix? "arm" cpu) ;ARMs are LE by default ++ (endianness little)) ++ ((string-match "^aarch64.*be" cpu) ++ (endianness big)) ++ ((string=? "aarch64" cpu) ++ (endianness little)) + (else + (error "unknown CPU endianness" cpu))))) + +@@ -95,7 +103,7 @@ + ((string-match "^x86_64-.*-gnux32" triplet) 4) ; x32 + + ((string-match "64$" cpu) 8) +- ((string-match "64[lbe][lbe]$" cpu) 8) ++ ((string-match "64_?[lbe][lbe]$" cpu) 8) + ((member cpu '("sparc" "powerpc" "mips" "mipsel")) 4) + ((string-match "^arm.*" cpu) 4) + (else (error "unknown CPU word size" cpu))))) +diff --git a/test-suite/tests/asm-to-bytecode.test b/test-suite/tests/asm-to-bytecode.test +index 6d2f20e..937e990 100644 +--- a/test-suite/tests/asm-to-bytecode.test ++++ b/test-suite/tests/asm-to-bytecode.test +@@ -205,6 +205,15 @@ + (test-target "x86_64-unknown-linux-gnux32" ; x32 ABI (Debian tuplet) + (endianness little) 4) + ++ (test-target "arm-unknown-linux-androideabi" ++ (endianness little) 4) ++ (test-target "armeb-unknown-linux-gnu" ++ (endianness big) 4) ++ (test-target "aarch64-linux-gnu" ++ (endianness little) 8) ++ (test-target "aarch64_be-linux-gnu" ++ (endianness big) 8) ++ + (pass-if-exception "unknown target" + exception:miscellaneous-error + (call-with-values (lambda () |