You follow the following steps to write, no errors, in the middle because there is no Cordova-2.9.1.jar file, resulting in the construction of the project error, so step 2 is very important.
1, in the PHONEGAP official website (phonegap.com/install) Download the latest version (currently PhoneGap 2.9.1), download and unzip.
2, the new version of the PhoneGap 2.9.1,d:\phonegap-2.9.1\lib\android\framework is not Cordova-2.9.1.jar, so to compile it out.
1) Open the CMD command line tool.
2) Enter D:\phonegap-2.9.1\lib\android\framework in turn.
3) Enter "Android update project-p." -T android-19--subprojects "and enter, 19 is the version of my SDK, you can enter the Android enter on the command line to view the version of the SDK you installed and make the corresponding changes.
4) Enter the "Ant jar" command again. The generated Cordova-2.9.1.jar file is now in the framework directory.
3, add D:\adt-bundle-windows-x86-20131030\sdk\tool to the environment variable path.
4, then run the script, need ant command, no words to the official website (ant.apache.org) download, unzip. and add the D:\apache-ant-1.9.6\bin to the environment variable path.
5. Open cmd command line tool, execute D:\phonegap-2.9.1\lib\android\bin\create.bat D:\mycode\HelloPG com.gm.hellopg HELLOPG under Windows System, This creates the project HELLOPG under D:\mycode.
(where D:\phonegap-2.9.1\lib\android\bin\create.bat is the command statement, after the space, D:\mycode\HelloPG is the path of the project, after the space, COM.GM.HELLOPG is the name of the package, HELLOPG is the project name. ）
6, open the D:\adt-bundle-windows-x86-20131030\eclipse in the Eclipse.exe, Android development environment. The import already exists project (just the HELLOPG) file that we compiled the build.
Then assets directory under the directory of the WWW can be used html5+css+js do development.
Build PHONEGAP development environment under Android platform