Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compatibility with Gradle 9 ? #1949

Open
1 task
JJSarrasin opened this issue Dec 3, 2024 · 1 comment
Open
1 task

Compatibility with Gradle 9 ? #1949

JJSarrasin opened this issue Dec 3, 2024 · 1 comment
Assignees

Comments

@JJSarrasin
Copy link

Version

Media3 1.5.0

More version details

I upgrade my project containing media3 to Gradle 8.11.
A lot of warning during compilation appear in the media3 part of the project.
I'm not a gradle expert, maybe some of them are related to my configuration. But I expect other to be raised as errors in Gradle 9 because of this comment: "Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0."

Gradle 9 is expected to be available in Q1 2025

Task :media3-lib-common:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.

Task :media3-lib-decoder:extractDeepLinksDebug FROM-CACHE

Task :media3-lib-database:processDebugManifest
package="androidx.media3.database" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/database/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.database" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/database/src/main/AndroidManifest.xml.

Task :media3-lib-exoplayer:extractDeepLinksDebug FROM-CACHE

Task :media3-lib-datasource-okhttp:processDebugManifest
package="androidx.media3.datasource.okhttp" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/datasource_okhttp/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.datasource.okhttp" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/datasource_okhttp/src/main/AndroidManifest.xml.

Task :media3-lib-exoplayer-dash:extractDeepLinksDebug FROM-CACHE

Task :media3-lib-common:processDebugManifest
package="androidx.media3.common" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/common/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.common" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/common/src/main/AndroidManifest.xml.

Task :media3-lib-container:processDebugManifest
package="androidx.media3.container" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/container/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.container" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/container/src/main/AndroidManifest.xml.

Task :media3-lib-exoplayer-hls:extractDeepLinksDebug FROM-CACHE
Task :media3-lib-exoplayer-smoothstreaming:extractDeepLinksDebug FROM-CACHE
Task :media3-lib-extractor:extractDeepLinksDebug FROM-CACHE

Task :media3-lib-datasource:processDebugManifest
package="androidx.media3.datasource" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/datasource/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.datasource" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/datasource/src/main/AndroidManifest.xml.

Task :media3-lib-ui:extractDeepLinksDebug FROM-CACHE

Task :media3-lib-exoplayer-smoothstreaming:processDebugManifest
package="androidx.media3.exoplayer.smoothstreaming" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/exoplayer_smoothstreaming/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.exoplayer.smoothstreaming" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/exoplayer_smoothstreaming/src/main/AndroidManifest.xml.

Task :media3-lib-extractor:processDebugManifest
package="androidx.media3.extractor" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/extractor/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.extractor" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/extractor/src/main/AndroidManifest.xml.

Task :media3-lib-exoplayer:processDebugManifest
package="androidx.media3.exoplayer" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/exoplayer/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.exoplayer" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/exoplayer/src/main/AndroidManifest.xml.

Task :media3-lib-common:compileDebugJavaWithJavac
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.

Task :media3-lib-exoplayer-dash:processDebugManifest
package="androidx.media3.exoplayer.dash" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/exoplayer_dash/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.exoplayer.dash" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/exoplayer_dash/src/main/AndroidManifest.xml.

Task :media3-lib-decoder:processDebugManifest
package="androidx.media3.decoder" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/decoder/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.decoder" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/decoder/src/main/AndroidManifest.xml.

Task :media3-lib-ui:processDebugManifest
package="androidx.media3.ui" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/ui/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.ui" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/ui/src/main/AndroidManifest.xml.

Task :media3-lib-exoplayer-hls:processDebugManifest
package="androidx.media3.exoplayer.hls" found in source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/exoplayer_hls/src/main/AndroidManifest.xml.
Setting the namespace via the package attribute in the source AndroidManifest.xml is no longer supported, and the value is ignored.
Recommendation: remove package="androidx.media3.exoplayer.hls" from the source AndroidManifest.xml: /Users//Documents/Android/media3/libraries/exoplayer_hls/src/main/AndroidManifest.xml.

Task :media3-lib-common:compileDebugJavaWithJavac
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
4 warnings

Task :media3-lib-common:compileDebugJavaWithJavac
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
4 warnings

Task :media3-lib-common:bundleLibCompileToJarDebug

