Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 31 Mar 2023 11:14:31 -0400
From:      Adam Weinberger <adamw@adamw.org>
To:        Guido Falsi <madpilot@freebsd.org>
Cc:        gmarco@giovannelli.it, ports-committers@freebsd.org,  dev-commits-ports-all@freebsd.org, dev-commits-ports-main@freebsd.org
Subject:   Re: git: de841b40d24d - main - sysutils/xxd: New port
Message-ID:  <CAP7rwcgts1Obgu5x8YpnoGGYQ2_9ENW-eFU_FzDwLAETYHfeog@mail.gmail.com>
In-Reply-To: <e79df536-9cf8-dd5a-5d36-aa90735417ad@FreeBSD.org>
References:  <03eb85e1-14fa-24f4-dcb3-84caeef82a24@FreeBSD.org> <440103A8-A773-4B4E-BEB1-28C49D1B9CB5@adamw.org> <55712a33-dd09-719f-c294-417facb103a0@FreeBSD.org> <e79df536-9cf8-dd5a-5d36-aa90735417ad@FreeBSD.org>

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

[-- Attachment #1 --]
On Fri, Mar 31, 2023 at 11:07 AM Guido Falsi <madpilot@freebsd.org> wrote:

> On 31/03/23 16:32, Guido Falsi wrote:
> > On 31/03/23 16:30, Adam Weinberger wrote:
> >>
> >>
> >>> On Mar 31, 2023, at 10:28, Guido Falsi <madpilot@freebsd.org> wrote:
> >>>
> >>> On 31/03/23 15:49, Adam Weinberger wrote:
> >>>> On Thu, Mar 30, 2023 at 4:45 PM Guido Falsi <madpilot@freebsd.org
> >>>> <mailto:madpilot@freebsd.org>> wrote:
> >>>>     The branch main has been updated by madpilot:
> >>>>     URL:
> >>>>
> >>>>
> https://cgit.FreeBSD.org/ports/commit/?id=de841b40d24d22ab51ad05ed632e025903fbb41f
> <
> https://cgit.FreeBSD.org/ports/commit/?id=de841b40d24d22ab51ad05ed632e025903fbb41f
> >
> >>>>     commit de841b40d24d22ab51ad05ed632e025903fbb41f
> >>>>     Author:     Guido Falsi <madpilot@FreeBSD.org>
> >>>>     AuthorDate: 2023-03-30 20:42:54 +0000
> >>>>     Commit:     Guido Falsi <madpilot@FreeBSD.org>
> >>>>     CommitDate: 2023-03-30 20:42:54 +0000
> >>>>          sysutils/xxd: New port
> >>>>          This is the standalone version of the xxd tool provided by
> >>>> vim.
> >>>>          Submitted by:   Gianmarco Giovannelli <gmarco@giovannelli.it
> >>>>     <mailto:gmarco@giovannelli.it>>
> >>>>     diff --git a/sysutils/xxd/Makefile b/sysutils/xxd/Makefile
> >>>>     new file mode 100644
> >>>>     index 000000000000..378f364cf4bf
> >>>>     --- /dev/null
> >>>>     +++ b/sysutils/xxd/Makefile
> >>>>     @@ -0,0 +1,26 @@
> >>>>     +PORTNAME=      xxd
> >>>>     +DISTVERSIONPREFIX=     v
> >>>>     +DISTVERSION=   9.0.1366
> >>>>     +CATEGORIES=    sysutils
> >>>>     +
> >>>>     +MAINTAINER= gmarco@giovannelli.it <mailto:gmarco@giovannelli.it>
> >>>>     +COMMENT=       Hexdump and reverse hexdump utility
> >>>>     +WWW= https://github.com/mew-cx/xxd <
> https://github.com/mew-cx/xxd>;
> >>>>     +
> >>>>     +CONFLICTS_INSTALL=     vim-[0-9]* vim-gtk2 vim-gtk3 vim-motif
> >>>> vim-x11
> >>>>     +
> >>>>     +ALL_TARGET=    ${PORTNAME}
> >>>>     +PORTSCOUT=     ignore:1
> >>>>     +EXTRACT_AFTER_ARGS=    --include='*/src/xxd*'
> >>>>     +WRKSRC_SUBDIR= src/xxd
> >>>>     +
> >>>>     +PLIST_FILES=   bin/xxd
> >>>>     +
> >>>>     +USE_GITHUB=    yes
> >>>>     +GH_ACCOUNT=    vim
> >>>>     +GH_PROJECT=    vim
> >>>>     +
> >>>>     +do-install:
> >>>>     +       ${INSTALL_PROGRAM} ${WRKSRC}/xxd ${STAGEDIR}${PREFIX}/bin
> >>>>     +
> >>>>     +.include <bsd.port.mk <http://bsd.port.mk>>;
> >>>> The WWW is odd here. The source files are coming from
> >>>> github.com/vim/vim <http://github.com/vim/vim>, but the WWW is for a
> >>>> related but unused project.
> >>>
> >>> Oops, you're right. Submitter proposed to use a fork, but later I
> >>> decided grabbing the original vim distribution was better, I must
> >>> have forgotten updating the WWW line.
> >>>
> >>> Will fix it!
> >>>
> >>>> I update vim at the beginning of every month plus whenever new
> >>>> minors are released, and whenever there are patches that it's
> >>>> important for us to downstream. Rather than pinning xxd to a version
> >>>> that will be old literally tomorrow, why not pull the DISTVERSION
> >>>> and distinfo from editors/vim/Makefile?
> >>>
> >>> That would be a good idea, but while using vim distinfo is trivial,
> >>> I'm not sure how to import DISTVERSION from another port. Including
> >>> the Makefile would override a bunch of other variables.
> >>
> >> ${MAKE_CMD} -V DISTVERSION
> >>
> >> :-)
> >
> > Uhm I guess I need to pass it the vim makefile too so it would be:
> >
> > ${MAKE_CMD} -f ../editors/vim/Makefile -V DISTVERSION
> >
> > I guess. Does not look pretty, but could work.
> >
>
> Writing this here, for the record:
>
> This required some more work. I found inspiration in the
> devel/git-merge-changelog port.
>
> The BSDMAKE variable is defined only after bsd.port.pre.mk, so one needs
> to split the include of bsd.port.mk and extract values after the first
> one, into temporary variables that are referenced at the start of the
> Makefile.
>
> Committing fixes shortly.
>
> Thanks for the suggestions!
>

