Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8314693
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T20:54:28+00:00 2026-06-08T20:54:28+00:00

PREAMBLE: since SDK level 16, Android has a built-in Zeroconf implementation. Unless bronze age

  • 0

PREAMBLE: since SDK level 16, Android has a built-in Zeroconf implementation. Unless bronze age compatibility is a concern, don’t use jmDNS anymore, use NsdManager instead.


PREAMBLE #2: early versions of NsdManager are full of glitches, see SO question getSystemService(Context.NSD_SERVICE) freezes the 5.0 emulator and the linked bug records.


I’ve added jmDNS 3.4.1 to my Android project. Copied the JAR under lib, then under “Java BuildPath”/Libraries added a reference.

Now my build fails with the following message in Console:

[2012-07-27 22:59:07 - Yarxi] Dx 
UNEXPECTED TOP-LEVEL EXCEPTION:
java.lang.IllegalArgumentException: already added: Lcom/strangeberry/jmdns/tools/Browser$1;
at 

com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:123)
    at com.android.dx.dex.file.DexFile.add(DexFile.java:163)
    at com.android.dx.command.dexer.Main.processClass(Main.java:486)
    at com.android.dx.command.dexer.Main.processFileBytes(Main.java:455)
    at com.android.dx.command.dexer.Main.access$400(Main.java:67)
    at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:394)
    at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:245)
    at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:131)
    at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:109)
    at com.android.dx.command.dexer.Main.processOne(Main.java:418)
    at com.android.dx.command.dexer.Main.processAllFiles(Main.java:329)
    at com.android.dx.command.dexer.Main.run(Main.java:206)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at com.android.ide.eclipse.adt.internal.build.DexWrapper.run(DexWrapper.java:180)
    at com.android.ide.eclipse.adt.internal.build.BuildHelper.executeDx(BuildHelper.java:703)
    at com.android.ide.eclipse.adt.internal.build.builders.PostCompilerBuilder.build(PostCompilerBuilder.java:577)
    at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:728)
    at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
    at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:199)
    at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:321)
    at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:396)
    at org.eclipse.core.internal.resources.Project$1.run(Project.java:618)
    at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2344)
    at org.eclipse.core.internal.resources.Project.internalBuild(Project.java:597)
    at org.eclipse.core.internal.resources.Project.build(Project.java:124)
    at com.android.ide.eclipse.adt.internal.project.ProjectHelper.doFullIncrementalDebugBuild(ProjectHelper.java:1000)
    at com.android.ide.eclipse.adt.internal.launch.LaunchConfigDelegate.launch(LaunchConfigDelegate.java:147)
    at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:854)
    at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:703)
    at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:937)
    at org.eclipse.debug.internal.ui.DebugUIPlugin$8.run(DebugUIPlugin.java:1141)
    at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
[2012-07-27 22:59:10 - Yarxi] Dx 1 error; aborting
[2012-07-27 22:59:10 - Yarxi] Conversion to Dalvik format failed with error 1

And when I look at the JAR contents in the Package Explorer under Referenced Libraries, I see that every class under every package in the jmdns.jar is listed twice. Two copies of JmDNS.class, two copies of JmmDNS.class, and so forth.

Any ideas what’s wrong with the jar? I’m using other jars in the project, none of them act this way. Tried cleaning a few times, removed and re-added the JAR – same effect.

Might be worth noting that this is a library project, and the error pops up when I build the app that refers to the library.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T20:54:30+00:00Added an answer on June 8, 2026 at 8:54 pm

    You Probably used the .jar from SourceForge. That version has all .class files twice in the .jar and this leads to your error.

    Try using the .jar from Maven http://search.maven.org/#browse|1991004139, this should work, I used it earlier this month.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Preamble: Don't be scared off by the fact My Rails 3 app uses the
Preamble So, this question has already been answered, but as it was my first
PREAMBLE: this question is quite obsolete, it was written when the preferred Android dev
Preamble To build dynamic web-sites, we have to master at least four languages: HTML
Small preamble. I was good java developer on 1.4 jdk. After it I have
I've got Python code with a preamble containing the line: from numpy import array,arccosh,random_integers
In the spirit of the Perl Preamble where a script works properly whether executed
I've been using Eclipse since 2.x and IDEs in general for over 20 years
I am using ntheorem to typeset a set of conditions. In my preamble I
Preamble: I know, disabling warnings is not a good idea. Anyway, I have a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.