I've attached the output of my "ant debug" run at the command line.
Unfortunately it exits with a build failure so I cannot ignore and continue.

On Wed, Feb 23, 2011 at 11:52 AM, Xavier Ducrohet <x...@android.com> wrote:

> It's not possible at this time to exclude them.
>
> I believe the error is actually only a warning, in which case you could
> ignore it?
>
>
> On Wed, Feb 23, 2011 at 6:51 AM, Ian <ian.d...@gmail.com> wrote:
>
>> Hi all,
>>
>> My Android project has multiple Android Library dependencies. Two of them
>> use the ORMlite JAR so they each have that JAR in their libs directory so we
>> can build the individual projects with Eclipse. However, when I try to build
>> the overall Android project with ant, the -dex step complains that the
>> classes from the ORMlite JAR were already added.
>>
>> I suppose this makes sense (since dex is adding the classes from the
>> dependencies, there are in fact two ormlite JARs whose classes are being
>> added), but is there a way to specify that these JARs should not be included
>> in the dex process?
>>
>> Thanks!
>>
>> --
>> 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
>
>
>
>
> --
> Xavier Ducrohet
> Android SDK Tech Lead
> Google Inc.
> http://developer.android.com | http://tools.android.com
>
> Please do not send me questions directly. Thanks!
>
>  --
> 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 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
$ ant debug
Buildfile: /home/iandees/AndroidWorkspace/AndrApp/build.xml
    [setup] Android SDK Tools Revision 8
    [setup] Project Target: Android 2.2
    [setup] API level: 8
    [setup] 
    [setup] ------------------
    [setup] Resolving library dependencies:
    [setup] /home/iandees/AndroidWorkspace/AndrApp: common => 
/home/iandees/AndroidWorkspace/AndrApp/common
    [setup] /home/iandees/AndroidWorkspace/AndrApp: map => 
/home/iandees/AndroidWorkspace/AndrApp/map
    [setup] /home/iandees/AndroidWorkspace/AndrApp: network => 
/home/iandees/AndroidWorkspace/AndrApp/network
    [setup] /home/iandees/AndroidWorkspace/AndrApp: map-domain => 
/home/iandees/AndroidWorkspace/AndrApp/map-domain
    [setup] /home/iandees/AndroidWorkspace/AndrApp: location/ => 
/home/iandees/AndroidWorkspace/AndrApp/location
    [setup] /home/iandees/AndroidWorkspace/AndrApp: domain-location/ => 
/home/iandees/AndroidWorkspace/AndrApp/domain-location
    [setup] /home/iandees/AndroidWorkspace/AndrApp/domain-location: 
../location/ => /home/iandees/AndroidWorkspace/AndrApp/location
    [setup] /home/iandees/AndroidWorkspace/AndrApp/map-domain: ../network => 
/home/iandees/AndroidWorkspace/AndrApp/network
    [setup] /home/iandees/AndroidWorkspace/AndrApp/map-domain: ../common => 
/home/iandees/AndroidWorkspace/AndrApp/common
    [setup] /home/iandees/AndroidWorkspace/AndrApp/map-domain: ../map => 
/home/iandees/AndroidWorkspace/AndrApp/map
    [setup] /home/iandees/AndroidWorkspace/AndrApp/map: ../network => 
/home/iandees/AndroidWorkspace/AndrApp/network
    [setup] /home/iandees/AndroidWorkspace/AndrApp/map: ../common => 
/home/iandees/AndroidWorkspace/AndrApp/common
    [setup] /home/iandees/AndroidWorkspace/AndrApp/map: ../network => 
/home/iandees/AndroidWorkspace/AndrApp/network
    [setup] /home/iandees/AndroidWorkspace/AndrApp/map: ../common => 
