summaryrefslogtreecommitdiff
path: root/aclocal.m4
diff options
context:
space:
mode:
authorMoritz Angermann <moritz.angermann@gmail.com>2017-05-08 17:45:18 -0400
committerBen Gamari <ben@smart-cactus.org>2017-05-08 17:45:19 -0400
commitdc3b4af6d0c38ced4f0becf575474a1c1b08f794 (patch)
treef02cf1dbc0cb7a0bc1fd4c91e3d6fdd23a09008a /aclocal.m4
parentff7a3c4f9034af0aca1119c1c1e8f7187460bbad (diff)
downloadhaskell-dc3b4af6d0c38ced4f0becf575474a1c1b08f794.tar.gz
Fix Raspberry Pi
This is two fold: - We did not catch all ARM_ARCH_6 defines. Specifically not `6K` and `6KZ`, which is what llvm seems to use these days for `arm-none-linux-gnueabihf` (e.g. the triple that's used for raspbian as well). Without it, ghc assums we want to compile against some armv7 system, which raspbian is not (it is armv6 for maximum compatibility across the pi family, compromising on using armv7 and up features). - We stop forcing the -m and -arch flags on macOS. This is troublesome, as compiling for a 32bit system (e.g. raspberry pi, on a x86_64 macOS system results in the `-m64` flag being passed to to clang as well, which in turn figures out that you likely want 64bit, and rewrites your taret from `arm-none-linux-gnueabihf` to `aarch64-none-linux-gnueabihf`, which is definetly not what you want. Reviewers: austin, hvr, bgamari Reviewed By: bgamari Subscribers: rwbarton, thomie, erikd Differential Revision: https://phabricator.haskell.org/D3546
Diffstat (limited to 'aclocal.m4')
-rw-r--r--aclocal.m414
1 files changed, 2 insertions, 12 deletions
diff --git a/aclocal.m4 b/aclocal.m4
index dfb7892497..d874d41730 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -390,6 +390,8 @@ AC_DEFUN([GET_ARM_ISA],
defined(__ARM_ARCH_6T2__) || \
defined(__ARM_ARCH_6Z__) || \
defined(__ARM_ARCH_6ZK__) || \
+ defined(__ARM_ARCH_6K__) || \
+ defined(__ARM_ARCH_6KZ__) || \
defined(__ARM_ARCH_6M__)
return 0;
#else
@@ -585,18 +587,6 @@ AC_DEFUN([FPTOOLS_SET_C_LD_FLAGS],
i386-portbld-freebsd*)
$2="$$2 -march=i686"
;;
- i386-apple-darwin)
- $2="$$2 -m32"
- $3="$$3 -m32"
- $4="$$4 -arch i386"
- $5="$$5 -m32"
- ;;
- x86_64-apple-darwin)
- $2="$$2 -m64"
- $3="$$3 -m64"
- $4="$$4 -arch x86_64"
- $5="$$5 -m64"
- ;;
x86_64-unknown-solaris2)
$2="$$2 -m64"
$3="$$3 -m64"