> -----Original Message-----
> From: [email protected] [mailto:ptxdist-
> [email protected]] On Behalf Of Michael Olbrich
> Sent: Thursday, December 08, 2011 4:56 PM
> To: [email protected]
> Subject: Re: [ptxdist] [PATCH] ptxdist-2011.01.0 bug in make ipkg-push
>
> On Thu, Dec 08, 2011 at 10:45:00AM -0500, Jon Ringle wrote:
> > On Thu, Dec 8, 2011 at 10:37 AM, Michael Olbrich
> > <[email protected]>wrote:
> >
> > > Hi,
> > >
> > > so I accidentally pushed it before I could really review it...
> > > I had some time today and I think it's at least better than before.
> > >
> > > On Tue, Nov 29, 2011 at 03:59:41PM +0000, Benoît BURNICHON wrote:
> > > > Now, ptxd_ipkg_rev_smaller does not enforce a revision to be
> > > > 1.2.3-4 but allows everything debian like.
> > >
> > > Well, not everything debian like, '~' is not handled correctly, right?

The possibly prepended ':' also is not taken into account.

> > > Maybe something like this:
> > > ------------------------------------------------------------------------
> > > --- libptxdist.sh       2011-12-08 16:11:21.143970557 +0100
> > > +++ libptxdist.sh       2011-12-08 16:15:00.300421956 +0100
> > > @@ -741,13 +741,14 @@
> > >  #
> > >  ptxd_ipkg_rev_decimal_convert() {
> > >        local ver=$*
> > > -       while echo $ver | grep -q '[^0-9.]'
> > > +       while echo $ver | grep -q '[^0-9.~]'
> > >        do
> > > -               local char=`echo -n $ver | sed 's/.*\([^0-9.]\).*/\1/'`
> > > +               local char=`echo -n $ver | sed
> > > + 's/.*\([^0-9.~]\).*/\1/'`
> > >                 local char_dec=`echo -n $char | od -b | head -n 1 |
> > > awk '{print $2}'`
> > >                 ver=`echo $ver | sed "s/$char/.$char_dec/g"`
> > >         done
> > >
> > > +       ver=`echo $ver | sed -r "s/\.?~/.-1/g"`
> > >         ver=`echo $ver | sed 's/\.\./.0/g'`
> > >
> > >         echo "$ver"
> > > --------------------------------------------------------------------
> > > ----
> > >
> > > So I've been thinking about this whole version issue. The next step
> > > would be all versions with '-'. Maybe we should always add '-1' as
> > > packages revision. That would solve the problem for most of the
> > > packages is the list, you posted some time ago.
>
> Or we could add '-1' if the version contains a '-'.

Couldn't we just replace '-' by '+' in versions? There is not much difference 
in ASCII between the 2, only the ',' comes in between the 2.

>
> > > What remains are 'broken' versions. For those few we could do, e.g.:
> > >
> > > MYSQL_VERSION           := 5.1.14-beta
> > > MYSQL_XPKG_VERSION      := 5.1.14~beta
> > >
> > > Sounds like a good idea.
> > Seems like the pkg_XPKG_VERSION could be autogenerated based on the
> > pkg_VERSION so you wouldn't have to update all the package files. If
> > there is no '-' character in the version then pkg_XPKG_VERSION would
> > be equal to pkg_VERSION
>
> Yes, for most packages I want to reuse <PKG>_VERSION.
> <PKG>_XPKG_VERSION should just be a way to overwrite the default if
> necessary.
>
So replacements would be as follows:

CANFESTIVAL_VERSION := 3-20081204-1
MYSQL_VERSION := 5.1.14-beta
SPEEX_VERSION  := 1.2rc1

Detection of pre-versions: s/-?\(alpha|beta|gamma|rc\)/~\1/g
tr/-/+/

CANFESTIVAL_XPKG_VERSION := 3+20081204+1
MYSQL_XPKG_VERSION := 5.1.14~beta
SPEEX_XPKG_VERSION  := 1.2~rc1


________________________________

Ce courriel et toutes les pièces jointes sont confidentiels et peuvent être 
couverts par un privilège ou une protection légale. Il est établi à l’attention 
exclusive de ses destinataires. Toute utilisation de ce courriel non conforme à 
sa destination, toute diffusion ou toute publication, totale ou partielle, est 
interdite, sauf autorisation expresse préalable.
This email and any attachment are confidential and may be legally privileged or 
otherwise protected from disclosure. It is intended only for the stated 
addressee(s) and access to it by any other person(s) is unauthorized. Any use, 
dissemination or disclosure not in accordance with its purpose, either in whole 
or in part, is prohibited without our prior formal approval.
-- 
ptxdist mailing list
[email protected]

Reply via email to