Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 23 Aug 2023 00:57:51 +0800
From:      Po-Chuan Hsieh <sunpoet@freebsd.org>
To:        rodrigo@freebsd.org
Cc:        Joseph Mingrone <jrm@freebsd.org>, Renato Botelho <garga@freebsd.org>, ports-committers@freebsd.org,  dev-commits-ports-all@freebsd.org, dev-commits-ports-main@freebsd.org
Subject:   Re: git: 11e51925413b - main - devel/p5-DateTime-Format-MySQL: Update to 0.08
Message-ID:  <CAMHz58RdUg-FBhFgB%2BaSu2=MG=9fA7A6zoCgB%2B4qpAs12oFdFw@mail.gmail.com>
In-Reply-To: <226220f0-119d-79d1-c597-064990d6cb6f@FreeBSD.org>
References:  <202308161836.37GIaHp6043137@gitrepo.freebsd.org> <ec2e809f-9b65-46cb-b4fc-cacd287c5a83@FreeBSD.org> <86jzttx00m.fsf@phe.ftfl.ca> <a1c25f10-8198-4c67-891d-aa6a9ce5ae02@FreeBSD.org> <867cpsp4hi.fsf@phe.ftfl.ca> <6cb25b46-33e1-4ab6-8207-c3087c08a7a5@FreeBSD.org> <867cpsnmuh.fsf@phe.ftfl.ca> <CAMHz58TqGh9pO3gFsAmqth7tP4NSBsxZ7iJQk2ynCuJq-j-e7w@mail.gmail.com> <226220f0-119d-79d1-c597-064990d6cb6f@FreeBSD.org>

index | next in thread | previous in thread | raw e-mail

