My Android build just started failing. I’m getting this error:
Error:
/Users/opx/vium/.meteor/local/cordova-build/platforms/android/gradlew:
Command failed with exit code 1 Error output:
/Users/opx/vium/.meteor/local/cordova-build/platforms/android/res/drawable-mdpi/screen.png:
error: failed to read PNG signature: file does not start with PNG
signature.
So, I just figured it out. Sort of. The problem message is correct – screen.png is actually a jpeg mistakenly named as a png. BUT!
Here’s my mobile-config.js. The file it’s complaining about is the last one listed in the AppendToConfig section. So, the big question – why is adding AppendToConfig for the new iOS splash methodology adding stuff to the Android build (really, the question should be why can’t I do iOS-only AppendToConfig), and more strangely, how does this file end up being the one Android chooses to put in the drawable-mdpi directory? Am I not going to be able to properly config iOS and Android simultaneously in mobile-config.js?
Thanks!
App.launchScreens({
'android_mdpi_portrait': 'splash/320x480.png',
'android_hdpi_portrait': 'splash/480x800.png',
'android_xhdpi_portrait': 'splash/720x1280.png',
'android_xxhdpi_portrait': 'splash/960x1600.png',
'android_xxxhdpi_portrait': 'splash/1280x1920.png'
// More screen sizes and platforms...
});
App.appendToConfig(`
<splash src="../../../splash/Default@2x~universal~anyany.png" />
<splash src="../../../splash/Default@3x~universal~anyany.png" />
<splash src="../../../splash/Default@2x~universal~comany.png" />
<splash src="../../../splash/Default@3x~universal~comany.png" />
`);