summaryrefslogtreecommitdiff
path: root/platform/android/java/nativeSrcsConfigs
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2020-10-29 08:34:03 +0100
committerGitHub <noreply@github.com>2020-10-29 08:34:03 +0100
commita4f70d7e6cb2b83f152717a69c9c042dd9424fc9 (patch)
tree5d5578b91e5d5c77c6272957a46cb6dbb819add1 /platform/android/java/nativeSrcsConfigs
parent13e93fe90499b3aac569ac09440c8d6056efba68 (diff)
parentedf762fba6b305771191b706e4d097f7b5285360 (diff)
Merge pull request #43178 from m4gr3d/update_android_plugins
Update android gradle plugins versions
Diffstat (limited to 'platform/android/java/nativeSrcsConfigs')
-rw-r--r--platform/android/java/nativeSrcsConfigs/AndroidManifest.xml2
-rw-r--r--platform/android/java/nativeSrcsConfigs/CMakeLists.txt19
-rw-r--r--platform/android/java/nativeSrcsConfigs/README.md4
-rw-r--r--platform/android/java/nativeSrcsConfigs/build.gradle54
4 files changed, 79 insertions, 0 deletions
diff --git a/platform/android/java/nativeSrcsConfigs/AndroidManifest.xml b/platform/android/java/nativeSrcsConfigs/AndroidManifest.xml
new file mode 100644
index 0000000000..dc180375d5
--- /dev/null
+++ b/platform/android/java/nativeSrcsConfigs/AndroidManifest.xml
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest package="org.godotengine.godot" />
diff --git a/platform/android/java/nativeSrcsConfigs/CMakeLists.txt b/platform/android/java/nativeSrcsConfigs/CMakeLists.txt
new file mode 100644
index 0000000000..34925684da
--- /dev/null
+++ b/platform/android/java/nativeSrcsConfigs/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Non functional cmake build file used to provide Android Studio editor support to the project.
+cmake_minimum_required(VERSION 3.6)
+project(godot)
+
+set(CMAKE_CXX_STANDARD 14)
+set(CMAKE_CXX_STANDARD_REQUIRED ON)
+set(CMAKE_CXX_EXTENSIONS OFF)
+
+set(GODOT_ROOT_DIR ../../../..)
+
+# Get sources
+file(GLOB_RECURSE SOURCES ${GODOT_ROOT_DIR}/*.c**)
+file(GLOB_RECURSE HEADERS ${GODOT_ROOT_DIR}/*.h**)
+
+add_executable(${PROJECT_NAME} ${SOURCES} ${HEADERS})
+target_include_directories(${PROJECT_NAME}
+ SYSTEM PUBLIC
+ ${GODOT_ROOT_DIR}
+ ${GODOT_ROOT_DIR}/modules/gdnative/include)
diff --git a/platform/android/java/nativeSrcsConfigs/README.md b/platform/android/java/nativeSrcsConfigs/README.md
new file mode 100644
index 0000000000..e48505ccda
--- /dev/null
+++ b/platform/android/java/nativeSrcsConfigs/README.md
@@ -0,0 +1,4 @@
+## Native sources configs
+
+This is a non functional Android library used to provide Android Studio editor support to the Godot project native files.
+Nothing else should be added to this library.
diff --git a/platform/android/java/nativeSrcsConfigs/build.gradle b/platform/android/java/nativeSrcsConfigs/build.gradle
new file mode 100644
index 0000000000..65b7bb9dc9
--- /dev/null
+++ b/platform/android/java/nativeSrcsConfigs/build.gradle
@@ -0,0 +1,54 @@
+// Non functional android library used to provide Android Studio editor support to the project.
+plugins {
+ id 'com.android.library'
+}
+
+android {
+ compileSdkVersion versions.compileSdk
+ buildToolsVersion versions.buildTools
+
+ defaultConfig {
+ minSdkVersion versions.minSdk
+ targetSdkVersion versions.targetSdk
+ }
+
+ compileOptions {
+ sourceCompatibility versions.javaVersion
+ targetCompatibility versions.javaVersion
+ }
+
+ packagingOptions {
+ exclude 'META-INF/LICENSE'
+ exclude 'META-INF/NOTICE'
+
+ // Should be uncommented for development purpose within Android Studio
+ // doNotStrip '**/*.so'
+ }
+
+ sourceSets {
+ main {
+ manifest.srcFile 'AndroidManifest.xml'
+ }
+ }
+
+ externalNativeBuild {
+ cmake {
+ path "CMakeLists.txt"
+ }
+ }
+
+ libraryVariants.all { variant ->
+ def buildType = variant.buildType.name.capitalize()
+
+ def taskPrefix = ""
+ if (project.path != ":") {
+ taskPrefix = project.path + ":"
+ }
+
+ // Disable the externalNativeBuild* task as it would cause build failures since the cmake build
+ // files is only setup for editing support.
+ gradle.startParameter.excludedTaskNames += taskPrefix + "externalNativeBuild" + buildType
+ }
+}
+
+dependencies {}