Task :media3-lib-container:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
warning: unknown enum constant MigrationStatus.STRICT
reason: class file for kotlin.annotations.jvm.MigrationStatus not found
4 warnings

Task :media3-lib-database:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
3 warnings

Task :media3-lib-decoder:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
warning: unknown enum constant MigrationStatus.STRICT
reason: class file for kotlin.annotations.jvm.MigrationStatus not found
4 warnings

Task :media3-lib-datasource:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.

Task :media3-lib-extractor:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.

Task :media3-lib-datasource:compileDebugJavaWithJavac
3 warnings

Task :media3-lib-ui:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
3 warnings

Task :media3-lib-datasource:bundleLibCompileToJarDebug
Task :media3-lib-datasource:bundleLibRuntimeToJarDebug

Task :media3-lib-extractor:compileDebugJavaWithJavac
warning: unknown enum constant When.MAYBE
reason: class file for javax.annotation.meta.When not found

Task :media3-lib-ui:bundleLibRuntimeToJarDebug
Task :media3-lib-ui:bundleLibCompileToJarDebug

Task :media3-lib-datasource-okhttp:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
warning: unknown enum constant Level.FULL
reason: class file for com.google.j2objc.annotations.ReflectionSupport$Level not found
4 warnings

Task :media3-lib-datasource-okhttp:bundleLibRuntimeToJarDebug

Task :media3-lib-extractor:compileDebugJavaWithJavac
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
4 warnings

Task :media3-lib-exoplayer:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release

Task :media3-lib-exoplayer:compileDebugJavaWithJavac
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
warning: unknown enum constant Level.FULL
reason: class file for com.google.j2objc.annotations.ReflectionSupport$Level not found

Task :media3-lib-exoplayer:compileDebugJavaWithJavac
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
4 warnings

Task :media3-lib-exoplayer:bundleLibCompileToJarDebug
Task :media3-lib-exoplayer:bundleLibRuntimeToJarDebug

Task :media3-lib-exoplayer-smoothstreaming:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
warning: unknown enum constant When.MAYBE
reason: class file for javax.annotation.meta.When not found
Note: /Users//Documents/Android/media3/libraries/exoplayer_smoothstreaming/src/main/java/androidx/media3/exoplayer/smoothstreaming/SsMediaSource.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
4 warnings

Task :media3-lib-exoplayer-smoothstreaming:bundleLibRuntimeToJarDebug
Task :media3-lib-exoplayer-smoothstreaming:bundleLibCompileToJarDebug

Task :media3-lib-exoplayer-hls:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
warning: unknown enum constant When.MAYBE
reason: class file for javax.annotation.meta.When not found
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
4 warnings

Task :media3-lib-exoplayer-dash:compileDebugJavaWithJavac
Java compiler version 21 has deprecated support for compiling with source/target version 8.
Try one of the following options:
1. [Recommended] Use Java toolchain with a lower language version
2. Set a higher source/target version
3. Use a lower version of the JDK running the build (if you're not using Java toolchain)
For more details on how to configure these settings, see https://developer.android.com/build/jdks.
To suppress this warning, set android.javaCompile.suppressSourceTargetDeprecationWarning=true in gradle.properties.
warning: [options] source value 8 is obsolete and will be removed in a future release
warning: [options] target value 8 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
warning: unknown enum constant When.MAYBE
reason: class file for javax.annotation.meta.When not found
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
4 warnings

Task :media3-lib-exoplayer-dash:bundleLibCompileToJarDebug
Task :media3-lib-exoplayer-dash:bundleLibRuntimeToJarDebug
Task :media3-lib-exoplayer-hls:bundleLibCompileToJarDebug
Task :media3-lib-exoplayer-hls:bundleLibRuntimeToJarDebug

Devices that reproduce the issue

All

Devices that do not reproduce the issue

No response

Reproducible in the demo app?

Yes

Reproduction steps

Build with Gradle 8.11 and see the build output.

Expected result

no warning/errors

Actual result

warnings

Media

Bug Report

  • You will email the zip file produced by adb bugreport to [email protected] after filing this issue.
@rohitjoins
Copy link
Contributor

Hi @JJSarrasin,

Thank you for reporting this and bringing it to our attention! These appear to be warnings, some of which can be suppressed if needed. We’ll address these as part of our Gradle version upgrade.

I'll keep the issue open until then.

@rohitjoins rohitjoins removed the bug label Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants