Skip to content
This repository has been archived by the owner on Jul 29, 2021. It is now read-only.

Update Android build with gradle plugin version 4.0.0 #299

Closed
wants to merge 1 commit into from

Conversation

ggfan
Copy link
Contributor

@ggfan ggfan commented Jul 7, 2020

A few of things:

  1. although prompted by Existing gradlew breaks with Java version 14 #298, this PR is NOT a fix, we like to keep the gradle version tied with android gradle plugin version 4.0.0 -- Gradle 6.1.1, we know this was tested and less surprises
  2. Fixed NDK version in build.gradle to the lastest one NOW: "21.3.6528147". CI needs to install this version of NDK. If NDK version is not specified, a default built-in ndk version will be requested and you need to manually install it.
  3. current way getting ndkDir does not work with Android Studio /Android Gradle Plugin 4.0.0, and fixed in this PR. this one probably is the only one that matters

@ggfan ggfan force-pushed the android-build-update branch 3 times, most recently from cf64690 to ddbec78 Compare July 8, 2020 01:15
Copy link
Contributor

@TonyBarbour TonyBarbour left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - thanks @ggfan Is there anything that can be done about all the Google Play store warnings?

@ggfan
Copy link
Contributor Author

ggfan commented Jul 9, 2020

looks like CI is building for arm7, changing it to arm64-v8a might help. The problem is that my linux machine is down on campus ( I am WFH ), once it is booted again I could try more.

Just added the above change to the CL, let's see how CI goes. Cody might need to review the CI changes: could we totally bypass NDK 15 install?

@cnorthrop
Copy link
Contributor

Tony, I don't think there's active development on these samples any more right? They are old enough you could probably switch to the defaults available from Travis, rather than downloading the NDK each time. Same for gradle I think, per a quick scan of this document:
https://guides.gradle.org/executing-gradle-builds-on-travisci/

@cnorthrop
Copy link
Contributor

Actually, these are periodically rolled into Google's samples here (https://github.com/googlesamples/vulkan-basic-samples/commits/master) so it makes sense to support newer toolchains. You can probably go with with these changes. Thanks Gerry!

Does anything in BUILD.md need to be updated for the versions?

@TonyBarbour
Copy link
Contributor

Just tried the change to arm64-v8a and all the play store warnings go away. Everyone oh with that change?

@TonyBarbour
Copy link
Contributor

Nothing to do in BUILD.md. Pushed this and a change to the ABI used in Travis.

@TonyBarbour TonyBarbour closed this Jul 9, 2020
@ggfan
Copy link
Contributor Author

ggfan commented Jul 10, 2020

yeah, I think we could drop a line or two inside BUILD.md, and I will give it a shot. Once checked in this PR ( Studio 4.0.0 version ), the behavior is:

  • a specific NDK version is needed as configured inside app's build.gradle
  • studio will prompt to download, but on command line, it needs to be pre-downloaded

Studio 4.2.0+ will auto-download a default NDK version to use, only if not configuring a NDK version to use.
NDK will be installed inside $SDK/ndk/$ndkversion directory ( the last part, $ndkVersion, could be any name ), my thought would be: go ahead update current sample with 4.0.0.

Just need to confirm that CI could take it if we comment out NDK-r15 version ( which is current version )

@ggfan
Copy link
Contributor Author

ggfan commented Jul 10, 2020

Oh I missed that it is already merged. thank you!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants