From b627a510d3ea60b4748e171d5702bedca399bfd9 Mon Sep 17 00:00:00 2001 From: Egor Yusov Date: Sat, 16 Dec 2017 12:24:15 -0800 Subject: CMake: updated Android build rules --- unityplugin/GhostCubeScene/CMakeLists.txt | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'unityplugin/GhostCubeScene') diff --git a/unityplugin/GhostCubeScene/CMakeLists.txt b/unityplugin/GhostCubeScene/CMakeLists.txt index ebcc3c1..df83e23 100644 --- a/unityplugin/GhostCubeScene/CMakeLists.txt +++ b/unityplugin/GhostCubeScene/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required (VERSION 3.10) +cmake_minimum_required (VERSION 3.6) project(GhostCubeScene CXX) @@ -73,6 +73,11 @@ if(PLATFORM_WIN32 OR PLATFORM_UNIVERSAL_WINDOWS) endif() +elseif(PLATFORM_ANDROID) + + list(APPEND ${SOURCE} src/Android/AndroidMain.cpp) + add_library(GhostCubeScene SHARED ${SOURCE} ${INCLUDE}) + #elseif(APPLE) #add_executable(GhostCubeScene MACOSX_BUNDLE Main.cpp) #elseif(UNIX) @@ -103,6 +108,10 @@ PRIVATE UnityEmulator TargetPlatform ) +if(PLATFORM_ANDROID) + target_link_libraries(GhostCubeScene PRIVATE GhostCubePlugin-shared) +endif() + set_common_target_properties(GhostCubeScene) if(MSVC) -- cgit v1.2.3