From 72983480fe6d5161026fef3418fbb7c0cc82b1a9 Mon Sep 17 00:00:00 2001 From: Adrian Bunk Date: Thu, 3 Sep 2009 00:17:11 +0300 Subject: build pixman-arm-simd.c always when pixman-arm-neon.c is being built SIMD=n, NEON=y resulted in a build error due to pixman-arm-neon.c calling _pixman_implementation_create_arm_simd(). Let pixman-arm-simd.c be basically empty when SIMD is disabled and NEON is enabled. That's a general problem, but hits especially when building Thumb-2 code. --- configure.ac | 3 +-- pixman/pixman-arm-simd.c | 6 ++++++ pixman/pixman-private.h | 2 -- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/configure.ac b/configure.ac index 937fae7..7c7010c 100644 --- a/configure.ac +++ b/configure.ac @@ -380,8 +380,6 @@ fi AC_SUBST(ARM_SIMD_CFLAGS) -AM_CONDITIONAL(USE_ARM_SIMD, test $have_arm_simd = yes) - dnl ========================================================================== dnl Check for ARM NEON instructions ARM_NEON_CFLAGS="-mfpu=neon -mcpu=cortex-a8" @@ -416,6 +414,7 @@ fi AC_SUBST(ARM_NEON_CFLAGS) AM_CONDITIONAL(USE_ARM_NEON, test $have_arm_neon = yes) +AM_CONDITIONAL(USE_ARM_SIMD, test $have_arm_simd = yes -o $have_arm_neon = yes) AC_MSG_RESULT($have_arm_neon) if test $enable_arm_neon = yes && test $have_arm_neon = no ; then diff --git a/pixman/pixman-arm-simd.c b/pixman/pixman-arm-simd.c index fb7bf3d..94a3528 100644 --- a/pixman/pixman-arm-simd.c +++ b/pixman/pixman-arm-simd.c @@ -29,6 +29,8 @@ #include "pixman-private.h" +#ifdef USE_ARM_SIMD + static void arm_composite_add_8000_8000 (pixman_implementation_t * impl, pixman_op_t op, @@ -473,13 +475,17 @@ arm_simd_composite (pixman_implementation_t *imp, width, height); } +#endif /* USE_ARM_SIMD */ + pixman_implementation_t * _pixman_implementation_create_arm_simd (void) { pixman_implementation_t *general = _pixman_implementation_create_fast_path (); pixman_implementation_t *imp = _pixman_implementation_create (general); +#ifdef USE_ARM_SIMD imp->composite = arm_simd_composite; +#endif return imp; } diff --git a/pixman/pixman-private.h b/pixman/pixman-private.h index ff7a65f..5e5e2a9 100644 --- a/pixman/pixman-private.h +++ b/pixman/pixman-private.h @@ -532,10 +532,8 @@ pixman_implementation_t * _pixman_implementation_create_sse2 (void); #endif -#ifdef USE_ARM_SIMD pixman_implementation_t * _pixman_implementation_create_arm_simd (void); -#endif #ifdef USE_ARM_NEON pixman_implementation_t * -- 1.5.6.1