Hello, spachner! Thanks many times for your help! It works great!!! But I have a question about build.xml file. Should I specify something in "depends" properties of <target> tag? Could you recommend some good article about build.xml?
I am new on Eclipse. Thanks))) On 2 Кві, 13:25, spachner <[email protected]> wrote: > On 2 Apr., 10:58, Tatyana Ulyanova <[email protected]> wrote: > > > Hello, friends! > > > I using Eclipse Gallileo to develop Android application and Java > > library for this application. > > Please, help to set Android application dependency from my custom Java > > library rightly. I want this library automatically build if necessary > > and be included to .apk file. > > > Much appreciate for any help :)) > > Hi, > > first you need a Eclipse project for the library and you have to > advice Eclipse to generate on each modification a jar for the custom > library. For that you need a little ant script which look like this: > > <?xml version="1.0" encoding="UTF-8"?> > <!-- > ====================================================================== > > ====================================================================== > --> > <project name="project" default="default" basedir="."> > <description> > description > </description> > > <!-- ================================= > target: default > ================================= --> > <target name="default" depends="depends" > description="description"> > > <jar destfile="YourCustomLib.jar"> > <fileset dir="bin" includes="**/*.class" /> > <fileset dir="src" includes="**/*.java" /> > </jar> > </target> > > <!-- - - - - - - - - - - - - - - - - - > target: depends > - - - - - - - - - - - - - - - - - --> > <target name="depends"> > </target> > > </project> > > Name that ant script e.g. build.xml and put this file somewehre into > the project directory. Under "Project Properties/Builders" make a new > Ant Builder and put them at the end of the builder list (if there are > any). Use as build file the mentioned build.xml. > > Next you can add the YourCustomLib.jar to your Android project with > "Configure Build Path/Library/Add Jar". With this Eclipse checks > automatically whether the Android .pkg hat to be rebuild based on > library changes. > > That's it. > > regards > > spachner -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

