How to create a .s (asm) file in an Android.mk file

I integrate my own codec in the libstagefrightAndroid source code. I have successfully completed all that Integration of custom Wrapper Codec in Android but I found the problem as if I have a file .sin my codec.

I follow LOCAL_CFLAGS := -DOSCL_EXPORT_REF= -DOSCL_IMPORT_REF=because it does not take files .sfor assembly.

I found some solutions, but this is not my link answer

please help me in this matter

Thanks at Advance.

+4
source share
1 answer

Try including files with this approach .s. It is important to have a fallback implementation C, and I assume you have one. In Android.mkyour codec file

ifeq ($(TARGET_ARCH),arm)
LOCAL_SRC_FILES += \
    src/asm/file1.s \
    src/asm/file2.s \
    src/asm/file3.s \
    src/asm/file4.s
else
LOCAL_SRC_FILES += \
    src/file1.cpp \
    src/file2.cpp \
    src/file3.cpp \
    src/file4.cpp
endif

For example, you can refer to the method of creating a decoder MP3, as in this file Android.mk.

+6
source

Source: https://habr.com/ru/post/1530929/


All Articles