[-- Attachment #1 --]
On Wed, Aug 23, 2023 at 12:19 AM Rodrigo Osorio <rodrigo@freebsd.org> wrote:

> On 21/08/23 20:11, Po-Chuan Hsieh wrote:
>
> On Sat, Aug 19, 2023 at 3:59 AM Joseph Mingrone <jrm@freebsd.org> wrote:
>
>> On Fri, 2023-08-18 at 16:08, Renato Botelho <garga@FreeBSD.org>
>> <garga@FreeBSD.org> wrote:
>>
>> > On 18/08/23 15:52, Joseph Mingrone wrote:
>> >> On Fri, 2023-08-18 at 14:32, Renato Botelho <garga@FreeBSD.org>
>> <garga@FreeBSD.org> wrote:
>>
>> >>> On 17/08/23 10:37, Joseph Mingrone wrote:
>> >>>> On Thu, 2023-08-17 at 10:15, Renato Botelho <garga@FreeBSD.org>
>> <garga@FreeBSD.org> wrote:
>>
>> >>>>> On 16/08/23 15:36, Po-Chuan Hsieh wrote:
>> >>>>>> The branch main has been updated by sunpoet:
>> >>>>>> URL:
>> https://cgit.FreeBSD.org/ports/commit/?id=11e51925413b7090544d4a4ac449c364717f7e50
>> >>>>>> commit 11e51925413b7090544d4a4ac449c364717f7e50
>> >>>>>> Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
>> <sunpoet@FreeBSD.org>
>> >>>>>> AuthorDate: 2023-08-16 18:16:29 +0000
>> >>>>>> Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
>> <sunpoet@FreeBSD.org>
>> >>>>>> CommitDate: 2023-08-16 18:26:21 +0000
>> >>>>>>        devel/p5-DateTime-Format-MySQL: Update to 0.08
>> >>>>>>             Changes:
>> https://metacpan.org/dist/DateTime-Format-MySQL/changes
>> >>>>>> ---
>> >>>>>>     devel/p5-DateTime-Format-MySQL/Makefile | 2 +-
>> >>>>>>     devel/p5-DateTime-Format-MySQL/distinfo | 6 +++---
>> >>>>>>     2 files changed, 4 insertions(+), 4 deletions(-)
>> >>>>>> diff --git a/devel/p5-DateTime-Format-MySQL/Makefile
>> b/devel/p5-DateTime-Format-MySQL/Makefile
>> >>>>>> index 989d481a74d2..f9b0e03be278 100644
>> >>>>>> --- a/devel/p5-DateTime-Format-MySQL/Makefile
>> >>>>>> +++ b/devel/p5-DateTime-Format-MySQL/Makefile
>> >>>>>> @@ -1,5 +1,5 @@
>> >>>>>>     PORTNAME=    DateTime-Format-MySQL
>> >>>>>> -PORTVERSION=    0.0701
>> >>>>>> +PORTVERSION=    0.08
>>
>> >>>>> Hello Po-Chuan!
>>
>> >>>>> 0.08 is smaller than 0.0701 so port version went backwards after
>> this change.
>> >>>> 0.08 is greater than 0.0701, but not according to pkg version.
>> >>>>    % pkg version -t 0.08 0.0701
>> >>>>           <
>>
>> >>> Actually pkg is correct in this case.  Numerically 8 is smaller than
>> 701.  I tested it on Ubuntu and dpkg --compare-versions has the same
>> result, and I believe any other package management tool will do.
>>
>> >>> What seems to be wrong is the version schema used by this project.
>> It should be 0.0800 instead of 0.08.
>> >> I didn't mean to suggest that pkg is wrong, but just pointing out that
>> numerically, 0.08, which is equal to 0.0800, is greater than 0.0701.  This
>> could be a source of confusion for anyone who assumes that the comparison
>> of version numbers works the same as comparisons of
>> >> real numbers.
>>
>> > Anyway, can you please fix the port by adding PORTEPOCH?
>>
>> Fixed in 49eb4309189da197f55dee54f8efb5e875f2daaa.  Thanks for reporting.
>>
>> Joe
>>
>
> No doubt 0.08 is less than 0.0701 in the pkg world.
> Thank you all for fixing it.
>
> We don't know if the versioning change is temporary or not. Instead of
> adding PORTEPOCH, please consider the following fix/hack next time.
> Thanks again.
>
> --- a/devel/p5-DateTime-Format-MySQL/Makefile
> +++ b/devel/p5-DateTime-Format-MySQL/Makefile
> @@ -1,8 +1,9 @@
>  PORTNAME=      DateTime-Format-MySQL
> -PORTVERSION=   0.08
> +PORTVERSION=   0.0800
>  CATEGORIES=    devel perl5
>  MASTER_SITES=  CPAN
>  PKGNAMEPREFIX= p5-
> +DISTNAME=      DateTime-Format-MySQL-${PORTVERSION:C|00$||}
>
>  MAINTAINER=    perl@FreeBSD.org
>  COMMENT=       Parse and format MySQL dates and times
>
>
> Hi,
>
> I don't know if such a simple fix can solve the issue we have with Perl
> versioning sheme
> and the semantic versioning scheme we use in ports.
> This article is very instructive about how awful it is
> https://perlhacks.com/2016/12/version-numbers/.
>

Yes, Perl has a different versioning scheme.
That's why I would hack PORTVERSION sometimes.
Take textproc/p5-Text-ANSI-Util for example, I removed the hack after years
since the version scheme seems to be consolidated.
c975054b7866b05594a1b6be9cea3c33870d8567
11cb372ff4cae86977fe2f873b630825b8cd43a0

Just a few examples running this command to evaluate the version number:
>     perl -Mversion -E"say version->parse('$VERSION')->normal"
>
> VERSION    | Output
> -----------|-------
> "8"        | v8.0.0
> "00008"    | v8.0.0
> "000080"   | v80.0.0
> "0.8"      | v0.800.0
> "0.81"     | v0.810.0
> "0.801"    | v0.801.0
> "0.8001"   | v0.800.100
> "0.008001" | v0.8.1
>
> By the way, I did a quick try in with your fix, and the substitution with
> an '$'
> doesn't seem to work in BSD makefiles.
>
> %cat Makefile
> V="0.0800"
>
You have to remove the double quote.

> all:
>     @echo ${V}
>     @echo ${V:C|00$||}
>
> %make
> 0.0800
> 0.0800
>
> Regards
> -- rodrigo
>

[-- Attachment #2 --]
<div dir="ltr"><div dir="ltr">On Wed, Aug 23, 2023 at 12:19 AM Rodrigo Osorio &lt;<a href="mailto:rodrigo@freebsd.org">rodrigo@freebsd.org</a>&gt; wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
  
    
  
  <div>
    <div>On 21/08/23 20:11, Po-Chuan Hsieh
      wrote:<br>
    </div>
    <blockquote type="cite">
      
      <div dir="ltr">
        <div dir="ltr">On Sat, Aug 19, 2023 at 3:59 AM Joseph Mingrone
          &lt;<a href="mailto:jrm@freebsd.org" target="_blank">jrm@freebsd.org</a>&gt; wrote:<br>
        </div>
        <div class="gmail_quote">
          <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Fri, 2023-08-18 at
            16:08, Renato Botelho <a href="mailto:garga@FreeBSD.org" target="_blank">&lt;garga@FreeBSD.org&gt;</a> wrote:<br>
            <br>
            &gt; On 18/08/23 15:52, Joseph Mingrone wrote:<br>
            &gt;&gt; On Fri, 2023-08-18 at 14:32, Renato Botelho
            <a href="mailto:garga@FreeBSD.org" target="_blank">&lt;garga@FreeBSD.org&gt;</a> wrote:<br>
            <br>
            &gt;&gt;&gt; On 17/08/23 10:37, Joseph Mingrone wrote:<br>
            &gt;&gt;&gt;&gt; On Thu, 2023-08-17 at 10:15, Renato Botelho
            <a href="mailto:garga@FreeBSD.org" target="_blank">&lt;garga@FreeBSD.org&gt;</a> wrote:<br>
            <br>
            &gt;&gt;&gt;&gt;&gt; On 16/08/23 15:36, Po-Chuan Hsieh
            wrote:<br>
            &gt;&gt;&gt;&gt;&gt;&gt; The branch main has been updated by
            sunpoet:<br>
            &gt;&gt;&gt;&gt;&gt;&gt; URL: <a href="https://cgit.FreeBSD.org/ports/commit/?id=11e51925413b7090544d4a4ac449c364717f7e50" rel="noreferrer" target="_blank">https://cgit.FreeBSD.org/ports/commit/?id=11e51925413b7090544d4a4ac449c364717f7e50</a><br>;
            &gt;&gt;&gt;&gt;&gt;&gt; commit
            11e51925413b7090544d4a4ac449c364717f7e50<br>
            &gt;&gt;&gt;&gt;&gt;&gt; Author:     Po-Chuan Hsieh
            <a href="mailto:sunpoet@FreeBSD.org" target="_blank">&lt;sunpoet@FreeBSD.org&gt;</a><br>
            &gt;&gt;&gt;&gt;&gt;&gt; AuthorDate: 2023-08-16 18:16:29
            +0000<br>
            &gt;&gt;&gt;&gt;&gt;&gt; Commit:     Po-Chuan Hsieh
            <a href="mailto:sunpoet@FreeBSD.org" target="_blank">&lt;sunpoet@FreeBSD.org&gt;</a><br>
            &gt;&gt;&gt;&gt;&gt;&gt; CommitDate: 2023-08-16 18:26:21
            +0000<br>
            &gt;&gt;&gt;&gt;&gt;&gt;       
            devel/p5-DateTime-Format-MySQL: Update to 0.08<br>
            &gt;&gt;&gt;&gt;&gt;&gt;             Changes:        <a href="https://metacpan.org/dist/DateTime-Format-MySQL/changes" rel="noreferrer" target="_blank">https://metacpan.org/dist/DateTime-Format-MySQL/changes</a><br>;
            &gt;&gt;&gt;&gt;&gt;&gt; ---<br>
            &gt;&gt;&gt;&gt;&gt;&gt;   
             devel/p5-DateTime-Format-MySQL/Makefile | 2 +-<br>
            &gt;&gt;&gt;&gt;&gt;&gt;   
             devel/p5-DateTime-Format-MySQL/distinfo | 6 +++---<br>
            &gt;&gt;&gt;&gt;&gt;&gt;     2 files changed, 4
            insertions(+), 4 deletions(-)<br>
            &gt;&gt;&gt;&gt;&gt;&gt; diff --git
            a/devel/p5-DateTime-Format-MySQL/Makefile
            b/devel/p5-DateTime-Format-MySQL/Makefile<br>
            &gt;&gt;&gt;&gt;&gt;&gt; index 989d481a74d2..f9b0e03be278
            100644<br>
            &gt;&gt;&gt;&gt;&gt;&gt; ---
            a/devel/p5-DateTime-Format-MySQL/Makefile<br>
            &gt;&gt;&gt;&gt;&gt;&gt; +++
            b/devel/p5-DateTime-Format-MySQL/Makefile<br>
            &gt;&gt;&gt;&gt;&gt;&gt; @@ -1,5 +1,5 @@<br>
            &gt;&gt;&gt;&gt;&gt;&gt;     PORTNAME=   
            DateTime-Format-MySQL<br>
            &gt;&gt;&gt;&gt;&gt;&gt; -PORTVERSION=    0.0701<br>
            &gt;&gt;&gt;&gt;&gt;&gt; +PORTVERSION=    0.08<br>
            <br>
            &gt;&gt;&gt;&gt;&gt; Hello Po-Chuan!<br>
            <br>
            &gt;&gt;&gt;&gt;&gt; 0.08 is smaller than 0.0701 so port
            version went backwards after this change.<br>
            &gt;&gt;&gt;&gt; 0.08 is greater than 0.0701, but not
            according to pkg version.<br>
            &gt;&gt;&gt;&gt;    % pkg version -t 0.08 0.0701<br>
            &gt;&gt;&gt;&gt;           &lt;<br>
            <br>
            &gt;&gt;&gt; Actually pkg is correct in this case. 
            Numerically 8 is smaller than 701.  I tested it on Ubuntu
            and dpkg --compare-versions has the same result, and I
            believe any other package management tool will do.<br>
            <br>
            &gt;&gt;&gt; What seems to be wrong is the version schema
            used by this project.  It should be 0.0800 instead of 0.08.<br>
            &gt;&gt; I didn&#39;t mean to suggest that pkg is wrong, but
            just pointing out that numerically, 0.08, which is equal to
            0.0800, is greater than 0.0701.  This could be a source of
            confusion for anyone who assumes that the comparison of
            version numbers works the same as comparisons of<br>
            &gt;&gt; real numbers.<br>
            <br>
            &gt; Anyway, can you please fix the port by adding
            PORTEPOCH?<br>
            <br>
            Fixed in 49eb4309189da197f55dee54f8efb5e875f2daaa.  Thanks
            for reporting.<br>
            <br>
            Joe<br>
          </blockquote>
          <div><br>
          </div>
          <div>No doubt 0.08 is less than 0.0701 in the pkg world.</div>
          <div>Thank you all for fixing it.<br>
          </div>
          <div><br>
          </div>
          <div>We don&#39;t know if the versioning change is temporary or
            not. Instead of adding PORTEPOCH, please consider the
            following fix/hack next time.<br>
          </div>
          <div>Thanks again.</div>
          <div><br>
          </div>
          --- a/devel/p5-DateTime-Format-MySQL/Makefile<br>
          +++ b/devel/p5-DateTime-Format-MySQL/Makefile<br>
          @@ -1,8 +1,9 @@<br>
           PORTNAME=      DateTime-Format-MySQL<br>
          -PORTVERSION=   0.08<br>
          +PORTVERSION=   0.0800<br>
           CATEGORIES=    devel perl5<br>
           MASTER_SITES=  CPAN<br>
           PKGNAMEPREFIX= p5-<br>
          +DISTNAME=      DateTime-Format-MySQL-${PORTVERSION:C|00$||}<br>
          <br>
           MAINTAINER=    <a href="mailto:perl@FreeBSD.org" target="_blank">perl@FreeBSD.org</a><br>
          <div> COMMENT=       Parse and format MySQL dates and times</div>
          <div> </div>
        </div>
      </div>
    </blockquote>
    <p>Hi,</p>
    <p>I don&#39;t know if such a simple fix can solve the issue we have
      with Perl versioning sheme<br>
      and the semantic versioning scheme we use in ports.<br>
      This article is very instructive about how awful it is
      <a href="https://perlhacks.com/2016/12/version-numbers/" target="_blank">https://perlhacks.com/2016/12/version-numbers/</a>.</p></div></blockquote><div><br></div><div>Yes, Perl has a different versioning scheme.</div><div>That&#39;s why I would hack PORTVERSION sometimes.</div><div>Take textproc/p5-Text-ANSI-Util for example, I removed the hack after years since the version scheme seems to be consolidated.<br></div><div>c975054b7866b05594a1b6be9cea3c33870d8567</div><div>11cb372ff4cae86977fe2f873b630825b8cd43a0</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>
    <p>Just a few examples running this command to evaluate the version
      number:<br>
          perl -Mversion -E&quot;say
      version-&gt;parse(&#39;$VERSION&#39;)-&gt;normal&quot;<br>
      <br>
      VERSION    | Output<br>
      -----------|-------<br>
      &quot;8&quot;        | v8.0.0<br>
      &quot;00008&quot;    | v8.0.0<br>
      &quot;000080&quot;   | v80.0.0<br>
      &quot;0.8&quot;      | v0.800.0<br>
      &quot;0.81&quot;     | v0.810.0<br>
      &quot;0.801&quot;    | v0.801.0 <br>
      &quot;0.8001&quot;   | v0.800.100<br>
      &quot;0.008001&quot; | v0.8.1</p>
    <p>By the way, I did a quick try in with your fix, and the
      substitution with an &#39;$&#39;<br>
      doesn&#39;t seem to work in BSD makefiles.</p>
    <p>%cat Makefile<br>
      V=&quot;0.0800&quot;</p></div></blockquote><div>You have to remove the double quote.</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><p>
      all:<br>
          @echo ${V}<br>
          @echo ${V:C|00$||}</p>
    <p>%make<br>
      0.0800<br>
      0.0800</p>
    <p>Regards<br>
      -- rodrigo<br>
    </p>
  </div>

</blockquote></div></div>
home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAMHz58RdUg-FBhFgB%2BaSu2=MG=9fA7A6zoCgB%2B4qpAs12oFdFw>