aboutsummaryrefslogtreecommitdiff
path: root/NvCloth/compiler/cmake/android/NvCloth.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'NvCloth/compiler/cmake/android/NvCloth.cmake')
-rw-r--r--NvCloth/compiler/cmake/android/NvCloth.cmake39
1 files changed, 39 insertions, 0 deletions
diff --git a/NvCloth/compiler/cmake/android/NvCloth.cmake b/NvCloth/compiler/cmake/android/NvCloth.cmake
new file mode 100644
index 0000000..544a3b5
--- /dev/null
+++ b/NvCloth/compiler/cmake/android/NvCloth.cmake
@@ -0,0 +1,39 @@
+#
+# Build NvCloth
+#
+
+SET(GW_DEPS_ROOT $ENV{GW_DEPS_ROOT})
+
+SET(NVCLOTH_SOURCE_DIR ${PROJECT_SOURCE_DIR}/../../../)
+
+SET(NVCLOTH_PLATFORM_SOURCE_FILES
+ ${PROJECT_ROOT_DIR}/src/neon/NeonCollision.cpp
+ ${PROJECT_ROOT_DIR}/src/neon/NeonSelfCollision.cpp
+ ${PROJECT_ROOT_DIR}/src/neon/NeonSolverKernel.cpp
+ ${PROJECT_ROOT_DIR}/src/neon/SwCollisionHelpers.h
+)
+
+SET(NVCLOTH_PLATFORM_INCLUDES
+ ${LL_SOURCE_DIR}/include/linux
+ ${ANDROID_NDK}/sources/android/cpufeatures
+)
+
+# Use generator expressions to set config specific preprocessor definitions
+SET(NVCLOTH_COMPILE_DEFS
+ ${NVCLOTH_ANDROID_COMPILE_DEFS};
+ NvCloth_STATIC_LIB; # TODO: needed?
+
+ NV_ANDROID
+ NV_SIMD_SCALAR=1 # always compile scalar paths on android, so we may use them as fallback
+ NV_CLOTH_IMPORT=PX_DLL_EXPORT
+ NV_CLOTH_ENABLE_DX11=0
+ NV_CLOTH_ENABLE_CUDA=0
+
+ $<$<CONFIG:debug>:${NVCLOTH_ANDROID_DEBUG_COMPILE_DEFS};>
+ $<$<CONFIG:checked>:${NVCLOTH_ANDROID_CHECKED_COMPILE_DEFS};>
+ $<$<CONFIG:profile>:${NVCLOTH_ANDROID_PROFILE_COMPILE_DEFS};>
+ $<$<CONFIG:release>:${NVCLOTH_ANDROID_RELEASE_COMPILE_DEFS};>
+)
+
+# include common low level settings
+INCLUDE(../common/NvCloth.cmake)