PhoneGap + xcode5.0.2 Configuration development environment

Source: Internet
Author: User


PHONEGAP Official website: http://phonegap.com/

Part One: Installation Nodejs


Installation Address: http://nodejs.org/

Install PhoneGap official website Download http://phonegap.com/install/


$ sudo npm install-g phonegap This installation may be slower, patiently waiting for the next


Installation Successful

Usr/local/bin/phonegap-/usr/local/lib/node_modules/phonegap/bin/phonegap.js


Phonegap@3.4.0-0.19.11/usr/local/lib/node_modules/phonegap


├──pluralize@0.0.4


├──colors@0.6.0-1


├──semver@1.1.0


├──qrcode-terminal@0.9.4


├──shelljs@0.1.4


├──optimist@0.6.0 (wordwrap@0.0.2, minimist@0.0.8)


├──phonegap-build@0.8.4 (qrcode-terminal@0.8.0, optimist@0.3.7, shelljs@0.0.9, phonegap-build-api@0.3.3)


├──prompt@0.2.11 (revalidator@0.1.6, pkginfo@0.3.0, read@1.0.5, utile@0.2.1, winston@0.6.2)


├──cordova@3.4.0-0.1.2 (mime@1.2.11, q@0.9.7, semver@2.0.11, underscore@1.4.4, plist-with-patches@0.5.1, xcode@0.6.6 , elementtree@0.1.5, npmconf@0.1.13, tar@0.1.19, request@2.21.0, plugman@0.20.1)


└──connect-phonegap@0.8.3 (home-dir@0.1.2, connect-inject@0.3.2, address@0.0.3, shelljs@0.2.6, request-progress@0.3.1, node-static@0.7.0, tar@0.1.19, useragent@2.0.8, request@2.33.0, gaze@0.4.3, connect@2.12.0)

The second section modifies local folder permissions


sudo chown-r $USER/usr/local

sudo chmod-r 0775/usr/local



Part III

NPM install-g Cordova



Fourth part

Cd/usr/local/lib/node_modules/phonegap/lib/phonegap


$ phonegap Create My-app

Installation Successful

[PhoneGap] Missing library phonegap/www/3.4.0

[PhoneGap] Downloading https://github.com/phonegap/phonegap-app-hello-world/archive/3.4.0.tar.gz ...

[PhoneGap] the options Undefined/usr/local/lib/node_modules/phonegap/lib/phonegap/my-app Com.phonegap.helloworld HelloWorld

[PhoneGap] Created project At/usr/local/lib/node_modules/phonegap/lib/phonegap/my-app


Localhost:my-app lsr$ ls

Hooks merges Platformspluginswww

HTML/JS/CSS is stored in www directory.

and a res subdirectory. Where the Res directory holds icons and splash screens for multiple platforms.

The platforms directory is currently empty, and a project catalog will be added to this directory when building multiple platforms.

The plugins directory is currently empty and will be downloaded to this directory when a plugin is added.


Fifth part

PhoneGap Run iOS


Created successfully

Detecting IOS SDK Environment ...


[PhoneGap] using the local environment


[PhoneGap] Adding the IOS platform ...


[PhoneGap] Missing library cordova/ios/3.4.0


[PhoneGap] Downloading https://git-wip-us.apache.org/repos/asf?p=cordova-ios.git;a=snapshot;h=3.4.0;sf=tgz ...


[PhoneGap] Compiling IOS ...


Build settings from command line:


Archs = i386


Configuration_build_dir =/usr/local/lib/node_modules/phonegap/lib/phonegap/my-app/platforms/ios/build/emulator


Sdkroot = iphonesimulator7.0


Valid_archs = i386




= = = BUILD TARGET cordovalib of PROJECT cordovalib with CONFIGURATION Debug = = =



* * BUILD SUCCEEDED * *




[PhoneGap] successfully compiled IOS app


[PhoneGap] Trying to install app onto device


Error:ios-deploy is not found. Download, build and install version 1.0.4 or greater from Https://github.com/phonegap/ios-deploy to your path. Or ' npm install-g ios-deploy ' using node.js:http://nodejs.org/


[PhoneGap] No device was found


[PhoneGap] Trying to install app onto emulator


[WARNING] missing Ios-sim


[WARNING] install Ios-sim from Http://github.com/phonegap/ios-sim


Error:ios-sim is not found. Download, build and install version 1.7 or greater from Https://github.com/phonegap/ios-sim to your path. Or ' npm install-g ios-sim ' using node.js:http://nodejs.org/


[ERROR]/usr/local/lib/node_modules/phonegap/lib/phonegap/my-app/platforms/ios/cordova/run:command failed with Exit code 1



We're opening the project in the Platforms folder.







Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.