Flutter build apk shows sdk location not found

281 views Asked by At

I customise the google map location picker and load it from my github repository now when I try to build file it shows me below error.

FAILURE: Build failed with an exception.

  • What went wrong: A problem occurred configuring root project 'google_map_location_picker'.

SDK location not found. Define location with an ANDROID_SDK_ROOT environment variable or by setting the sdk.dir path in your project's local properties file at '/Users/johnsmith/Developer/flutter/.pub-cache/git/google_map_location_picker-9319b89e3819c4363d6a3bd0e946544fa45018e8/android/local.properties'.

1

There are 1 answers

0
Muhamamad uzair On

Go to your flutter installation location and then go to the sdk folder and then add copy the path and then add this path on environmental variable of your PC. For Environmental Variable: This PC -> right click to properties -> A advanced system settings -> Environment variables.