Skip to content

Help Wanted: Android build failing on CI #8878

Open

Description

@ocornut

Android CI seems to be failing for a reason I don't understand:
https://github.com/ocornut/imgui/actions/runs/16883878492

I am not building for Android myself.

Thanks!

Activity

  1. psyche314 commented on Aug 12, 2025

    @psyche314

    It looks like a bug inside the AGP plugin?

  2. psyche314 commented on Aug 12, 2025

    @psyche314

    Oh, I see. I tried Gradle 9.0 and it failed, but Gradle 8.14 succeeded. It seems the issue is caused by the Gradle version not being locked. You can use the gradle wrapper command to create gradlew and lock the Gradle version, or update the Gradle scripts to support the newer Gradle version.

    
    C:\Projects\ShortKebabCase\imgui\examples\example_android_opengl3\android>"C:\Users\Breaky\.gradle\wrapper\dists\gradle-9.0-milestone-1-bin\3vdepk4s12bybhohyuvjcm1bd\gradle-9.0-milestone-1\bin\gradle.bat" build
    
    Welcome to Gradle 9.0-milestone-1!
    
    For more details see https://docs.gradle.org/9.0-milestone-1/release-notes.html
    
    Starting a Gradle Daemon (subsequent builds will be faster)
    
    FAILURE: Build failed with an exception.
    
    * Where:
    Build file 'C:\Projects\ShortKebabCase\imgui\examples\example_android_opengl3\android\app\build.gradle' line: 1
    
    * What went wrong:
    A problem occurred evaluating project ':app'.
    > 'org.gradle.api.artifacts.Dependency org.gradle.api.artifacts.dsl.DependencyHandler.module(java.lang.Object)'
    
    * Try:
    > Run with --stacktrace option to get the stack trace.
    > Run with --info or --debug option to get more log output.
    > Run with --scan to get full insights.
    > Get more help at https://help.gradle.org.
    
    BUILD FAILED in 5s
    
    
    C:\Projects\ShortKebabCase\imgui\examples\example_android_opengl3\android>set JAVA_HOME=C:\Program Files\Java\jdk-17
    
    C:\Projects\ShortKebabCase\imgui\examples\example_android_opengl3\android>"C:\Users\Breaky\.gradle\wrapper\dists\gradle-8.14-bin\38aieal9i53h9rfe7vjup95b9\gradle-8.14\bin\gradle.bat" build
    Starting a Gradle Daemon, 2 incompatible Daemons could not be reused, use --status for details
    
    > Task :app:lintReportDebug
    Wrote HTML report to file:///C:/Projects/ShortKebabCase/imgui/examples/example_android_opengl3/android/app/build/reports/lint-results-debug.html
    
    [Incubating] Problems report is available at: file:///C:/Projects/ShortKebabCase/imgui/examples/example_android_opengl3/android/build/reports/problems/problems-report.html
    
    Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.
    
    You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
    
    For more on this, please refer to https://docs.gradle.org/8.14/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.
    
    BUILD SUCCESSFUL in 33s
    103 actionable tasks: 42 executed, 61 up-to-date
    C:\Projects\ShortKebabCase\imgui\examples\example_android_opengl3\android>
    

    Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

    This warning is caused by the use of deprecated features and should be noted.

  3. ocornut commented on Aug 12, 2025

    @ocornut
    OwnerAuthor

    or update the Gradle scripts to support the newer Gradle version.

    That would be better. Do you think you could help with it?

  4. psyche314 commented on Aug 13, 2025

    @psyche314

    or update the Gradle scripts to support the newer Gradle version.

    That would be better. Do you think you could help with it?

    I tried to use GradleVersion.current() to check whether the Gradle version has reached 9.0, and if so, use the new Gradle syntax. However, on Gradle 9.0, the old syntax causes the script itself to fail to compile. It seems that, unlike C++'s if constexpr, selective compilation is not possible, so I don’t know how to modify it without breaking compatibility with older Gradle versions.

  5. ocornut commented on Aug 19, 2025

    @ocornut
    OwnerAuthor

    Fixed by 361e370 + 6556011

  6. ocornut commented on Jun 25, 2026

    @ocornut
    OwnerAuthor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      ⌂ 换网址