Reputation: 8870
As an academic exercise, I'm following this to build an Android app from the command line using just the android sdk.
I was wondering where in the Android SDK I could find the Android library to javac against? Otherwise, javac doesn't know where to find, for instance, android.app.Activity
. I think dx needs the library too right?
Upvotes: 1
Views: 2385
Reputation: 1006654
As an academic exercise, I'm following this to build an Android app from the command line using just the android sdk.
That blog post is from 2009. At the time of this writing, it is 2015. The build process has substantially changed since 2009.
I was wondering where in the Android SDK I could find the Android library to javac against?
$ANDROID_SDK/platforms/platform-NNN
, where $ANDROID_SDK
is wherever you have the Android SDK installed and NNN
is an API level (e.g., 21). In there, you will find an android.jar
file that contains the mocks of the Android SDK API that we compile against.
I looked at the docs on the Android page for creating a project through cli, but it would generate an Ant project?
I have heard that you can have a -g
switch to generate Gradle build files instead of Ant, but I haven't ever used it. Personally, I would just copy the Gradle build files from a known-working project and modify them to suit.
Upvotes: 2