You are not logged in.

#1 2008-07-23 07:27:18

roadt
Member
Registered: 2007-10-18
Posts: 26

[makepkg] depends version check problems

hello everyone, 
i want to make a simple PKGBUILD of tijmp, it need the jdk6 as the dependence.

In my PKGBUILD, i wrote

depends=('jdk>=6')

but when makepkg -f , makepkg reports errors.

==> Making package: tijmp 0.7-1  (Wed Jul 23 15:26:11 CST 2008)
==> Checking Runtime Dependencies...
==> Missing Dependencies:
  -> jdk>=6
==> Checking Buildtime Dependencies...
==> ERROR: Could not resolve all dependencies

my jdk version is  6u7

$P -Qi jdk
Name           : jdk
Version        : 6u7-1
URL            : http://java.sun.com
....

but if i changed the PKGBUILD, like

depends=('jdk>=6u')

makepkg works well.

why?

Last edited by roadt (2008-07-23 07:28:04)

Offline

#2 2008-07-23 08:00:42

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,405
Website

Re: [makepkg] depends version check problems

This happens because according to the version comparison 6 > 6u7 but 6u < 6u7 - you can test this with the vercmp tool.  This is because any text after a number is assumed to mean something like alpha, beta, rc, etc.  It is difficult (read impossible) to come up with a version comparison function that works for every piece of software.

Online

#3 2008-07-23 08:56:39

roadt
Member
Registered: 2007-10-18
Posts: 26

Re: [makepkg] depends version check problems

Thanks Allan.

it's difficult to create a rule for apply for all people. agreed.

but if the vercmp works as this rule,  i suppose jdk 6u7 is wrongly named.
since u7 is neither alpha nor  beta. (though i still doesn't understand what u7 or u mean).
maybe 6.7 or something similar is better.  why using u7? that's strange for me..

Offline

#4 2008-07-23 09:04:55

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,405
Website

Re: [makepkg] depends version check problems

Jdk is named 6u7 because that is what upstream calls it so not much we can do about that.

Online

#5 2008-07-23 09:29:26

roadt
Member
Registered: 2007-10-18
Posts: 26

Re: [makepkg] depends version check problems

yes, google some, seems named as  6 Update 7 .

okay.   i'll keep the depends=('jdk>=6u') in PKGBUILD.
it's not too ugly to live with,  and seems i have no  choice. :-)

Thanks for your help.

Offline

Board footer

Powered by FluxBB