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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T12:34:37+00:00 2026-05-31T12:34:37+00:00

This must be quite a common problem. An application depends on Library A and

  • 0

This must be quite a common problem. An application depends on Library A and Library B. Library A depends on Library C-v1 (version 1 of Library C) and Library B depends on some newly introduced features in Library C-v2 (version 2 of Library C). And of course, there was some major refactoring in Library C-v2 which means it can’t be backwards compatible with Library C-v1. But Library C-v1 and Library C-v2 have the same package names and class names.

Now, it should be possible to effectively “re-namespace” Library C-v1. For example, a class called com.example.MyClass could be re-namespaced to old.com.example.MyClass. It should be completely possible to build an automated tool that takes a binary JAR and changes all the package names in this fashion.

It should also be possible to change the references in a dependent library. For example, any reference in Library A to Library C should be changed to point to the new package names.

Surely there must already be a tool available to do this?

(PS: I’m sure some clever person will mention OSGi, but I want to do this as a one-time activity).

  • 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-05-31T12:34:38+00:00Added an answer on May 31, 2026 at 12:34 pm

    jarjar does what you are asking:

    You can avoid problems where your library depends on a specific version of a library, which may conflict with the dependencies of another library.

    The libraries are repackaged into your jar and renamed in the process. It also includes an Ant-Task.

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

Sidebar

Related Questions

I guess my problem is quite common, so there must be an easy solution.
I am sure that this must be quite a common problem so I would
This must be a common problem because I see it in many published papers
Presumably it must be quite common to desire a screen in which there are
this must be such a simple problem but can someone tell me why this
This must be a FAQ, but I can’t find a duplicate question! There are
I'm sure this must be something simple, but I can't quite work out what's
I think this question is quite common. Recently I have got a requirement that
This must be quite basic, but I was wondering how to add an integer
This must be quite simple, but I just can't find a way. I have

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.