One other option is to make a vim-xxd flavor, which honestly may be the
best option. It would mean that xxd is built with the same configuration
that the mainline vim ports are built with, and vim and xxd already
conflict with each other (I'm not too concerned about vim-tiny and vim-xxd
conflicting as a byproduct).

# Adam


-- 
Adam Weinberger
adamw@adamw.org
https://www.adamw.org

[-- Attachment #2 --]
<div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-family:arial,sans-serif"><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Mar 31, 2023 at 11:07 AM Guido Falsi &lt;<a href="mailto:madpilot@freebsd.org">madpilot@freebsd.org</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 31/03/23 16:32, Guido Falsi wrote:<br>
&gt; On 31/03/23 16:30, Adam Weinberger wrote:<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt;&gt; On Mar 31, 2023, at 10:28, Guido Falsi &lt;<a href="mailto:madpilot@freebsd.org" target="_blank">madpilot@freebsd.org</a>&gt; wrote:<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; On 31/03/23 15:49, Adam Weinberger wrote:<br>
&gt;&gt;&gt;&gt; On Thu, Mar 30, 2023 at 4:45 PM Guido Falsi &lt;<a href="mailto:madpilot@freebsd.org" target="_blank">madpilot@freebsd.org</a> <br>
&gt;&gt;&gt;&gt; &lt;mailto:<a href="mailto:madpilot@freebsd.org" target="_blank">madpilot@freebsd.org</a>&gt;&gt; wrote:<br>
&gt;&gt;&gt;&gt;     The branch main has been updated by madpilot:<br>
&gt;&gt;&gt;&gt;     URL:<br>
&gt;&gt;&gt;&gt;     <br>
&gt;&gt;&gt;&gt; <a href="https://cgit.FreeBSD.org/ports/commit/?id=de841b40d24d22ab51ad05ed632e025903fbb41f" rel="noreferrer" target="_blank">https://cgit.FreeBSD.org/ports/commit/?id=de841b40d24d22ab51ad05ed632e025903fbb41f</a>; &lt;<a href="https://cgit.FreeBSD.org/ports/commit/?id=de841b40d24d22ab51ad05ed632e025903fbb41f" rel="noreferrer" target="_blank">https://cgit.FreeBSD.org/ports/commit/?id=de841b40d24d22ab51ad05ed632e025903fbb41f</a>&gt;<br>;
&gt;&gt;&gt;&gt;     commit de841b40d24d22ab51ad05ed632e025903fbb41f<br>
&gt;&gt;&gt;&gt;     Author:     Guido Falsi &lt;madpilot@FreeBSD.org&gt;<br>
&gt;&gt;&gt;&gt;     AuthorDate: 2023-03-30 20:42:54 +0000<br>
&gt;&gt;&gt;&gt;     Commit:     Guido Falsi &lt;madpilot@FreeBSD.org&gt;<br>
&gt;&gt;&gt;&gt;     CommitDate: 2023-03-30 20:42:54 +0000<br>
&gt;&gt;&gt;&gt;          sysutils/xxd: New port<br>
&gt;&gt;&gt;&gt;          This is the standalone version of the xxd tool provided by <br>
&gt;&gt;&gt;&gt; vim.<br>
&gt;&gt;&gt;&gt;          Submitted by:   Gianmarco Giovannelli &lt;<a href="mailto:gmarco@giovannelli.it" target="_blank">gmarco@giovannelli.it</a><br>
&gt;&gt;&gt;&gt;     &lt;mailto:<a href="mailto:gmarco@giovannelli.it" target="_blank">gmarco@giovannelli.it</a>&gt;&gt;<br>
&gt;&gt;&gt;&gt;     diff --git a/sysutils/xxd/Makefile b/sysutils/xxd/Makefile<br>
&gt;&gt;&gt;&gt;     new file mode 100644<br>
&gt;&gt;&gt;&gt;     index 000000000000..378f364cf4bf<br>
&gt;&gt;&gt;&gt;     --- /dev/null<br>
&gt;&gt;&gt;&gt;     +++ b/sysutils/xxd/Makefile<br>
&gt;&gt;&gt;&gt;     @@ -0,0 +1,26 @@<br>
&gt;&gt;&gt;&gt;     +PORTNAME=      xxd<br>
&gt;&gt;&gt;&gt;     +DISTVERSIONPREFIX=     v<br>
&gt;&gt;&gt;&gt;     +DISTVERSION=   9.0.1366<br>
&gt;&gt;&gt;&gt;     +CATEGORIES=    sysutils<br>
&gt;&gt;&gt;&gt;     +<br>
&gt;&gt;&gt;&gt;     +MAINTAINER= <a href="mailto:gmarco@giovannelli.it" target="_blank">gmarco@giovannelli.it</a> &lt;mailto:<a href="mailto:gmarco@giovannelli.it" target="_blank">gmarco@giovannelli.it</a>&gt;<br>
&gt;&gt;&gt;&gt;     +COMMENT=       Hexdump and reverse hexdump utility<br>
&gt;&gt;&gt;&gt;     +WWW= <a href="https://github.com/mew-cx/xxd" rel="noreferrer" target="_blank">https://github.com/mew-cx/xxd</a>; &lt;<a href="https://github.com/mew-cx/xxd" rel="noreferrer" target="_blank">https://github.com/mew-cx/xxd</a>&gt;<br>;
&gt;&gt;&gt;&gt;     +<br>
&gt;&gt;&gt;&gt;     +CONFLICTS_INSTALL=     vim-[0-9]* vim-gtk2 vim-gtk3 vim-motif <br>
&gt;&gt;&gt;&gt; vim-x11<br>
&gt;&gt;&gt;&gt;     +<br>
&gt;&gt;&gt;&gt;     +ALL_TARGET=    ${PORTNAME}<br>
&gt;&gt;&gt;&gt;     +PORTSCOUT=     ignore:1<br>
&gt;&gt;&gt;&gt;     +EXTRACT_AFTER_ARGS=    --include=&#39;*/src/xxd*&#39;<br>
&gt;&gt;&gt;&gt;     +WRKSRC_SUBDIR= src/xxd<br>
&gt;&gt;&gt;&gt;     +<br>
&gt;&gt;&gt;&gt;     +PLIST_FILES=   bin/xxd<br>
&gt;&gt;&gt;&gt;     +<br>
&gt;&gt;&gt;&gt;     +USE_GITHUB=    yes<br>
&gt;&gt;&gt;&gt;     +GH_ACCOUNT=    vim<br>
&gt;&gt;&gt;&gt;     +GH_PROJECT=    vim<br>
&gt;&gt;&gt;&gt;     +<br>
&gt;&gt;&gt;&gt;     +do-install:<br>
&gt;&gt;&gt;&gt;     +       ${INSTALL_PROGRAM} ${WRKSRC}/xxd ${STAGEDIR}${PREFIX}/bin<br>
&gt;&gt;&gt;&gt;     +<br>
&gt;&gt;&gt;&gt;     +.include &lt;<a href="http://bsd.port.mk" rel="noreferrer" target="_blank">bsd.port.mk</a> &lt;<a href="http://bsd.port.mk" rel="noreferrer" target="_blank">http://bsd.port.mk</a>&gt;&gt;<br>;
&gt;&gt;&gt;&gt; The WWW is odd here. The source files are coming from <br>
&gt;&gt;&gt;&gt; <a href="http://github.com/vim/vim" rel="noreferrer" target="_blank">github.com/vim/vim</a> &lt;<a href="http://github.com/vim/vim" rel="noreferrer" target="_blank">http://github.com/vim/vim</a>&gt;, but the WWW is for a <br>
&gt;&gt;&gt;&gt; related but unused project.<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; Oops, you&#39;re right. Submitter proposed to use a fork, but later I <br>
&gt;&gt;&gt; decided grabbing the original vim distribution was better, I must <br>
&gt;&gt;&gt; have forgotten updating the WWW line.<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; Will fix it!<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; I update vim at the beginning of every month plus whenever new <br>
&gt;&gt;&gt;&gt; minors are released, and whenever there are patches that it&#39;s <br>
&gt;&gt;&gt;&gt; important for us to downstream. Rather than pinning xxd to a version <br>
&gt;&gt;&gt;&gt; that will be old literally tomorrow, why not pull the DISTVERSION <br>
&gt;&gt;&gt;&gt; and distinfo from editors/vim/Makefile?<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; That would be a good idea, but while using vim distinfo is trivial, <br>
&gt;&gt;&gt; I&#39;m not sure how to import DISTVERSION from another port. Including <br>
&gt;&gt;&gt; the Makefile would override a bunch of other variables.<br>
&gt;&gt;<br>
&gt;&gt; ${MAKE_CMD} -V DISTVERSION<br>
&gt;&gt;<br>
&gt;&gt; :-)<br>
&gt; <br>
&gt; Uhm I guess I need to pass it the vim makefile too so it would be:<br>
&gt; <br>
&gt; ${MAKE_CMD} -f ../editors/vim/Makefile -V DISTVERSION<br>
&gt; <br>
&gt; I guess. Does not look pretty, but could work.<br>
&gt; <br>
<br>
Writing this here, for the record:<br>
<br>
This required some more work. I found inspiration in the <br>
devel/git-merge-changelog port.<br>
<br>
The BSDMAKE variable is defined only after <a href="http://bsd.port.pre.mk" rel="noreferrer" target="_blank">bsd.port.pre.mk</a>, so one needs <br>
to split the include of <a href="http://bsd.port.mk" rel="noreferrer" target="_blank">bsd.port.mk</a> and extract values after the first <br>
one, into temporary variables that are referenced at the start of the <br>
Makefile.<br>
<br>
Committing fixes shortly.<br>
<br>
Thanks for the suggestions!<br></blockquote><div><br></div><div style="font-family:arial,sans-serif" class="gmail_default">One other option is to make a vim-xxd flavor, which honestly may be the best option. It would mean that xxd is built with the same configuration that the mainline vim ports are built with, and vim and xxd already conflict with each other (I&#39;m not too concerned about vim-tiny and vim-xxd conflicting as a byproduct).</div><div style="font-family:arial,sans-serif" class="gmail_default"><br></div><div style="font-family:arial,sans-serif" class="gmail_default"># Adam</div></div><br clear="all"><br><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>Adam Weinberger</div><div><a href="mailto:adamw@adamw.org" target="_blank">adamw@adamw.org</a></div><div><a href="https://www.adamw.org" target="_blank">https://www.adamw.org</a></div></div></div></div></div></div>;
home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAP7rwcgts1Obgu5x8YpnoGGYQ2_9ENW-eFU_FzDwLAETYHfeog>