]> git.proxmox.com Git - grub2.git/commitdiff
Add powerpc little-endian (ppc64le) flags
authorPaulo Flabiano Smorigo <pfsmorigo@linux.vnet.ibm.com>
Wed, 17 Sep 2014 17:42:40 +0000 (14:42 -0300)
committerColin Watson <cjwatson@debian.org>
Fri, 26 Sep 2014 13:06:40 +0000 (14:06 +0100)
* configure.ac: Add target for ppc64le (ppc64el).

Origin: other, https://lists.gnu.org/archive/html/grub-devel/2014-09/msg00022.html
Last-Update: 2014-09-19

Patch-Name: ppc64el-flags.patch

configure.ac

index dd4ba1fe453e0b461723512e2523011d9bea8496..c21307c5a70c6a9f59270c13e64c4238cf0d0d25 100644 (file)
@@ -119,6 +119,7 @@ if test "x$with_platform" = x; then
     x86_64-*) platform=pc ;;
     powerpc-*) platform=ieee1275 ;;
     powerpc64-*) platform=ieee1275 ;;
+    powerpc64le-*) platform=ieee1275 ;;
     sparc64-*) platform=ieee1275 ;;
     mipsel-*) platform=loongson ;;
     mips-*) platform=arc ;;
@@ -137,6 +138,7 @@ case "$target_cpu"-"$platform" in
   x86_64-xen) ;;
   x86_64-*) target_cpu=i386 ;;
   powerpc64-ieee1275) target_cpu=powerpc ;;
+  powerpc64le-ieee1275) target_cpu=powerpc ;;
 esac
 
 # Check if the platform is supported, make final adjustments.
@@ -570,6 +572,13 @@ if test "x$target_cpu" = xi386 && test "x$platform" != xemu; then
   TARGET_CFLAGS="$TARGET_CFLAGS -march=i386"
 fi
 
+if test x$target_cpu = xpowerpc && test x$ac_cv_c_bigendian = xno; then
+       #LD_FORCE_LE=1
+       TARGET_CFLAGS="$TARGET_CFLAGS -mbig-endian"
+       TARGET_CCASFLAGS="$TARGET_CCASFLAGS -mbig-endian"
+       TARGET_LDFLAGS="$TARGET_LDFLAGS -static -mbig-endian"
+fi
+
 if test "x$target_m32" = x1; then
   # Force 32-bit mode.
   TARGET_CFLAGS="$TARGET_CFLAGS -m32"