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 7825151
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T08:50:59+00:00 2026-06-02T08:50:59+00:00

I have been searching around for ages trying to find a solution to my

  • 0

I have been searching around for ages trying to find a solution to my problem, but all of the other posts I have come across either don’t work or don’t match my situation, so hopefully someone can give me some insight.

I have a library that I am build with ant, which outputs 2 jar files, one as normal containing the compiled version of the library, and another containing just the source files.

This library is uploaded to our Nexus repository with packaging set to jar. For the actual jar file I set extension to jar and leave classifier blank. For the source jar I set classifier to sources and extension to jar.

No matter what I do with my ivy.xml file I can’t get it to download the sources jar. Based on posts I have read elsewhere I tried adding:

conf="*->default,sources"

to my dependency, but then I get an error:

configuration not found in org#name;version: 'sources'

So this is basically expecting my library to define sources as a configuration somewhere? I thought it would just pick up the fact that there is another artefact with the classifier set to sources in the repository.

Can anyone give me other suggestions of what I might be doing wrong either with the way I have published my library to Nexus, or with how I have set up my dependency declaration in my Ivy file.

This is the basic Ivy.xml file where I am defining my dependency on the library that I have put in Nexus.

<ivy-module version="2.0">

    <info organisation="${ivy.organisation}" module="moduleName" />

    <configurations>
        <conf name="pda" description="moduleName for PDA"/>
        <conf name="server" description="moduleName for server"/>
    </configurations>

    <dependencies>
        <!-- Internal -->
        <dependency name="utility" org="${ivy.organisation}" rev="latest.integration" conf="${ivy.configuration}"/>
        <dependency name="myLib" org="my.org" rev="0.0.+"/>
    </dependencies>

</ivy-module>

In response to comments below, the ivy.configuration property is set to pda within my build.properties for Ant. For Eclipse I have created a properties file and also set ivy.configuration to pda (this properties file is then referenced in the Ivy settings within Eclipse).

The error message I get is:

Some projects fail to be resolved
    Impossible to resolve dependencies of ${ivy.organisation}#moduleName;working@host
        unresolved dependency: my.org#myLib;0.0.+: configuration not found in my.org#myLib;0.0.0: 'sources'. It was required from ${ivy.organisation}#moduleName;working@host pda

UPDATE
Here is the resolved ivy.xml file:

<?xml version="1.0" encoding="UTF-8"?>
<ivy-module version="2.0">
    <info organisation="my.org"
        module="myLib"
        revision="0.0.0"
        status="release"
        publication="20120419131909"
        default="true"
    />
    <configurations>
        <conf name="default" visibility="public"/>
    </configurations>
    <publications>
        <artifact name="myLib" type="jar" ext="jar" conf="default"/>
    </publications>
</ivy-module>

This obviously explains why it fails to find the ‘sources’ conf. But I was under the impression that the sources conf should be added automatically because I have added the sources to Nexus.

  • 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-02T08:51:01+00:00Added an answer on June 2, 2026 at 8:51 am

    So after a lot of playing around I seem to finally have a solution to this. If I declare my dependency in the following way:

    <dependency name="myLib" org="my.org" rev="0.0.+">
        <artifact type="jar"/>
        <artifact type="source" m:classifier="sources" conf="pdaDev->sources"/>
    </dependency>
    

    Then I can add a new config (e.g. pdaDev above) which links to the sources config of the dependency. When using Eclipse I can tell it to use the pdaDev config and it does pull in the source jar too (if it exists).

    It seems strange that Nexus doesn’t seem to include the sources config in the resolved Ivy file unless it is explicitly asked for like I have done above.

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

Sidebar

Related Questions

I've been searching around for the solution, and have come across the multipart and
I have been searching around using Google but I can't find an answer to
I've been searching around and trying all sorts of different approaches, but I can't
I have been searching around for a simple solution, but I have not found
I have been searching around but I cant seem to find any answers for
I have been searching around for answers, but I can't seem to find anything.
I have been searching around for this question but cant seem to find it.
I have been searching around for an answer to this but I can't seem
I have been searching around for a solution for quite some time, hoping someone
I have been searching all around about how to integrate driving directions into MKMapView

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.