Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How Can I Get Started with PhoneGap in Eclipse? [closed]

Tags:

Trying to create my first PhoneGap project in eclipse. I have followed the Getting Started tutorial but that only seems to help in a best case scenario. My guess is that if they make the tutorials vague enough people will pay them for adequate help.

Following this tutorial: Getting Started with Android

When I run the create command I get the following error (see below). My guess that my environment is not ready. I have installed the Android SDK, I have the Java SDK installed and in my path. The only part that I am not clear on is the Apache Ant. I thought that was installed along with Eclipse?

Missing one of the following: JDK: http://java.oracle.com Android SDK: http://developer.android.com Apache ant: http://ant.apache.org 

What do I need to do to fix this problem and successfully create a PhoneGap project in Eclipse?

like image 705
JBeckton Avatar asked Nov 02 '12 02:11

JBeckton


1 Answers

I'm assuming you're on Windows because I just finished resolving the same error.

What I did:

  • Install the latest JDK [1]
  • Install Apache Ant binary [2]
  • Install Android SDK [3]

After all of those were installed I appended the below paths to my Path system variable which can be found at:

Control Panel > System > Advanced System Settings > Advanced tab > Environment Variables button > System variables

C:\Program Files\Java\jdk1.7.0_09\bin;C:\Users\Rob\Documents\apache-ant-1.8.4\bin;C:\Program Files (x86)\Android\android-sdk\tools

Be aware that my username is in those paths so yours will be different. Don't forget the semi-colon between the existing path and what you will be adding.

Depending on your usage of the above tools, it may be cleaner to add the path to the create.bat script.

  1. http://www.oracle.com/technetwork/java/javase/downloads/index.html
  2. http://ant.apache.org/bindownload.cgi
  3. http://developer.android.com/sdk/index.html
like image 190
Rob Olmos Avatar answered Oct 11 '22 18:10

Rob Olmos