/home/iandees/AndroidWorkspace/AndrApp/common
    [setup] ------------------
    [setup] Ordered libraries:
    [setup] /home/iandees/AndroidWorkspace/AndrApp/map-domain
    [setup] /home/iandees/AndroidWorkspace/AndrApp/map
    [setup] /home/iandees/AndroidWorkspace/AndrApp/network
    [setup] /home/iandees/AndroidWorkspace/AndrApp/common
    [setup] /home/iandees/AndroidWorkspace/AndrApp/domain-location
    [setup] /home/iandees/AndroidWorkspace/AndrApp/location
    [setup] ------------------
    [setup] 
    [setup] WARNING: Attribute minSdkVersion in AndroidManifest.xml (4) is 
lower than the project target API level (8)
    [setup] 
    [setup] Importing rules file: tools/ant/main_rules.xml

-debug-obfuscation-check:

-set-debug-mode:

-compile-tested-if-test:

-dirs:
     [echo] Creating output directories if needed...

-pre-build:

-resource-src:
     [echo] Generating R.java / Manifest.java from the resources...

-aidl:
     [echo] Compiling aidl files into Java classes...

-pre-compile:

compile:
    [javac] /home/iandees/android-sdk-linux_86/tools/ant/main_rules.xml:361: 
warning: 'includeantruntime' was not set, defaulting to 
build.sysclasspath=last; set to false for repeatable builds
    [javac] Compiling 16 source files to 
/home/iandees/AndroidWorkspace/AndrApp/bin/classes

-post-compile:

-obfuscate:

-dex:
     [echo] Converting compiled files and external libraries into 
/home/iandees/AndroidWorkspace/AndrApp/bin/classes.dex...
    [apply] 
    [apply] UNEXPECTED TOP-LEVEL EXCEPTION:
    [apply] java.lang.IllegalArgumentException: already added: 
Lcom/j256/ormlite/android/AndroidCompiledStatement;
    [apply]     at 
com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:123)
    [apply]     at com.android.dx.dex.file.DexFile.add(DexFile.java:143)
    [apply]     at com.android.dx.command.dexer.Main.processClass(Main.java:338)
    [apply]     at 
com.android.dx.command.dexer.Main.processFileBytes(Main.java:315)
    [apply]     at com.android.dx.command.dexer.Main.access$100(Main.java:56)
    [apply]     at 
com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:266)
    [apply]     at 
com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:244)
    [apply]     at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:130)
    [apply]     at 
com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:108)
    [apply]     at com.android.dx.command.dexer.Main.processOne(Main.java:284)
    [apply]     at 
com.android.dx.command.dexer.Main.processAllFiles(Main.java:220)
    [apply]     at com.android.dx.command.dexer.Main.run(Main.java:176)
    [apply]     at com.android.dx.command.dexer.Main.main(Main.java:157)
    [apply]     at com.android.dx.command.Main.main(Main.java:89)
    [apply] 
    [apply] UNEXPECTED TOP-LEVEL EXCEPTION:
    [apply] java.lang.IllegalArgumentException: already added: 
Lcom/j256/ormlite/android/AndroidCompiledStatement;
    [apply]     at 
com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:123)
    [apply]     at com.android.dx.dex.file.DexFile.add(DexFile.java:143)
    [apply]     at com.android.dx.command.dexer.Main.processClass(Main.java:338)
    [apply]     at 
com.android.dx.command.dexer.Main.processFileBytes(Main.java:315)
    [apply]     at com.android.dx.command.dexer.Main.access$100(Main.java:56)
    [apply]     at 
com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:266)
    [apply]     at 
com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:244)
    [apply]     at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:130)
    [apply]     at 
com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:108)
    [apply]     at com.android.dx.command.dexer.Main.processOne(Main.java:284)
    [apply]     at 
com.android.dx.command.dexer.Main.processAllFiles(Main.java:220)
    [apply]     at com.android.dx.command.dexer.Main.run(Main.java:176)
    [apply]     at com.android.dx.command.dexer.Main.main(Main.java:157)
    [apply]     at com.android.dx.command.Main.main(Main.java:89)
    [apply] 2 errors; aborting

BUILD FAILED
/home/iandees/android-sdk-linux_86/tools/ant/main_rules.xml:449: The following 
error occurred while executing this line:
/home/iandees/android-sdk-linux_86/tools/ant/main_rules.xml:199: apply 
returned: 1

Total time: 17 seconds

Reply via email to