Browse Source

[android] Properly set Root of the Project

Signed-off-by: Caio Oliveira <caiooliveirafarias0@gmail.com>
android-root
Caio Oliveira 5 days ago
parent
commit
f20be5f1ba
No known key found for this signature in database GPG Key ID: AAAE6C7FD4186B0C
  1. 13
      src/android/app/build.gradle.kts
  2. 6
      src/android/settings.gradle.kts

13
src/android/app/build.gradle.kts

@ -18,6 +18,7 @@ plugins {
id("androidx.navigation.safeargs.kotlin") id("androidx.navigation.safeargs.kotlin")
id("org.jlleitschuh.gradle.ktlint") version "11.4.0" id("org.jlleitschuh.gradle.ktlint") version "11.4.0"
id("com.github.triplet.play") version "3.8.6" id("com.github.triplet.play") version "3.8.6"
id("idea")
} }
/** /**
@ -27,6 +28,8 @@ plugins {
*/ */
val autoVersion = (((System.currentTimeMillis() / 1000) - 1451606400) / 10).toInt() val autoVersion = (((System.currentTimeMillis() / 1000) - 1451606400) / 10).toInt()
val edenDir = project(":Eden").projectDir
@Suppress("UnstableApiUsage") @Suppress("UnstableApiUsage")
android { android {
namespace = "org.yuzu.yuzu_emu" namespace = "org.yuzu.yuzu_emu"
@ -241,11 +244,17 @@ android {
externalNativeBuild { externalNativeBuild {
cmake { cmake {
version = "3.22.1" version = "3.22.1"
path = file("../../../CMakeLists.txt")
path = file("${edenDir}/CMakeLists.txt")
} }
} }
} }
idea {
module {
// Inclusion to exclude build/ dir from non-Android
excludeDirs.add(file("${edenDir}/build"))
}
}
tasks.register<Delete>("ktlintReset", fun Delete.() { tasks.register<Delete>("ktlintReset", fun Delete.() {
delete(File(layout.buildDirectory.toString() + File.separator + "intermediates/ktLint")) delete(File(layout.buildDirectory.toString() + File.separator + "intermediates/ktLint"))
@ -346,7 +355,7 @@ fun getGitVersion(): String {
} }
afterEvaluate { afterEvaluate {
val artifactsDir = layout.projectDirectory.dir("../../../artifacts")
val artifactsDir = layout.projectDirectory.dir("${edenDir}/artifacts")
val outputsDir = layout.buildDirectory.dir("outputs").get() val outputsDir = layout.buildDirectory.dir("outputs").get()
android.applicationVariants.forEach { variant -> android.applicationVariants.forEach { variant ->

6
src/android/settings.gradle.kts

@ -1,3 +1,6 @@
// SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project
// SPDX-License-Identifier: GPL-3.0-or-later
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project // SPDX-FileCopyrightText: 2023 yuzu Emulator Project
// SPDX-License-Identifier: GPL-3.0-or-later // SPDX-License-Identifier: GPL-3.0-or-later
@ -19,3 +22,6 @@ dependencyResolutionManagement {
} }
include(":app") include(":app")
include("Eden")
project(":Eden").projectDir = file("../..")
Loading…
Cancel
Save