Files
media/build.gradle
tonihei b3d452a567 Fix Protobuf gradle setup
The current setup fails to run from the command line in some
cases before the protobuf plugin is applied too early.

The correct setup is to declare the plugin as a dependency in
the high-level build.gradle file and then simply load the
plugin after initializing the shared module settings. This
matches how the Kotlin Gradle plugin is set up as well.

PiperOrigin-RevId: 837458389
(cherry picked from commit b7e2fe1485)
2026-01-22 15:25:29 +00:00

46 lines
1.5 KiB
Groovy

// Copyright (C) 2016 The Android Open Source Project
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
buildscript {
repositories {
google()
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:8.12.3'
classpath 'com.google.android.gms:strict-version-matcher-plugin:1.2.4'
classpath 'org.jetbrains.kotlin:kotlin-gradle-plugin:2.0.20'
classpath 'org.jetbrains.kotlin:compose-compiler-gradle-plugin:2.0.20'
classpath 'com.google.protobuf:protobuf-gradle-plugin:0.9.5'
}
}
allprojects {
repositories {
google()
mavenCentral()
maven {
url 'https://jitpack.io'
content {
includeGroup "com.github.philburk"
}
}
}
if (it.hasProperty('externalBuildDir')) {
if (!new File(externalBuildDir).isAbsolute()) {
externalBuildDir = new File(rootDir, externalBuildDir)
}
buildDir = "${externalBuildDir}/${project.name}"
}
group = 'androidx.media3'
}