• version question for an nginx module

    From Ronald Klop@ronald-lists@klop.ws to muc.lists.freebsd.ports on Thu Jul 16 21:16:58 2026
    From Newsgroup: muc.lists.freebsd.ports

    ------=_Part_1615_1526711420.1784229418409
    Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit

    Hi,

    I'm creating a port for an nginx module. The module has a version. But I also want it to create a new pkg when nginx changes as it uses the source of nginx also.
    So I had this in mind.

    PORTNAME= nginx-module-foo
    DISTVERSION= 1.0.0
    .include "../nginx/version.mk"
    PORTVERSION= ${DISTVERSION}~${NGINX_VERSION}
    CATEGORIES= www
    MASTER_SITES= https://nginx.org/download/:nginx
    DISTFILES= nginx-${NGINX_VERSION}.tar.gz:nginx

    With this the port will automatically get a new pkg version when DISTVERSION changes, and also when NGINX_VERSION changes.

    Is this a reasonable way to do this? Do we have similar constructions in the ports tree?

    Regards,
    Ronald.

    ------=_Part_1615_1526711420.1784229418409
    Content-Type: text/html; charset=us-ascii
    Content-Transfer-Encoding: 7bit

    <html><head></head><body>Hi,<br>

    I'm creating a port for an nginx module. The module has a version. But I also want it to create a new pkg when nginx changes as it uses the source of nginx also.<br>
    So I had this in mind.<br>

    PORTNAME=&nbsp; &nbsp; &nbsp; &nbsp;nginx-module-foo<br>
    DISTVERSION=&nbsp; &nbsp; 1.0.0<br>
    .include "../nginx/version.mk"<br>
    PORTVERSION=&nbsp; &nbsp; ${DISTVERSION}~${NGINX_VERSION}<br>
    CATEGORIES=&nbsp; &nbsp; &nbsp;www<br>
    MASTER_SITES=&nbsp; &nbsp;https://nginx.org/download/:nginx<br> DISTFILES=&nbsp; &nbsp; &nbsp; nginx-${NGINX_VERSION}.tar.gz:nginx<br>

    With this the port will automatically get a new pkg version when DISTVERSION changes, and also when NGINX_VERSION changes.<br>

    Is this a reasonable way to do this? Do we have similar constructions in the ports tree?<br>

    Regards,<br>
    Ronald.<br>
    &nbsp;</body></html>
    ------=_Part_1615_1526711420.1784229418409--


    --
    Posted automagically by a mail2news gateway at muc.de e.V.
    Please direct questions, flames, donations, etc. to news-admin@muc.de
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From Gleb Popov@arrowd@freebsd.org to muc.lists.freebsd.ports on Thu Jul 16 23:29:37 2026
    From Newsgroup: muc.lists.freebsd.ports

    On Thu, Jul 16, 2026 at 10:17rC>PM Ronald Klop <ronald-lists@klop.ws> wrote:

    Hi,

    I'm creating a port for an nginx module. The module has a version. But I also want it to create a new pkg when nginx changes as it uses the source of nginx also.
    So I had this in mind.

    PORTNAME= nginx-module-foo
    DISTVERSION= 1.0.0
    .include "../nginx/version.mk"
    PORTVERSION= ${DISTVERSION}~${NGINX_VERSION}
    CATEGORIES= www
    MASTER_SITES= https://nginx.org/download/:nginx
    DISTFILES= nginx-${NGINX_VERSION}.tar.gz:nginx

    With this the port will automatically get a new pkg version when DISTVERSION changes, and also when NGINX_VERSION changes.
    Usually this doesn't work because a change in DISTVERSION results in
    distinfo becoming out-of-date.
    --
    Posted automagically by a mail2news gateway at muc.de e.V.
    Please direct questions, flames, donations, etc. to news-admin@muc.de
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From Ronald Klop@ronald-lists@klop.ws to muc.lists.freebsd.ports on Fri Jul 17 10:07:06 2026
    From Newsgroup: muc.lists.freebsd.ports

    ------=_Part_547_1584134777.1784275626121
    Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit


    Van: Gleb Popov <arrowd@freebsd.org>
    Datum: donderdag, 16 juli 2026 22:29
    Aan: Ronald Klop <ronald-lists@klop.ws>
    CC: ports@freebsd.org
    Onderwerp: Re: version question for an nginx module

    On Thu, Jul 16, 2026 at 10:17PM Ronald Klop <ronald-lists@klop.ws> wrote:

    Hi,

    I'm creating a port for an nginx module. The module has a version. But I also want it to create a new pkg when nginx changes as it uses the source of nginx also.
    So I had this in mind.

    PORTNAME= nginx-module-foo
    DISTVERSION= 1.0.0
    .include "../nginx/version.mk"
    PORTVERSION= ${DISTVERSION}~${NGINX_VERSION}
    CATEGORIES= www
    MASTER_SITES= https://nginx.org/download/:nginx
    DISTFILES= nginx-${NGINX_VERSION}.tar.gz:nginx

    With this the port will automatically get a new pkg version when DISTVERSION changes, and also when NGINX_VERSION changes.

    Usually this doesn't work because a change in DISTVERSION results in
    distinfo becoming out-of-date.



    Sharp observation. I didn't think about that yet.

    Could I use a MASTERDIR construction to share the distinfo with the master port?

    Regards,
    Ronald.

    ------=_Part_547_1584134777.1784275626121
    Content-Type: text/html; charset=us-ascii
    Content-Transfer-Encoding: 7bit

    <html><head></head><body>&nbsp;
    <p><strong>Van:</strong> Gleb Popov &lt;arrowd@freebsd.org&gt;<br> <strong>Datum:</strong> donderdag, 16 juli 2026 22:29<br>
    <strong>Aan:</strong> Ronald Klop &lt;ronald-lists@klop.ws&gt;<br> <strong>CC:</strong> ports@freebsd.org<br>
    <strong>Onderwerp:</strong> Re: version question for an nginx module</p>

    <blockquote style="padding-right: 0px; padding-left: 5px; margin-left: 5px; border-left: #000000 2px solid; margin-right: 0px">
    <div class="MessageRFC822Viewer" id="P">
    <div class="TextPlainViewer" id="P.P">On Thu, Jul 16, 2026 at 10:17PM Ronald Klop &lt;ronald-lists@klop.ws&gt; wrote:<br>
    &gt;<br>
    &gt; Hi,<br>
    &gt;<br>
    &gt; I'm creating a port for an nginx module. The module has a version. But I also want it to create a new pkg when nginx changes as it uses the source of nginx also.<br>
    &gt; So I had this in mind.<br>
    &gt;<br>
    &gt; PORTNAME= &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;nginx-module-foo<br>
    &gt; DISTVERSION= &nbsp;&nbsp;&nbsp;1.0.0<br>
    &gt; .include "../nginx/version.mk"<br>
    &gt; PORTVERSION= &nbsp;&nbsp;&nbsp;${DISTVERSION}~${NGINX_VERSION}<br>
    &gt; CATEGORIES= &nbsp;&nbsp;&nbsp;&nbsp;www<br>
    &gt; MASTER_SITES= &nbsp;&nbsp;<a href="https://nginx.org/download/:nginx">https://nginx.org/download/:nginx</a><br>
    &gt; DISTFILES= &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;nginx-${NGINX_VERSION}.tar.gz:nginx<br>
    &gt;<br>
    &gt; With this the port will automatically get a new pkg version when DISTVERSION changes, and also when NGINX_VERSION changes.<br>

    Usually this doesn't work because a change in DISTVERSION results in<br> distinfo becoming out-of-date.</div>
    </div>
    </blockquote>



    Sharp observation. I didn't think about that yet.<br>

    Could I use a MASTERDIR construction to share the distinfo with the master port?<br>

    Regards,<br>
    Ronald.<br>
    &nbsp;</body></html>
    ------=_Part_547_1584134777.1784275626121--


    --
    Posted automagically by a mail2news gateway at muc.de e.V.
    Please direct questions, flames, donations, etc. to news-admin@muc.de
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From Gleb Popov@arrowd@freebsd.org to muc.lists.freebsd.ports on Fri Jul 17 11:38:21 2026
    From Newsgroup: muc.lists.freebsd.ports

    On Fri, Jul 17, 2026 at 11:07rC>AM Ronald Klop <ronald-lists@klop.ws> wrote:


    Sharp observation. I didn't think about that yet.

    Could I use a MASTERDIR construction to share the distinfo with the master port?
    Having a single distinfo for both ports will result in downloading
    distfiles for both ports even if the user builds one of them.
    Instead, try creating a smart makesum override that'd update distinfos
    of both ports.
    This is what I proposed for nvidia/drm-kmod ports here: https://reviews.freebsd.org/D50282#1148183
    A similar trick that I used for FLAVORized port: https://github.com/freebsd/freebsd-ports/blob/5f2391932a16ac1f198f0f4fad3d9d285fa7d52e/devel/hs-haskell-language-server/Makefile#L49-L54
    --
    Posted automagically by a mail2news gateway at muc.de e.V.
    Please direct questions, flames, donations, etc. to news-admin@muc.de
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From Gleb Popov@arrowd@freebsd.org to muc.lists.freebsd.ports on Fri Jul 17 15:59:01 2026
    From Newsgroup: muc.lists.freebsd.ports

    On Fri, Jul 17, 2026 at 3:52rC>PM Tomoaki AOKI <junchoon@dec.sakura.ne.jp> wrote:

    merging distinfo on-the-fly is abandoned, because I couldn't
    find the sane and surely-to-work way to automatically bump
    PORTREVISION.
    drm-kmod's version should be a part of the nvidia-drm version, that's
    all. No need for auto-bump magic.
    --
    Posted automagically by a mail2news gateway at muc.de e.V.
    Please direct questions, flames, donations, etc. to news-admin@muc.de
    --- Synchronet 3.22a-Linux NewsLink 1.2