Which version of libdb-java should be used

Asked by David Coles

I've been trying to install the zeroc-ice33 package on my computer. Unfortunately I could not get this to succeed due to a conflict between the version of libdb-java on my machine. The package zeroc-ice33 depends on libzeroc-ice-java which depends on libdb4.6-java, while the package netbeans depends on liblucene2-java which depends on libdb4.5-java.

It appears that the 3 versions of libdb-java (4.5, 4.6 and 4.7) are all mutually exclusive and as such any two packages using different versions will cause a conflict. I notice that there is no reason I can't have multiple versions of the underlying libdb packages (libdb4.5, libdb4.6 and libdb4.7) but this doesn't seem to hold for the java bindings. Is there a good reason that these packages conflict or is this a potential bug?

Fortunately the jaunty package of liblucene2-java depends on the libdb4.6-java and by installing it I'm able to safely run both packages at the moment. Though it does seem like something that could easily be a more serious issue in the future.

I'm also surprised at the large number of dependencies liblucene2-java has. The Lucene website seems to indicate ( http://lucene.apache.org/java/docs/systemrequirements.html ) that Lucene should really only need a recent version of Java, ANT and possibly JUnit, though I assume that it could be the contrib modules that is causing the blowout of dependencies. Would these be better as recommends or possibly packaged into a completely separate package.

Thanks for your advice.

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Joker Wild (lajjr-deactivatedaccount) said :
#1

if say you install libdb4.6 it synaptic package manager it install libdb4.5 too check it..If you have netbeans on your system you will see...4.7 added features...etc.

libdb4.6-java will work

Revision history for this message
David Coles (dcoles) said :
#2

Yes, in general, a newer version of a library should be backwards compatible with older versions of the library and thus be able to be used as a drop in replacement. In that case, my problem is that the libdb4.6-java does have a 'Provides' dependency rule for libdb4.5-java and thus any packages that depends explicitly upon libdb4.5java will not be able to be installed.

If libdb4.6-java can't be used as a drop in dependency is there any reason why I can't have both libdb4.5-java and libdb4.6-java installed at the same time? If not, then really there should only be one version of libdb-java used in a release since it effectively partitions software you can install depending version of libdb-java you want to use.

It only appears to be the liblucene2-java package that depends on libdb2.5-java anyway. It might just have been I was very unlucky to choose two java applications that cause this conflict.

Revision history for this message
Joker Wild (lajjr-deactivatedaccount) said :
#3

David,

You can have both it should be no problem I have all three on mine, and I have to say that I haven't had one problem.

Revision history for this message
David Coles (dcoles) said :
#4

Sorry for the delay. I've just tried this on a brand new install of intrepid.

$ sudo apt-get install libdb4.5-java libdb4.6-java libdb4.7-java
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies.
  libdb4.5-java: Conflicts: libdb-java
  libdb4.6-java: Conflicts: libdb-java
  libdb4.7-java: Conflicts: libdb-java
E: Broken packages

Are you sure you're talking about libdb*-java and not just libdb*?

Revision history for this message
Joker Wild (lajjr-deactivatedaccount) said :
#5

I don't have libdb-java plain installed .

libdb4.2 install
libdb4.4 install
libdb4.5 install
libdb4.5-java install
libdb4.6 install
libdb4.6++ install
libdb4.6-dev install
libdb4.6-java install
libdb4.6-java-dev purge
libdb4.6-java-gcj purge
libdb4.6-ruby1.8 install
libdbd-ldap-perl install
libdbd-mysql-perl install
libdbd-pg-perl install
libdbd-sqlite3-perl install
libdbi-perl install
libdbm-ruby install
libdbm-ruby1.8 install
libdbus-1-3 install
libdbus-1-dev install
libdbus-glib-1-2 install

Can you help with this problem?

Provide an answer of your own, or ask David Coles for more information if necessary.

To post a message you must log in.