Copy the ant dir and this build file to your project, or get it as a subrepo / remote.

Add the namespace for the maven ant tasks to your <project> tag:

     <project ... xmlns:artifact="antlib:org.apache.maven.artifact.ant">

Include this in your android build.xml like this:

     <import file="build-dependencies.xml"/>

Define dependencies ${dependency.fileset} is a defined property so you can use the default copy-dependencies task)

    <artifact:dependencies filesetId="${dependency.fileset}">
       <dependency groupId="" artifactId="crouton" version="1.7" />
       <dependency groupId="com.actionbarsherlock" artifactId="actionbarsherlock" version="4.2.0" type="apklib" />
       <dependency groupId="com.viewpagerindicator" artifactId="library" version="2.4.1" type="apklib" />
            ... other dependencies ...

Move any libraries that you want to manage yourself from "libs" to "extra"

From the command line call "ant copy-dependencies". This will:

  1. Clean the libs folder and copy all dependencies to libs
  2. Copy all jars in extra to libs (so you can override jars that are pulled in as dependency)
  3. Unpack any apklib to a subfolder in apklibs
  4. Replace android-support-v4.jar and -v13 in any apklib with the version found in libs

You can now import the library projects in apklib as usual.