PKGBUILDs/extra/libvpx/fix-armhf-link.patch
2015-04-21 11:57:20 +00:00

62 lines
1.8 KiB
Diff

diff --git a/build/make/configure.sh b/build/make/configure.sh
index 25c9f80..396e5b0 100644
--- a/build/make/configure.sh
+++ b/build/make/configure.sh
@@ -623,10 +623,14 @@ process_common_toolchain() {
# detect tgt_isa
case "$gcctarget" in
+ armv6*-gnueabihf)
+ tgt_isa=armv6
+ float_abi=hard
+ ;;
armv6*)
tgt_isa=armv6
;;
- armv7*-hardfloat*)
+ armv7*-gnueabihf)
tgt_isa=armv7
float_abi=hard
;;
@@ -634,6 +638,10 @@ process_common_toolchain() {
tgt_isa=armv7
float_abi=softfp
;;
+ armv5te*)
+ tgt_isa=armv5te
+ float_abi=soft
+ ;;
*x86_64*|*amd64*)
tgt_isa=x86_64
;;
@@ -831,7 +839,6 @@ process_common_toolchain() {
case ${tgt_cc} in
gcc)
- CROSS=${CROSS:-arm-none-linux-gnueabi-}
link_with_cc=gcc
setup_gnu_toolchain
arch_int=${tgt_isa##armv}
@@ -839,13 +846,6 @@ process_common_toolchain() {
check_add_asflags --defsym ARCHITECTURE=${arch_int}
tune_cflags="-mtune="
if [ ${tgt_isa} = "armv7" ] || [ ${tgt_isa} = "armv7s" ]; then
- if [ -z "${float_abi}" ]; then
- check_cpp <<EOF && float_abi=hard || float_abi=softfp
-#ifndef __ARM_PCS_VFP
-#error "not hardfp"
-#endif
-EOF
- fi
check_add_cflags -march=armv7-a -mfloat-abi=${float_abi}
check_add_asflags -march=armv7-a -mfloat-abi=${float_abi}
@@ -854,6 +854,8 @@ EOF
check_add_asflags -mfpu=neon
fi
else
+ check_add_cflags -march=${tgt_isa} -mfloat-abi=${float_abi}
+ check_add_asflags -march=${tgt_isa} -mfloat-abi=${float_abi}
check_add_cflags -march=${tgt_isa}
check_add_asflags -march=${tgt_isa}
fi