Repository navigation
Expand file tree
/
Copy pathsettings.gradle
More file actions
49 lines (43 loc) · 1.82 KB
/
Copy pathsettings.gradle
File metadata and controls
49 lines (43 loc) · 1.82 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
pluginManagement {
// media3 (TMessagesProj_Modules/media, Telegram's fork) is an included build since 1.11.
includeBuild('TMessagesProj_Modules/media/build-logic-settings')
}
plugins {
id 'gradlebuild.media3-settings-logic'
}
include ':TMessagesProj'
include ':TMessagesProj_App'
include ':TMessagesProj_AppHuawei'
include ':TMessagesProj_AppHockeyApp'
include ':TMessagesProj_AppStandalone'
include ':TMessagesProj_AppTests'
// Third-party modules, kept in TMessagesProj_Modules (media3 is an included build there, below).
include ':TMessagesProj_Modules:webrtc'
include ':TMessagesProj_Modules:jlatexmath'
project(':TMessagesProj_Modules:jlatexmath').projectDir = file('TMessagesProj_Modules/jlatexmath/jlatexmath')
dependencyResolutionManagement {
repositories {
google()
mavenCentral()
}
}
// androidx.media3:media3-* dependencies resolve to the modules of the local checkout; their
// version numbers are ignored.
def media3Dir = file('TMessagesProj_Modules/media')
// The included build looks for the SDK in its own local.properties (git-ignored there).
// Mirror sdk.dir from ours; without it AGP falls back to ANDROID_HOME, as in the Docker build.
def rootLocalProperties = file('local.properties')
if (rootLocalProperties.exists()) {
def props = new Properties()
rootLocalProperties.withInputStream { props.load(it) }
def sdkDir = props.getProperty('sdk.dir')
if (sdkDir) {
def media3LocalProperties = new File(media3Dir, 'local.properties')
def content = "# Generated by the root settings.gradle from its local.properties.\n" +
"sdk.dir=" + sdkDir.replace('\\', '\\\\') + "\n"
if (!media3LocalProperties.exists() || media3LocalProperties.text != content) {
media3LocalProperties.text = content
}
}
}
includeMedia3.execute(media3Dir)