Date: Sun, 19 Aug 2018 13:10:10 +0800 From: blubee blubeeme <gurenchan@gmail.com> To: Helen Koike <helen.koike@collabora.com> Cc: FreeBSD Ports <freebsd-ports@freebsd.org>, Mathieu Arnold <mat@freebsd.org> Subject: Re: workflow question: how do you maintain the port in sync with upstream? Message-ID: <CALM2mEnwGkUMYsF3SSwoOGK%2Be6uGYCVZ5qf=hK9kw=FPdU7ZJQ@mail.gmail.com> In-Reply-To: <78db7cab-6658-5380-0c19-2e7245bd851f@collabora.com> References: <05457c2b-b85c-a929-20e7-38ff1b2899d6@collabora.com> <CALM2mEmnrLmLApeuun9h2OPJbj_wMXY9u-q=PUGyNpy5w8XfQg@mail.gmail.com> <87211ccd-bb2f-cd03-ecde-fd123d0c9ca5@collabora.com> <CALM2mEkV-pyQneSiSrWuBQ2VxoM-UAADSDjm5o2HhjD4FWBQYA@mail.gmail.com> <c0e1f68d-d1c7-b74d-b058-d758f46a7e1b@collabora.com> <CALM2mE=hXWocn8DDA23Qy6SEaFZg6OtoAQsAYWwhzc5eObwGpA@mail.gmail.com> <20180814153338.bujxg3a5uswj3y5n@ogg.in.absolight.net> <CALM2mEmD6epXhfFseEFOSdSz5-7aHEdDvt8WQ1krk9Ue4_vGbg@mail.gmail.com> <78db7cab-6658-5380-0c19-2e7245bd851f@collabora.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Aug 19, 2018, 13:02 Helen Koike <helen.koike@collabora.com> wrote: > > > On 08/14/2018 01:09 PM, blubee blubeeme wrote: > > > > > > On Tue, Aug 14, 2018 at 11:33 PM Mathieu Arnold <mat@freebsd.org > > <mailto:mat@freebsd.org>> wrote: > > > > On Tue, Aug 14, 2018 at 10:41:43PM +0800, blubee blubeeme wrote: > > > This one is fairly straight forward, you can simply replace that > > string > > > with a regex command; > > > This is an example of running a replace command for strings after > > the patch > > > phase of the build; > > > > > > post-patch: > > > @${REINPLACE_CMD} -e 's|for Linux|for FreeBSD|g' > > ${WRKSRC}/README > > > > Patching files in post-patch using sed SHOULD only be used to replace > > dynamic content, never static content. > > I am not sure I understand what dynamic content means here in the > post-patch (as nothing was built, so no new file should be created). Is > the replacement used by mail/lbdb wrong? > > from mail/lbdb/Makefile > post-patch: > ${REINPLACE_CMD} -e 's/sed/gsed/' ${WRKSRC}/m_muttalias.sh.in > > is it ok if I do the same? > It is not clear to me when I can use REINPLACE_CMD in the Makefile and > when I should do a patch. This is mostly a personal choice. If I'm changing complex strings I'd > generate a patch, if it's something simple just use the replace command. The shebang fix does something similar to incorrectly defined shebang lines at the top of script files. > > > > This is missing the point of the email since you can call that command > > in any stage of the port build process. > > > > Maybe we could append this info to the porters handbook. > > > > > > -- > > Mathieu Arnold > > > > Helen >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CALM2mEnwGkUMYsF3SSwoOGK%2Be6uGYCVZ5qf=hK9kw=FPdU7ZJQ>