if (locations != null && locations.length > 0) {
IFile pkgInfoFile = locations[0].getFile(new Path(PACKAGEINFO));
try {
ByteArrayInputStream input = new ByteArrayInputStream(pkg.formatVersionSpec().getBytes("UTF-8"));
pkgInfoFile.create(input, false, progress.newChild(1, 0));
} catch (CoreException e) {
status.add(new Status(IStatus.ERROR, Plugin.PLUGIN_ID, 0, "Error creating file " + pkgInfoFile.getFullPath(), e));
} catch (UnsupportedEncodingException e) {
/* just ignore, should never happen */
}