I\'ve spent a lot of time trying to work this out to no avail.
I udpated cordova and since el capitan my mac now has issues with NPM and cordova.
I got it to
After digging into cordova_lib I think it's clear (to me) that cordova is not supposed to resize the icon for you but only copy them if they exist and have the right dimensions.
See this code in cordova-lib\src\cordova\metadata\ios_parser.js:
// See https://developer.apple.com/library/ios/documentation/userexperience/conceptual/mobilehig/LaunchImages.html
// for launch images sizes reference.
var platformIcons = [
{dest: 'icon-60.png', width: 60, height: 60},
{dest: 'icon-60@2x.png', width: 120, height: 120},
{dest: 'icon-60@3x.png', width: 180, height: 180},
{dest: 'icon-76.png', width: 76, height: 76},
{dest: 'icon-76@2x.png', width: 152, height: 152},
{dest: 'icon-small.png', width: 29, height: 29},
{dest: 'icon-small@2x.png', width: 58, height: 58},
{dest: 'icon-40.png', width: 40, height: 40},
{dest: 'icon-40@2x.png', width: 80, height: 80},
{dest: 'icon.png', width: 57, height: 57},
{dest: 'icon@2x.png', width: 114, height: 114},
{dest: 'icon-72.png', width: 72, height: 72},
{dest: 'icon-72@2x.png', width: 144, height: 144},
{dest: 'icon-50.png', width: 50, height: 50},
{dest: 'icon-50@2x.png', width: 100, height: 100}
];
var destIconsFolder, destSplashFolder;
var xcassetsExists = folderExists(path.join(platformRoot, 'Images.xcassets/'));
if (xcassetsExists) {
destIconsFolder = 'Images.xcassets/AppIcon.appiconset/';
} else {
destIconsFolder = 'Resources/icons/';
}
platformIcons.forEach(function (item) {
var icon = icons.getBySize(item.width, item.height) || icons.getDefault();
if (icon){
var src = path.join(appRoot, icon.src),
dest = path.join(platformRoot, destIconsFolder, item.dest);
events.emit('verbose', 'Copying icon from ' + src + ' to ' + dest);
shell.cp('-f', src, dest);
}
});
The best option seems to be using a plugin which does the resizing for you with hooks. Check out Generating iOS and Android icons in Cordova / PhoneGap or https://github.com/disusered/cordova-icon-gm for a new more futureproof version of the same plugin (hooks in directories are deprecated in 6.x).