Thanks a lot for your suggestion, it seems to work.  I've put it in
custom_rules.xml.  I had to wrap it in <project> element as per this post

http://stackoverflow.com/questions/8528373/android-custom-build-using-ant

which results in a "Duplicated project name in import" warning.  It
nevertheless seems to build fine.


On Sat, Feb 23, 2013 at 12:34 PM, Kostya Vasilyev <kmans...@gmail.com>wrote:

> I've done this -- keeping ant builds completely separate from
> Eclipse's -- by hacking on the project's and the SDK's build.xml
> files.
>
> Not an ant expert either (last I used was some ten years ago), but it
> wasn't too difficult either.
>
> The modification that deals with library references (in the
> application project's build.xml) looks like this:
>
>         <target name="-pre-compile">
>                 <!-- Fix library references -->
>                 <!-- <path id="jar.libs.ref"> -->
>                 <path id="project.all.jars.path">
>                         <pathelement
> location="../AquaCompat/ant/bin/classes.jar" />
>                         <pathelement
> location="../AquaSupport/ant/bin/classes.jar" />
>                         <pathelement
> location="../AquaMailUnlockerLibrary/ant/bin/classes.jar" />
>                         <pathelement
> location="../LocalePlatform/ant/bin/classes.jar" />
>                         <pathelement
> location="../AmbilWarna/ant/bin/classes.jar" />
>                         <pathelement location="libs/htmlcleaner-2.2.jar" />
>                 </path>
>                 <echo>***** -pre-compile:
> project.all.jars.path="${toString:project.all.jars.path}"</echo>
>         </target>
>
> Oh, and I already filed a feature request for this a little over a year
> ago:
>
> https://code.google.com/p/android/issues/detail?id=23271
>
> Maybe it'll be possible "out of the box" with the new Gradle-based
> build system, who knows?
>
> -- K
>
> 2013/2/23 Latimerius <l4t1m3r...@gmail.com>:
> > Hello,
> >
> > I posted this on SO the day before yesterday (*) but since there have
> been
> > no replies posting here, too:
> >
> > I have an Android project which uses an Android library project as a
> > dependency.  Building it with ant works fine, I'd just like to have the
> > library project use a different bin directory.  However, when I add
> >
> > out.dir=bin-ant
> >
> > to the library project's ant.properties file, the (normal) Android
> project
> > won't compile anymore, issuing "cannot find symbol" errors for symbols
> > defined in the library.  Admittedly, I'm not very experienced with Ant
> but I
> > guess this means ant didn't find library's classes.jar which is now
> placed
> > in bin-ant/, not bin/ .  Does anybody happen to know how to tell ant
> where
> > to find the library's classes.jar?
> >
> > Thanks in advance!
> >
> >
> > (*)
> >
> http://stackoverflow.com/questions/15012527/ant-wont-build-android-project-which-depends-on-library-project-with-non-defaul
> >
> > --
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to android-developers@googlegroups.com
> > To unsubscribe from this group, send email to
> > android-developers+unsubscr...@googlegroups.com
> > For more options, visit this group at
> > http://groups.google.com/group/android-developers?hl=en
> > ---
> > You received this message because you are subscribed to the Google Groups
> > "Android Developers" group.
> > To unsubscribe from this group and stop receiving emails from it, send an
> > email to android-developers+unsubscr...@googlegroups.com.
> > For more options, visit https://groups.google.com/groups/opt_out.
> >
> >
>
> --
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Android Developers" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to android-developers+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to