platoon-code / libyuv

Automatically exported from code.google.com/p/libyuv
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

android.mk does not build neon for platform sdk #298

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
consider changing android neon build according to:

android.mk does not build neon.  need to use TARGET_ARCH_VARIANT.  But the 
.neon.cc suffix is not supported by platform sdk.

Also the following trick works for NDK, but the add-src-files-target-cflags 
does not work on platform sdk either.

// 
http://stackoverflow.com/questions/7679363/android-build-system-neon-and-non-neo
n-builds

ifeq ($(TARGET_ARCH_VARIANT),armv7-a)
    LOCAL_CFLAGS += -DLIBYUV_NEON
    LOCAL_NEON_SRC_FILES := \
        source/compare_neon.cc    \
        source/rotate_neon.cc     \
        source/row_neon.cc        \
        source/scale_neon.cc
    LOCAL_SRC_FILES += $(LOCAL_NEON_SRC_FILES)
    LOCAL_NEON_CFLAGS := -mfloat-abi=softfp -mfpu=neon -march=armv7
    TARGET-process-src-files-tags += $(call add-src-files-target-cflags, $(LOCAL_NEON_SRC_FILES), $(LOCAL_NEON_CFLAGS))
endif

Original issue reported on code.google.com by fbarch...@google.com on 26 Dec 2013 at 9:13

GoogleCodeExporter commented 9 years ago

Original comment by fbarch...@google.com on 9 Feb 2015 at 7:47