Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Apr 2024 09:19:25 +0530
From:      Reshad Patuck <reshadpatuck1@gmail.com>
To:        Baptiste Daroussin <bapt@freebsd.org>
Cc:        "freebsd-pkgbase@freebsd.org" <freebsd-pkgbase@freebsd.org>
Subject:   Re: FreeBSD kernel version 0
Message-ID:  <CADaJeD27EPoZP9P7SNokhO35KANAMjCRNuwB-ukVi2%2BUBCiz7g@mail.gmail.com>
In-Reply-To: <t4mmlx65rpwskdsdnubkw6vh3ugk7k2zwogciyrrbotn5xzkj7@4unr4vaedhwe>
References:  <CADaJeD0QpPZizJPia6vxZAjB4EaDo8R%2B3PsV21GriRR4PJtLqw@mail.gmail.com> <t4mmlx65rpwskdsdnubkw6vh3ugk7k2zwogciyrrbotn5xzkj7@4unr4vaedhwe>

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

[-- Attachment #1 --]
Hi Bapt,

Thanks for this update.
Since I use pkg base with 14.0 on a bunch of systems in production would
you know if there are any plans to backport the patches to 14.0?
As a hack I am downgrading pkg manually on my system before building the
packages for now, this seems not-ideal.

I am trying to backport this into a patch that I can apply on 14.0 until
14.1 is available.
Can you tell me if these commits are a good starting point?
https://gitlab.com/FreeBSD/freebsd-src/-/commit/051d69d6f8b51dc1d7bba58af99be76185312222
https://gitlab.com/FreeBSD/freebsd-src/-/commit/5faaa602cee093269b1a73156c95c6892b4f098d

Thanks for the help,
Reshad


On Fri, 26 Apr 2024 at 17:08, Baptiste Daroussin <bapt@freebsd.org> wrote:

> On Fri 26 Apr 16:49, Reshad Patuck wrote:
> > Hi,
> >
> > I have been trying to compile FreeBSD 14.0-RELEASE-p5 on a FreeBSD
> > 14.0-RELEASE VM today and it seems like the FreeBSD_version annotation in
> > the +MANIFEST file is set to the value "0".
> > This caused my system to throw the error "pkg-static: Invalid FreeBSD
> > version 0 for package FreeBSD-kernel-generic" when I tried to install the
> > pkgs on another FreeBSD 14.0 system.
> >
> > I had compiled the same version (using the same commit hash) on the 12th
> of
> > March and it worked fine.
> >
> > I have attached the following files at https://paste.ee/d/9KcnQ:
> > - pkg-base-build-script.sh - The list of commands I used to build a new
> pkg
> > base instance
> > - +MANIFEST-working - the +MANIFEST file from the working pkg of FreeBSD
> > 14.0-RELEASE-p5 built on 2024-03-12
> > - +MANIFEST-broken - the +MANIFEST file from the broken pkg of FreeBSD
> > 14.0-RELEASE-p5 built on 2024-04-18
> >
> > I use a stock FreeBSD 14.0 image in AWS to spin up a new VM each time I
> run
> > this compilation and have used the same image since February.
> > The only thing that runs before I run the compilation is a pkg
> installation
> > of some tools like git, curl, htop, screen and vim.
> >
> > Looking at my archives, it seems that the version of pkg had changed from
> > '1.20_9' to '1.21.2'. Could there be something here?
> > Any help understanding why this difference exists will be much
> appreciated.
> >
> > Best Regards,
> > Reshad
>
> The reason is a bug in the 14.0 Makefiles which are not exposing OSVERSION
> (fixed in main, stable and will be in 14.1) and a behaviour fix in pkg
> 1.21.2
> which highlights the main issue.
>
> Up to pkg 1.21.2, pkg was leaking the OS version of the builder host into
> the
> package, since pkg 1.21.2 pkg stops leaking that informaiton and so the
> version
> if set to 0.
>
> Waiting for 14.1 to be release the builders have to export OSVERSION
> variable.
> the content of the variable should match what ever is the _FreeBSD_version
> in
> the source being built, this information is available in sys/sys/params.h
>
> Best regards,
> Bapt
>

[-- Attachment #2 --]
<div dir="ltr"><div>Hi Bapt,</div><div><br></div><div>Thanks for this update.</div><div>Since I use pkg base with 14.0 on a bunch of systems in production would you know if there are any plans to backport the patches to 14.0?</div><div>As a hack I am downgrading pkg manually on my system before building the packages for now, this seems not-ideal.</div><div><br></div><div>I am trying to backport this into a patch that I can apply on 14.0 until 14.1 is available.</div><div>Can you tell me if these commits are a good starting point?</div><div><a href="https://gitlab.com/FreeBSD/freebsd-src/-/commit/051d69d6f8b51dc1d7bba58af99be76185312222">https://gitlab.com/FreeBSD/freebsd-src/-/commit/051d69d6f8b51dc1d7bba58af99be76185312222</a></div><div><a href="https://gitlab.com/FreeBSD/freebsd-src/-/commit/5faaa602cee093269b1a73156c95c6892b4f098d">https://gitlab.com/FreeBSD/freebsd-src/-/commit/5faaa602cee093269b1a73156c95c6892b4f098d</a></div><div><br></div><div>Thanks for the help,</div><div>Reshad<br></div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, 26 Apr 2024 at 17:08, Baptiste Daroussin &lt;<a href="mailto:bapt@freebsd.org" target="_blank">bapt@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 Fri 26 Apr 16:49, Reshad Patuck wrote:<br>
&gt; Hi,<br>
&gt; <br>
&gt; I have been trying to compile FreeBSD 14.0-RELEASE-p5 on a FreeBSD<br>
&gt; 14.0-RELEASE VM today and it seems like the FreeBSD_version annotation in<br>
&gt; the +MANIFEST file is set to the value &quot;0&quot;.<br>
&gt; This caused my system to throw the error &quot;pkg-static: Invalid FreeBSD<br>
&gt; version 0 for package FreeBSD-kernel-generic&quot; when I tried to install the<br>
&gt; pkgs on another FreeBSD 14.0 system.<br>
&gt; <br>
&gt; I had compiled the same version (using the same commit hash) on the 12th of<br>
&gt; March and it worked fine.<br>
&gt; <br>
&gt; I have attached the following files at <a href="https://paste.ee/d/9KcnQ" rel="noreferrer" target="_blank">https://paste.ee/d/9KcnQ</a>:<br>;
&gt; - pkg-base-build-script.sh - The list of commands I used to build a new pkg<br>
&gt; base instance<br>
&gt; - +MANIFEST-working - the +MANIFEST file from the working pkg of FreeBSD<br>
&gt; 14.0-RELEASE-p5 built on 2024-03-12<br>
&gt; - +MANIFEST-broken - the +MANIFEST file from the broken pkg of FreeBSD<br>
&gt; 14.0-RELEASE-p5 built on 2024-04-18<br>
&gt; <br>
&gt; I use a stock FreeBSD 14.0 image in AWS to spin up a new VM each time I run<br>
&gt; this compilation and have used the same image since February.<br>
&gt; The only thing that runs before I run the compilation is a pkg installation<br>
&gt; of some tools like git, curl, htop, screen and vim.<br>
&gt; <br>
&gt; Looking at my archives, it seems that the version of pkg had changed from<br>
&gt; &#39;1.20_9&#39; to &#39;1.21.2&#39;. Could there be something here?<br>
&gt; Any help understanding why this difference exists will be much appreciated.<br>
&gt; <br>
&gt; Best Regards,<br>
&gt; Reshad<br>
<br>
The reason is a bug in the 14.0 Makefiles which are not exposing OSVERSION<br>
(fixed in main, stable and will be in 14.1) and a behaviour fix in pkg 1.21.2<br>
which highlights the main issue.<br>
<br>
Up to pkg 1.21.2, pkg was leaking the OS version of the builder host into the<br>
package, since pkg 1.21.2 pkg stops leaking that informaiton and so the version<br>
if set to 0.<br>
<br>
Waiting for 14.1 to be release the builders have to export OSVERSION variable.<br>
the content of the variable should match what ever is the _FreeBSD_version in<br>
the source being built, this information is available in sys/sys/params.h<br>
<br>
Best regards,<br>
Bapt<br>
</blockquote></div>
help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CADaJeD27EPoZP9P7SNokhO35KANAMjCRNuwB-ukVi2%2BUBCiz7g>