From 574dbabb009af4871e89b303ca20388da2b3f42e Mon Sep 17 00:00:00 2001 From: PulkoMandy Date: Tue, 22 Apr 2014 09:49:32 +0200 Subject: [PATCH] Configure the ARM compiler to default to Cortex-A8 Ideally, we would only need to set this in build/jam/board/*, but the flags set there are not passed to the build of packages. The default is using some early ARM variant, for which gcc lacks some more atomic operations and emits calls to helper functions we don't implement. Setting the default architecture avoids this, as all packages will now be built to target the Cortex-A8. Also set the proper VFP version in BeagleBoard config file. Note this breaks the Verdex and Pi builds, but ARMv7 is what we should focus on for now. We can try to make older archs work after finishing the m68k port. --- build/jam/board/beagle/BoardSetup | 6 +++--- build/scripts/build_cross_tools_gcc4 | 7 +++++-- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/build/jam/board/beagle/BoardSetup b/build/jam/board/beagle/BoardSetup index 6c588d15d1..ccee40f7a7 100644 --- a/build/jam/board/beagle/BoardSetup +++ b/build/jam/board/beagle/BoardSetup @@ -63,8 +63,8 @@ HAIKU_BOARD_SDIMAGE_FILES = # HAIKU_ASFLAGS_$(HAIKU_PACKAGING_ARCH) - += -mcpu=cortex-a8 -mfpu=vfp -mfloat-abi=hard ; + += -mcpu=cortex-a8 -mfpu=vfpv3 -mfloat-abi=hard ; HAIKU_CCFLAGS_$(HAIKU_PACKAGING_ARCH) - += -mcpu=cortex-a8 -mfpu=vfp -mfloat-abi=hard ; + += -mcpu=cortex-a8 -mfpu=vfpv3 -mfloat-abi=hard ; HAIKU_C++FLAGS_$(HAIKU_PACKAGING_ARCH) - += -mcpu=cortex-a8 -mfpu=vfp -mfloat-abi=hard ; + += -mcpu=cortex-a8 -mfpu=vfpv3 -mfloat-abi=hard ; diff --git a/build/scripts/build_cross_tools_gcc4 b/build/scripts/build_cross_tools_gcc4 index 62854a0505..13baf4ffd7 100755 --- a/build/scripts/build_cross_tools_gcc4 +++ b/build/scripts/build_cross_tools_gcc4 @@ -34,8 +34,11 @@ m68k-*) ;; arm-*) # Multilib creates a lot of confusion as the wrong libs end up being linked. - binutilsConfigureArgs="--disable-multilib --with-float=hard" - gccConfigureArgs="--disable-multilib --with-float=hard" + # For now, target Cortex-A8 devices. + binutilsConfigureArgs="--disable-multilib --with-float=hard + --with-cpu=cortex-a8 --with-arch=armv7-a --with-fpu=vfpv3" + gccConfigureArgs="--disable-multilib --with-float=hard + --with-cpu=cortex-a8 --with-arch=armv7-a --with-fpu=vfpv3" ;; *) binutilsConfigureArgs="--disable-multilib"