I've successfully built app for android in cordova in ubuntu 14.04. However, I got error while I was trying to run cordova build ubuntu in project folder, which is as following:
ERROR building one of the platforms: Error: /home/ninger/cordova/vfinder/platforms/ubuntu/cordova/build: Command failed with exit code 1
You may not have the required environment or OS to build this project
Error: /home/ninger/cordova/vfinder/platforms/ubuntu/cordova/build: Command failed with exit code 1
at ChildProcess.whenDone (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/cordova/superspawn.js:131:23)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:743:16)
at Process.ChildProcess._handle.onexit (child_process.js:810:5)
After run cordova -d run ubuntu, I got the verbose output as following, almost the same hints:
missing icon element in config.xml
Generating config.xml from defaults for platform "ubuntu"
Calling plugman.prepare for platform "ubuntu"
Preparing ubuntu project
Processing configuration changes for plugins.
Iterating over installed plugins: [ 'cordova-plugin-whitelist' ]
Writing out cordova_plugins.js...
missing icon element in config.xml
Running command:/home/ninger/cordova/test/platforms/ubuntu/cordova/run
Building Desktop Application...
Missing icon
Command finished with error code 1:/home/ninger/cordova/test/platforms/ubuntu/cordova/run
ERROR running one or more of the platforms: Error: /home/ninger/cordova/test/platforms/ubuntu/cordova/run: Command failed with exit code 1
You may not have the required environment or OS to run this project
cordova -d run <platform>for a verbose output when running. – Guillem Vicens May 14 '15 at 6:17