Thanks for asking this question here!
The official solution: You can find more info at the link printed in the log (http://d.android.com/r/studio-ui/export-licenses.html), but in short this can be done by:
Locate the licenses on your Mac/PC:
If you have accepted the license agreements on one workstation, but wish to build your projects on a different one,
you can export your licenses by copying the accepted licenses folder from the Android Sdk Home
folder (this should be located at
<android sdk home path>/licenses) of your current workstation,
to the Android Sdk Home directory of the machine where you now want to build your projects.
- Create an
android-licenses directory in the root directory of your git repository, and copy the license files into this directory from your Mac/PC.
- Then in your Workflow on bitrise.io copy the licenses to the right location using a
Script step right after the
Git Clone step (that’s when your code is available on the build virtual machine), with the content:
# fail if any commands fails
# debug log
mkdir -p "$ANDROID_HOME/licenses"
rsync -avhP ./android-licenses/ "$ANDROID_HOME/licenses/"
That’s all, this script copies the licenses from the
android-licenses (from your repository) into the system’s Android SDK Home path under
You can find more information and alternative solutions here: http://devcenter.bitrise.io/android/frequent-android-issues/#could-not-find-an-android-package-or-you-have-not-accepted-the-license-agreements , but the solution above is the current official solution (the “learn how to transfer the license agreements from one workstation to another” message in the log is not a Bitrise error/log, it comes from gradle and the Android tools).