mirror of
https://github.com/PixarAnimationStudios/OpenSubdiv
synced 2024-12-01 15:50:07 +00:00
Merge pull request #346 from nathan-at-digitalfish/no_neon
Allow NEON to be disabled on Android.
This commit is contained in:
commit
d14ec1cf5e
@ -121,7 +121,7 @@ SET(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)
|
||||
|
||||
set(OSD_COMPILER_FLAGS)
|
||||
|
||||
# Disable spurrious warnings in gcc builds and clang
|
||||
# Disable spurious warnings in gcc builds and clang
|
||||
if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_CLANGCC OR CMAKE_COMPILER_IS_ICC )
|
||||
|
||||
# Turn on all warnings
|
||||
@ -178,10 +178,6 @@ if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_CLANGCC OR CMAKE_COMPILER_IS_ICC
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
if(ANDROID)
|
||||
list(APPEND OSD_COMPILER_FLAGS -mfpu=neon)
|
||||
endif()
|
||||
|
||||
elseif(MSVC)
|
||||
|
||||
# Turn on all warnings
|
||||
@ -289,7 +285,8 @@ option(NO_TBB "Disable TBB backend" OFF)
|
||||
option(NO_CUDA "Disable CUDA backend" OFF)
|
||||
option(NO_OPENCL "Disable OpenCL backend" OFF)
|
||||
option(NO_CLEW "Disable CLEW wrapper library" OFF)
|
||||
option(NO_NO_GCD "Disable GrandCentralDispatch backend" OFF)
|
||||
option(NO_GCD "Disable GrandCentralDispatch backend" OFF)
|
||||
option(NO_NEON "Disable NEON backend" OFF)
|
||||
|
||||
# Check for dependencies
|
||||
if(NOT NO_OMP)
|
||||
@ -339,6 +336,10 @@ if (NOT NO_GCD AND APPLE)
|
||||
set(GCD_FOUND 1)
|
||||
endif()
|
||||
|
||||
if (NOT NO_NEON AND ANDROID)
|
||||
set(NEON_FOUND 1)
|
||||
endif()
|
||||
|
||||
if (NOT NO_MAYA)
|
||||
find_package(Maya 201200)
|
||||
endif()
|
||||
@ -347,14 +348,14 @@ endif()
|
||||
# disabled. Also, add preprocessor defines that can be used in the source
|
||||
# code to determine if a specific dependency is present or not.
|
||||
|
||||
if(ANDROID)
|
||||
add_definitions(-DLOCAL_ARM_MODE=arm -DLOCAL_ARM_NEON=true)
|
||||
endif()
|
||||
|
||||
if(GCD_FOUND)
|
||||
add_definitions( -DOPENSUBDIV_HAS_GCD )
|
||||
endif()
|
||||
|
||||
if(NEON_FOUND)
|
||||
add_definitions(-DLOCAL_ARM_MODE=arm -DLOCAL_ARM_NEON=true -mfpu=neon)
|
||||
endif()
|
||||
|
||||
if(OPENMP_FOUND)
|
||||
add_definitions(
|
||||
-DOPENSUBDIV_HAS_OPENMP
|
||||
|
@ -168,7 +168,7 @@ set(NEON_PRIVATE_HEADERS
|
||||
neonKernel.h
|
||||
)
|
||||
|
||||
if(ANDROID)
|
||||
if(NEON_FOUND)
|
||||
enable_language(ASM)
|
||||
list(APPEND CPU_SOURCE_FILES
|
||||
neonComputeContext.cpp
|
||||
|
Loading…
Reference in New Issue
Block a user