Hi Ionic,
Since the update to the new app-scripts@0.0.39, I have had problems building with ionic package build android --profile prod --release
:
You have been opted out of telemetry. To change this, run: cordova telemetry on.
ANDROID_HOME=/usr/local/src/android-sdk-linux
JAVA_HOME=/usr/lib/jvm/java-8-oracle
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'android'.
> Could not resolve all dependencies for configuration ':_debugCompile'.
> Could not find any version that matches com.google.android.gms:play-services-gcm:9.8+.
Searched in the following locations:
https://repo1.maven.org/maven2/com/google/android/gms/play-services-gcm/maven-metadata.xml
https://repo1.maven.org/maven2/com/google/android/gms/play-services-gcm/
file:/usr/local/src/android-sdk-linux/extras/android/m2repository/com/google/android/gms/play-services-gcm/maven-metadata.xml
file:/usr/local/src/android-sdk-linux/extras/android/m2repository/com/google/android/gms/play-services-gcm/
file:/usr/local/src/android-sdk-linux/extras/google/m2repository/com/google/android/gms/play-services-gcm/maven-metadata.xml
Required by:
:android:unspecified
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 2.939 secs
Error: Error code 1 for command: /home/package/workspace/apps-abae991f-67/cordova/platforms/android/gradlew with args: cdvBuildRelease,-b,/home/package/workspace/apps-abae991f-67/cordova/platforms/android/build.gradle,-Dorg.gradle.daemon=true,-Pandroid.useDeprecatedNdk=true
My config.xml
plugins:
<plugin name="cordova-plugin-device" spec="~1.1.3"/>
<plugin name="cordova-plugin-console" spec="~1.0.4"/>
<plugin name="cordova-plugin-whitelist" spec="~1.3.0"/>
<plugin name="cordova-plugin-statusbar" spec="~2.2.0"/>
<plugin name="ionic-plugin-keyboard" spec="~2.2.1"/>
<plugin name="cordova-plugin-network-information" spec="~1.3.0"/>
<plugin name="phonegap-plugin-push" spec="~1.8.4">
<variable name="SENDER_ID" value="**************"/>
</plugin>
<plugin name="cordova-plugin-splashscreen" spec="~3.2.2"/>
<plugin name="cordova-plugin-camera" spec="~2.2.0"/>
This fails for both development and production builds. Running ionic run android
or ionic build android --release
works fine. My guess is an updated Google Support Repo?
On a sidenote, iOS .ipa files are building just fine.