fix for x86 android build break (#5088)

This commit is contained in:
Guoyu Wang 2020-09-09 04:38:22 -07:00 committed by GitHub
parent a1a81470e3
commit 5019b2f3b9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -176,7 +176,11 @@ else()
set(mlas_platform_srcs_avx
${ONNXRUNTIME_ROOT}/core/mlas/lib/x86/SgemmKernelAvx.S
)
set_source_files_properties(${mlas_platform_srcs_avx} PROPERTIES COMPILE_FLAGS "-mavx")
if (CMAKE_SYSTEM_NAME STREQUAL "Android")
set_source_files_properties(${mlas_platform_srcs_avx} PROPERTIES COMPILE_FLAGS "-mavx -fno-integrated-as")
else()
set_source_files_properties(${mlas_platform_srcs_avx} PROPERTIES COMPILE_FLAGS "-mavx")
endif()
set(mlas_platform_srcs
${mlas_platform_srcs_sse2}